Repository navigation
fix(loop): O13 recover thinking-only turns by lowering reasoning - #82
Merged
Merged
Conversation
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
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.
Summary
O13 (P0): recover thinking-only turns by raising the retry budget and lowering/turning off reasoning per provider on each retry, instead of aborting after two reasoning-only turns.
未找到原始 run1
Shared box has no
/workspace/moss-self/run1. Mac (~/Desktop/RDK_Studioand common paths) also has nomoss-self/run1directory or logs. Root cause below is code-verified against current main + backlog text (G6/O13 indocs/plan/moss-roadmap.md), not against original run1 logs.Root cause (code-verified)
THINKING_ONLY_RETRY_BUDGET = 1→ second thinking-only turn threwThe model returned private reasoning twice without a visible answer.reasoningwas unchanged; underadaptiveit could even rise tohigh.Fix
1 → 2(stop after 3 consecutive thinking-only turns).thinkingOnlyReasoningOverride(provider, attempt, modelId): attempt 0 →low; attempt 1 →offwhen provider/model matcheszai|zhipu|glm|deepseek|qwen|dashscope|kimi|moonshot, elselow.state.reasoningOverrideNextTurnconsumed inagent-loop-llm-call.ts(cleared after use; wins over adaptive high).THINKING_ONLY_RETRY_BUDGET + 1.src/safety/**orgit-config-env.ts. Does not start O70/O80.Files
src/core/loop/agent-loop-post-llm.tssrc/core/loop/agent-loop-llm-call.tssrc/core/loop/agent-loop-response.tssrc/core/loop/agent-loop-state.tssrc/core/loop/agent-loop.tstest/o13-thinking-only-recovery.spec.mjs(new)test/agent-loop-post-llm.spec.mjs(budget assert 1→2)Tests
Coverage: two thinking-only turns do not abort; still thinking-only after budget → clear error (never treat empty answer as success); glm override
low→off; Anthropic stayslow.B1 full suite not re-run (token cost); related loop unit tests + smoke green. No safety path changes.
Live glm-5.3 ×3
Because original run1 prompt is missing, ran the same new bootstrap-style read-only probe three times (
task.txtin gist): read post-llm + llm-call sources and produce a visible summary. Modelglm-5.3via D-Robotics gateway,--max-turns 25, debug on.run-1.logrun-2.logrun-3.logEnglish "private reasoning … times in a row" strings in the logs are quoted in the model answer, not runtime throws (exit 0). Long-context 180k-token original self-host path was not replayed (no run1) — noted as uncovered.
Accept write-up + logs: https://gist.github.com/QiaolongLi1201/7981751ab23566e604266d5790764c95
Base
59c7ee7b(main after #79 O79 + #81 O57/O83).Follow-ups