Skip to content

Unify Write tool to inline file_path + content#1016

Merged
bobleer merged 1 commit into
GCWing:mainfrom
bobleer:refactor/write-inline-unified
Jun 1, 2026
Merged

Unify Write tool to inline file_path + content#1016
bobleer merged 1 commit into
GCWing:mainfrom
bobleer:refactor/write-inline-unified

Conversation

@bobleer
Copy link
Copy Markdown
Collaborator

@bobleer bobleer commented Jun 1, 2026

Summary

  • Remove the PlaintextFollowup / two-step Write content generation path, including write_tool_mode config, round-executor follow-up AI calls, and related adapter/stream plumbing.
  • Align the Write tool contract with Claude Code: single inline call with required file_path + content, updated guardrails, and cleaned agent prompts.
  • Improve streaming Write UX by extracting file_path from the params buffer when possible and showing clearer status copy when content streams before the path.

Test plan

  • cargo check -p bitfun-core -p bitfun-ai-adapters -p bitfun-acp
  • cargo test -p bitfun-core --lib file_write_tool
  • cargo test -p bitfun-ai-adapters message_converter
  • pnpm run type-check:web
  • pnpm --dir src/web-ui run test:run src/shared/utils/partialJsonParser.test.ts src/flow_chat/services/flow-chat-manager/ToolEventModule.test.ts src/flow_chat/tool-cards/FileOperationToolCard.test.ts

Remove the PlaintextFollowup two-step Write content generation path,
settings UI, and round-executor follow-up logic so Write always submits
file_path and content in one tool call aligned with Claude Code.
Improve streaming Write UI path extraction and status copy when content
arrives before file_path.
@bobleer bobleer merged commit 76b2cf1 into GCWing:main Jun 1, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant