Repository navigation
judge: ASK hands a question back to the user; server stream errors retry once - #415
Merged
Merged
Conversation
…try once
- The goal judge has a third verdict, ASK (ask_user() or "ASK: <question>"):
the agent stopped on a question only the user can answer. The run ends
without a re-feed, the goal stands ("your answer: …"), and the TUI says it
waits for the reply. The judge decides, not the agent, so a weak model can't
use asking to dodge work; a question it could settle itself is MORE. MORE
outranks ASK, ASK outranks DONE; ASK is never read from a draft and needs a
colon and a question. Replaces the v0.71.0 rule that every unaccepted prose
reply handed control back, and covers a question asked after tool use.
- An error the server reports inside the stream is retried once, not with the
full retry budget: the server is up and says the generation failed, and an
over-long prompt fails the same way each time. Dropped connections and stalls
keep the full budget.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
There was a problem hiding this comment.
If your organization's extra usage balance is empty, an organization admin can add extra usage credits at claude.ai/admin-settings/usage. If its monthly spend limit was reached, an admin can raise it on the same page. If neither applies, contact Anthropic support.
Once extra usage is available, someone with write access to this repository can comment @claude review on this pull request to trigger a review.
- The user's answer carries the goal on: the goal keeps the question it stopped
on (goalState.Asked), the next run gets it (SetPendingQuestion), is judged like
the goal itself even when the model only acknowledges in prose, and the judge
is told the question was asked and this is the answer.
- The give-up paths (stuck, steps out, failed turn) keep an ASK: Transcript.Asked,
the "waiting for your answer" event and note, no re-feed, no "/goal go".
- ASK counts only when the agent's last words hold a question; otherwise it is
no verdict. "ASK: x — MORE: y" on one line is MORE. Formatting alone
("**ASK:**") is not a question. ask_user() with no question no longer hides a
DONE. The judge is told an already-answered question is MORE.
- A re-fed run that never used a tool is not pushed to "do it with tools": its
prose goes to the judge.
- Server stream errors: counted apart from dropped connections, and errors that
say the server is busy, overloaded or loading keep the full retry budget.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
- /goal go while a question stands is a resume, not the user's reply: the judge
sees the ordinary gap ("your answer: …"), not "this is their answer".
- A mid-stream error whose type is only "server_error", or whose message names
the request (context, too long, exceed, invalid), keeps the one-retry cap;
only specific busy/loading/overload/rate-limit conditions get the full budget.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
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.
the agent stopped on a question only the user can answer. The run ends
without a re-feed, the goal stands ("your answer: …"), and the TUI says it
waits for the reply. The judge decides, not the agent, so a weak model can't
use asking to dodge work; a question it could settle itself is MORE. MORE
outranks ASK, ASK outranks DONE; ASK is never read from a draft and needs a
colon and a question. Replaces the v0.71.0 rule that every unaccepted prose
reply handed control back, and covers a question asked after tool use.
full retry budget: the server is up and says the generation failed, and an
over-long prompt fails the same way each time. Dropped connections and stalls
keep the full budget.
Review rounds (codex, muse, devin):
on (goalState.Asked), the next run gets it (SetPendingQuestion), is judged like
the goal itself even when the model only acknowledges in prose, and the judge
is told the question was asked and this is the answer.
the "waiting for your answer" event and note, no re-feed, no "/goal go".
no verdict. "ASK: x — MORE: y" on one line is MORE. Formatting alone
("ASK:") is not a question. ask_user() with no question no longer hides a
DONE. The judge is told an already-answered question is MORE.
prose goes to the judge.
say the server is busy, overloaded or loading keep the full retry budget.
sees the ordinary gap ("your answer: …"), not "this is their answer".
the request (context, too long, exceed, invalid), keeps the one-retry cap;
only specific busy/loading/overload/rate-limit conditions get the full budget.
Each change has a test that fails with the change reverted. go test ./..., -race on internal/agent, internal/llm, cmd/agent, and the windows build pass.
🤖 Generated with Claude Code