Repository navigation
fix(routing): count a fallback private think's prose as the native path does - #641
Merged
slimepriestess merged 1 commit intoOct 20, 2026
Conversation
…th does The fallback path counted the prose a private think's round withheld into keptPrivate on every turn. The native path counts a private round's prose only where routeRound does: outside explicit routing, as kept private where the turn is silenced as that round ends; as suppressed under proseRouting disabled; and otherwise not at all (it only logs it). So an XML-mode turn with a private think and nothing silencing it got a "kept private" receipt line a native turn never prints, and under disabled routing the same prose was labelled kept private rather than kept in the transcript. routeRound now records each private-think round the turn was silenced at as that round ended. At turn end the fallback counts those rounds' prose as kept private, counts the withheld prose as suppressed under disabled routing, and otherwise counts nothing, so a send in a later round leaves an earlier private round uncounted, as on the native path. Tests pin an unsilenced turn, a send in a later round (native and XML), disabled routing, and a native turn whose completion carries the whole turn, which counts its private round once. The think tool's description under the private policy no longer says the text it withholds is the "native" round's, since the fallback now withholds it too. The holdSilencedProse comment and the pending hold-round-speech fragment, which said the private think hold was native-only, now match, and fallback-private-think.fixed.md says how the receipt counts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The review run stopped before it finished, so its review may be missing or incomplete. The run's log says why: https://github.com/anima-research/agent-framework/actions/runs/39510099326 |
slimepriestess
merged commit Oct 20, 2026
b6c8dd3
into
anima-research:fix/fallback-private-think
6 of 7 checks passed
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
The changes our review of #640 found, as a pull request into
fix/fallback-private-think. Merging it brings them into #640.Changes
keptPrivateon every fallback turn. On the native path,routeRoundcounts a private round's prose as kept private only where the turn is silenced as that round ends (outside explicit routing), as suppressed underproseRouting: disabled, and otherwise logs it and counts nothing. So an XML-mode turn with a private think and nothing silencing it, or with a send only in a later round, got a "kept private" receipt line that a native turn never prints, and under disabled routing the prose was labelled kept private rather than kept in the transcript.routeRoundnow records each private-think round the turn was silenced at as that round ended, and the fallback counts those rounds' prose at turn end by the same rules.think's description under the private policy no longer calls the withheld text the "native" round's, since the fallback now withholds it too.agent_settings' description of the policy is the same text for every agent, so it's left as it is.holdSilencedProsecomment and the pendinghold-round-speech.fixed.md, which said the private think hold was native-only, now match.fallback-private-think.fixed.mdsays how the receipt counts.Tests
On Linux, Node 24.22.0, at this head:
tsc --noEmitis clean.same-round-think-policypasses 21 of 21,prose-drafts92 of 92, andagent-allowed-tools68 of 68.prose-drafts:proseRouting: disabled, the withheld segment and the trailing one count once each as kept in the transcript;Not verified
v0.5.87'sparseAccumulatedIntoBlocks, run on a two-round accumulated turn, givestext | tool_use | tool_result | text | tool_use | tool_result | text. fix(routing): a private think keeps its round's text private on the fallback path too #640'swithoutRoundsProsethen drops only the round that calledthink. That was the parser alone, not a turn against a model.privateThinkRoundsstays empty, so nothing fix(routing): a private think keeps its round's text private on the fallback path too #640 adds runs.changelog.d/<slug>.<breaking|added|changed|fixed>.md(seechangelog.d/README.md) — or this change is internal-only / test-only / docs-only (apply theno-changeloglabel).Written by Nell-1783 (Claude Opus 5.5), with design calls by Ada-1017 and a read and runs by Hilda-2580. Our internal review read #640.
Description checked and posted by Lottie-2661 (Claude Opus 5.5).
🤖 Written using Anthropic's Claude Opus 5.5 through the Rookery's tooling, and posted from the shared
nissa-seruaccount.