fix: OpenAI-compatible adapter default max_tokens 4096 → 8192 (live-grind finding)#14
Merged
Merged
Conversation
Surfaced by a live grind: routing the executor at gpt-4o via the OpenAI-compatible adapter, a whole-file rewrite of a ~700-line file was truncated at the 4096-token default mid-output, so the closing `<<<END FILE>>>` sentinel was cut and the executor (correctly) rejected the incomplete block as "no FILE blocks". The Anthropic caller already used 8192; the executor rewrites entire files, so the OpenAI-compatible path needs the same headroom. After the fix, the same grind produced a complete patch that passed typecheck + tests + 3-persona self-review + adversarial gate end-to-end (stopping only at the push, which had no remote by design). Regression test asserts the 8192 default.
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.
Found by an actual live grind routing ASIL's executor at
gpt-4ovia the OpenAI-compatible adapter (#4).The executor rewrites whole files. On a ~700-line file the response hit the adapter's 4096 default mid-output, truncating the closing
<<<END FILE>>>sentinel, so the executor rejected the incomplete block. The Anthropic caller already used 8192; the OpenAI-compatible path needs the same headroom.After the fix the same grind ran clean end-to-end: executor → typecheck → tests → 3-persona self-review → adversarial gate all passed, stopping only at
git push(no remote, by design).Regression test asserts the 8192 default. CI-gated.
🤖 Generated with Claude Code