Skip to content

feat(comments): send review comments once, with Send now and a composer chip - #286

Merged
bk-agent-01 merged 4 commits into
stagefrom
t3code/comments-send-now
Oct 8, 2026
Merged

bk-agent-01 merged 4 commits into
stagefrom
t3code/comments-send-now

Conversation

@bk-agent-01

Copy link
Copy Markdown
Collaborator

Problem

Open review comments went with every turn, and nothing showed that they had already gone. The strip above the chat box had no way to send the comments by themselves. When comments were still open, there was no simple way to ask the agent to finish them or to report on them.

Fix (Option A, as approved)

Send once

  • A new last_sent_at column (fork migration 1048_ThreadCommentLastSent, additive) records when a comment went to the agent.
  • At turn start, the server adds only the open comments that are not sent yet. It then marks the comments that fit in the turn input.
  • A user reply or a reopen clears the mark, so the comment goes again. An agent reply does not clear it.
  • A new RPC, threadComments.resend, clears the mark on all open comments.

Review prompt

  • The agent is told to act on or answer each comment, and to reply to every one with t3_reply_comment. When a comment is unclear, it asks instead of guessing.

Strip above the chat box

  • The strip shows only the comments that are not sent yet.
  • A new Send now button sends a message with only the comments, through the run queue. The draft stays as it is, and a running turn is not interrupted.

Chip in the top-right corner of the chat box

  • It shows how many comments are sent (blue) or addressed (green).
  • Its menu has Address remaining, Ask for an update, Review comments, Resolve addressed and Pause sending. The first two clear the mark first, so the open comments go with that message.

Text

  • The agent tool descriptions and docs/user/chat-comments.md describe the send-once rule.

Code location: All of the logic is in fork files. ChatComposer.tsx gets one marked line that draws the chip. Mobile does not change.

Evidence

Tests cover the send-once and resend rules (service), sent marks at turn start (turn context), the migration ledger, and the strip and chip rules (web model). CI runs them; the dev server does not run tests. No screenshots: the preview browser cannot run on this host.

🤖 Generated with Claude Code

…er chip

Open review comments used to ride along with every turn, and nothing showed
that they had already gone. Now each comment goes once and is marked sent
(new `last_sent_at` column, fork migration 1048); a user reply, an edit via
reopen, or an explicit re-send clears the mark.

- Server: turn start appends only unsent open comments and marks the ones
  that fit; a new `threadComments.resend` RPC clears the mark on open
  comments. The agent instructions now ask it to work through each comment
  and reply to every one with t3_reply_comment.
- Web: the strip shows only unsent comments and gains "Send now", which sends
  a comments-only message through the run queue and keeps the draft. A chip
  in the composer's top-right corner shows sent (blue) / addressed (green)
  counts; its menu has Address remaining, Ask for an update, Review comments,
  Resolve addressed and Pause sending.
- Agent tool descriptions and the user guide describe the send-once rule.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:XL labels Oct 8, 2026
bk-agent-01 and others added 3 commits October 8, 2026 07:06
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- prepareOpenThreadComments returns the text plus a markSent step, and the
  run marks comments only once the provider turn has started, so a turn that
  never starts leaves them unsent.
- markSent marks a row only while it is unchanged since the turn read it, so
  a reply that lands in between still reaches the agent.
- The chip's re-send items are disabled while sending is paused.
- The chip straddles the chat box's top edge instead of covering the draft.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… the longer prompt

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@bk-agent-01
bk-agent-01 merged commit e1bcdda into stage Oct 8, 2026
25 of 26 checks passed
bk-agent-01 added a commit that referenced this pull request Oct 8, 2026
Stage shipped migration 1048 (ThreadCommentLastSent), so upstream 59-60
move to 1049-1050. Web UI RPC counts include #286's resend RPC (236).

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XL vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant