Commit Graph

260 Commits

Author SHA1 Message Date
Dave
a6ac6497e9 story-kit: merge 301_story_dedicated_token_usage_page_in_web_ui 2026-03-19 11:36:12 +00:00
Dave
f88114edbf story-kit: merge 305_story_bot_show_command_displays_story_text_in_chat 2026-03-19 11:12:35 +00:00
Dave
36535b639f story-kit: merge 300_story_show_token_cost_badge_on_pipeline_board_work_items 2026-03-19 11:02:12 +00:00
Dave
f4376b01e1 story-kit: merge 304_story_mcp_tool_to_move_stories_between_pipeline_stages 2026-03-19 10:59:47 +00:00
Dave
c327263254 story-kit: merge 302_story_bot_cost_command_shows_total_and_per_story_token_spend 2026-03-19 10:54:04 +00:00
Dave
981fd3fd81 story-kit: merge 298_story_bot_htop_command_with_live_updating_process_dashboard
Adds htop bot command with live-updating Matrix message showing system
load and per-agent CPU/memory usage. Supports timeout override and
htop stop. Resolved conflict with git command in commands.rs registry.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 10:33:21 +00:00
Dave
b25ae42737 story-kit: merge 299_story_bot_git_status_command_shows_working_tree_and_branch_info 2026-03-19 10:11:28 +00:00
Dave
9cdb0d4ea8 story-kit: merge 296_story_track_per_agent_token_usage_for_cost_visibility_and_optimisation 2026-03-19 09:55:25 +00:00
Dave
6c413e1fc7 fix: call auto_assign_available_work after every pipeline advance (bug 295)
Stories got stuck in QA/merge when agents were busy at assignment time.
Consolidates auto_assign into a single unconditional call at the end of
run_pipeline_advance, so whenever any agent completes, the system
immediately scans for pending work and assigns free agents.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:53:41 +00:00
Dave
63f46751ac story-kit: merge 294_story_rename_app_title_from_story_kit_to_storkit 2026-03-19 09:46:28 +00:00
Dave
6353b12c1d story-kit: merge 297_story_improve_bot_status_command_formatting 2026-03-19 09:39:05 +00:00
Dave
73c86b6946 story-kit: merge 293_story_register_all_bot_commands_in_the_command_registry
Moves status, ambient, and help commands into a unified command registry
in commands.rs. Help output now automatically lists all registered
commands. Resolved merge conflict with 1_backlog rename.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 09:14:04 +00:00
Dave
2f0d796b38 story-kit: merge 292_story_show_server_logs_in_web_ui 2026-03-19 01:31:25 +00:00
Dave
2346602b30 fix: default manual_qa to false so stories advance automatically
Bug 283 was implemented with manual_qa defaulting to true, causing all
stories to hold in QA for human review. Changed to default false as
originally specified — stories advance automatically unless explicitly
opted in with manual_qa: true.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-19 00:53:00 +00:00
Dave
52ec989c3a Fixed some bot tests. 2026-03-18 16:37:23 +00:00
Dave
503fa6b7bf fix: rename remaining 1_upcoming references to 1_backlog in bot.rs
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 15:53:36 +00:00
Dave
9352443555 story-kit: merge 247_story_human_qa_gate_with_rejection_flow 2026-03-18 15:47:48 +00:00
Dave
3adae6c475 story-kit: merge 289_bug_rebuild_and_restart_mcp_tool_does_not_rebuild 2026-03-18 15:27:29 +00:00
Dave
e8ec84668f story-kit: merge 284_story_matrix_bot_status_command_shows_pipeline_and_agent_availability 2026-03-18 15:22:19 +00:00
Dave
8fcfadcb04 story-kit: merge 288_bug_ambient_mode_state_lost_on_server_restart 2026-03-18 15:01:40 +00:00
Dave
e7bb8db7c1 story-kit: merge 285_story_matrix_bot_help_command_lists_available_bot_commands 2026-03-18 14:57:27 +00:00
Dave
df6f792214 story-kit: merge 287_story_rename_upcoming_pipeline_stage_to_backlog 2026-03-18 14:33:08 +00:00
Dave
baa8bdcfda story-kit: merge 286_story_server_self_rebuild_and_restart_via_mcp_tool 2026-03-18 14:09:09 +00:00
Dave
b50d007b40 story-kit: merge 282_story_matrix_bot_ambient_mode_toggle_via_chat_command 2026-03-18 12:12:19 +00:00
Dave
53fdcfec75 story-kit: merge 281_story_matrix_bot_announces_itself_when_it_comes_online 2026-03-18 11:48:15 +00:00
Dave
a5e64ded83 fix: unused system_prompt variable warning
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 11:44:16 +00:00
Dave
77e368d354 fix: --system is not a valid Claude Code CLI flag
Removed the --system argument from the PTY runner — Claude Code CLI
doesn't support it. Bot name instruction is now prepended to the user
prompt instead of passed as a system prompt argument.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 11:42:39 +00:00
Dave
81a5660f11 story-kit: merge 277 - bot uses configured display_name
Adds system_prompt parameter to chat_stream so the Matrix bot
passes "Your name is {name}" to Claude Code. Reads display_name
from bot.toml config. Resolved conflicts by integrating bot_name
into master's permission-handling code structure.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 11:23:50 +00:00
Dave
4bf01c6cca fix: session_id wiped on every trim, breaking --resume
The history trimming logic cleared session_id = None whenever entries
exceeded history_size. Since the history was always at capacity, every
new message wiped the session_id immediately after storing it. This
meant --resume was never passed to Claude Code, making every turn a
fresh conversation.

Fix: preserve session_id on trim. Claude Code's --resume loads the
full conversation from its own session transcript on disk, so trimming
our local tracking entries doesn't invalidate the session.

Also adds debug logging for session_id capture/storage (temporary).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 11:19:00 +00:00
Dave
5f4591f496 fix: update should_commit_stage test to match 5_done in COMMIT_WORTHY_STAGES
The test was asserting 5_done should NOT trigger commits, but commit 74dc42c
added 5_done to COMMIT_WORTHY_STAGES. Updated test to match.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-18 10:46:11 +00:00
Dave
dc7968ffbc story-kit: mergemaster conflict resolution, vite proxy fix, bug 279
- Upgrade mergemaster prompt to resolve complex conflicts itself
  instead of just reporting failure. Includes instructions to check
  git history and story files for context before resolving.
- Add proxy error handler to vite config to prevent crashes on
  backend ECONNREFUSED.
- Fix bug 279: auto-assign now checks that preferred agent's stage
  matches the pipeline stage. Coders won't be assigned to QA/merge.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 10:44:10 +00:00
Dave
60dabae795 story-kit: merge 271_story_show_assigned_agent_in_expanded_work_item_view
Adds assigned agent display to the expanded work item detail panel.
Resolved conflicts by keeping master versions of bot.rs (permission
handling), ChatInput.tsx, and fs.rs. Removed duplicate list_project_files
endpoint and tests from io.rs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 10:29:37 +00:00
Dave
beb5ea9f53 fix: revert broken auto-merge of 266 in bot.rs
The mergemaster's auto-resolver inserted a duplicate chat_stream call
inside the tokio::select! permission loop, producing mismatched braces.
The 266 merge didn't contribute useful code changes to bot.rs — the
session_id handling was already present.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 10:20:40 +00:00
Dave
0c686ba170 story-kit: merge 266_story_matrix_bot_structured_conversation_history 2026-03-18 10:18:49 +00:00
Dave
74dc42c1fc story-kit: add 5_done to commit-worthy stages
Keep done stage committed so accepted work is in git history.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 10:13:35 +00:00
Dave
3a1d7012b4 spike(92): stop auto-committing intermediate pipeline moves
Filter flush_pending() to only git-commit for terminal stages
(1_upcoming and 6_archived) while still broadcasting WatcherEvents
for all stages so the frontend stays in sync.

Reduces pipeline commits from 5+ to 2 per story run. No system
dependencies on intermediate commits were found.

Preserves merge_failure front matter cleanup from master.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 10:06:58 +00:00
Dave
10a5bea2b1 story-kit: merge 275_story_matrix_bot_surfaces_claude_code_permission_prompts_to_chat 2026-03-18 09:32:17 +00:00
Dave
8bbbe8fbdd story-kit: start 274_story_mcp_pipeline_status_tool_with_agent_assignments 2026-03-18 09:25:01 +00:00
Dave
bc0bb91a83 story-kit: merge 272_story_clear_merge_error_front_matter_when_story_leaves_merge_stage 2026-03-17 18:21:56 +00:00
Dave
901f7a65d3 story-kit: merge 270_bug_qa_test_server_overwrites_root_mcp_json_with_wrong_port 2026-03-17 18:16:13 +00:00
Dave
123f140244 story-kit: start 269_story_file_references_in_web_ui_chat_input 2026-03-17 17:56:24 +00:00
Dave
a893a1cef7 story-kit: merge 266_story_matrix_bot_structured_conversation_history 2026-03-17 17:42:08 +00:00
Dave
f72666b39e story-kit: merge 267_story_mcp_update_story_tool_should_support_front_matter_fields 2026-03-17 17:35:57 +00:00
Dave
86694a4383 story-kit: merge 265_story_spikes_skip_merge_and_stop_for_human_review 2026-03-17 16:36:00 +00:00
Dave
f5d5196bf5 Fix cross-signing bootstrap by passing UIA password auth
The homeserver requires User-Interactive Authentication before accepting
cross-signing keys. Pass the bot's password so bootstrap succeeds.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 16:08:39 +00:00
Dave
ce899b569e story-kit: merge 263_story_matrix_bot_self_signs_device_keys_at_startup_for_verified_encryption 2026-03-17 15:34:58 +00:00
Dave
96779c9caf story-kit: merge 262_story_bot_error_notifications_for_story_failures 2026-03-17 15:27:48 +00:00
Dave
5a4a2aaa17 story-kit: merge 245_bug_chat_history_persistence_lost_on_page_refresh_story_145_regression 2026-03-17 14:38:05 +00:00
Dave
a4affca9be story-kit: merge 261_story_bot_notifications_when_stories_move_between_stages 2026-03-17 14:05:02 +00:00
Dave
3602f882d2 story-kit: merge 258_bug_auto_assign_not_called_after_merge_failure 2026-03-17 13:38:42 +00:00