You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Beta header rewrite breaks Opus 5.5, Sonnet 5.5 and Fable 5.1 on OpenCode 1.18.x #33
On AI assistance: Claude (Opus 5.5 / 1M context) helped me narrow down the behavior and draft the wording below, including the repro steps. The actual issue and workflow are mine. — @balaji-dutt
Summary
With opencode 1.18.31 and opencode-claude-bridge 1.10.12, every request to a Claude 5.1+ model through the anthropic provider fails:
thinking.adaptive.block_binding: Extra inputs are not permitted
Since anomalyco/opencode#46653 (scoped to 5.1+ by anomalyco/opencode#46848), opencode adds thinking.block_binding to these requests and sends the thinking-binding-controls-2026-08-01 beta with it. buildBetaFlags() ignores the incoming anthropic-beta value and replaces it with BETA_FLAGS, so the field reaches the API without its beta.
#32 fixes this by merging the incoming flags. I'm filing this so the error is searchable, and to ask for #32 to be merged and released.
opencode run -m anthropic/claude-opus-5-5 'Reply with exactly: OK'
Confirming the cause
Adding the beta to the bridge's own list makes the same request succeed over OAuth, so the subscription path accepts it once it survives the rewrite:
ANTHROPIC_BETA_FLAGS="interleaved-thinking-2025-05-14,thinking-token-count-2026-05-13,context-management-2025-06-27,prompt-caching-scope-2026-01-05,claude-code-20250219,advisor-tool-2026-03-01,effort-2025-11-24,extended-cache-ttl-2025-04-11,thinking-binding-controls-2026-08-01" \
opencode run -m anthropic/claude-opus-5-5 'Reply with exactly: OK'# OK
Keep type: "adaptive". Without it, opencode drops the thinking object, and THINKING_MODELS only re-adds thinking for 4.x models, so the request goes out with no thinking at all.
Ask
Please merge and release #32. A release would also ship the #19 loader fix from #27: npm latest is still 1.10.12 (2026-07-02), and on 1.18.31 every start still logs failed to load plugin ... modelId.match is not a function. The request rewriting still runs despite that error; the ANTHROPIC_BETA_FLAGS test above changes the outcome.
Activity