Repository navigation
feat(server): remind the agent of open chat comments on every turn - #353
Merged
Merged
Conversation
A chat comment went to the agent in full once and was then never mentioned again, so an agent that moved on to the next request forgot comments it had not addressed. Every later turn now carries a short reminder that lists the sent-but-open comments by number and points at t3_list_comments and t3_reply_comment. New, edited, replied or reopened comments still go in full; addressed comments and paused threads get no reminder. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
An open chat comment goes to the agent in full once, with the next turn. After that the agent hears nothing about it. When the user sends a new request, the agent works on that request and forgets the comments that it did not mark addressed.
What changed
Each new provider turn now looks at the thread's open comments in two groups (
ThreadCommentsService.deliveryState, one read, same cost as before):<open_chat_comments>block, as today, then marked sentopen(agent did not mark it addressed)<open_chat_comments_reminder>(about 500 chars): the comment numbers, "keep working toward resolving them", callt3_reply_commentwithaddressed=true, callt3_list_commentsto read them againaddressedby the agent/compactThe reminder never marks anything sent, and it lists at most 20 numbers ("#20 and 5 more").
All changes are in fork-owned files (
apps/server/src/threadcomments/, the fork ws handler test,docs/user/chat-comments.md). No upstream file changes.How I tested
turnContext.test.ts(reminder only, block plus reminder, reminder when the block does not fit, number cap, tag defusing) andThreadCommentsService.test.ts(deliveryStatesplit and pause).🤖 Generated with Claude Code