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
textVerbosity injected for gpt-5.x on @ai-sdk/openai-compatible providers, breaks Bedrock Mantle via LiteLLM gateway #43911
OpenCode auto-injects textVerbosity: "low" for any model whose ID matches gpt-5.*, regardless of the actual backend provider. Via an @ai-sdk/openai-compatible provider (e.g. a LiteLLM gateway), this becomes verbosity in the request body. When the gateway routes to AWS Bedrock ("Bedrock Mantle"), Bedrock rejects the unknown parameter and LiteLLM throws UnsupportedParamsError, breaking every request to the model (including fallback attempts).
Root cause in packages/opencode/src/provider/transform.ts (options()), current dev branch:
The guard excludes Azure but allows every other provider through, including generic @ai-sdk/openai-compatible proxies that don't understand verbosity at all. This is the same class of bug fixed for reasoningSummary in #21237 / #22352 — textVerbosity never received the equivalent fix.
A related PR (#42075) already implemented and tested the correct fix, but it was auto-closed by the compliance bot for lacking a linked issue before it could be reviewed. This issue exists to unblock a fresh PR with that fix.
Plugins
None — reproduced with a custom @ai-sdk/openai-compatible provider pointed at a LiteLLM proxy that fronts AWS Bedrock.
OpenCode version
1.18.21
Steps to reproduce
Configure a provider in opencode.jsonc using "npm": "@ai-sdk/openai-compatible" pointed at a LiteLLM proxy.
Configure a model whose api.id matches gpt-5.* (e.g. gpt-5.6-luna) that LiteLLM routes to AWS Bedrock ("Bedrock Mantle").
Send any message to that model.
Request fails with:
litellm.UnsupportedParamsError: bedrock_mantle does not support parameters: ['verbosity'], for model=openai.gpt-5.6-luna. To drop these, set `litellm.drop_params=True` ...
Omit textVerbosity option for providers other than Azure (gpt-5) #2387 is the same root cause but was never fixed — closed as a one-off "unique use case" with a plugin workaround, despite a maintainer offering to add a proper exclusion. This issue is that same unresolved bug recurring for another user, now with a reproducible LiteLLM+Bedrock case and a tested fix.
Update: identified the precise trigger for why this suddenly surfaced.
We run LiteLLM as the proxy in front of Bedrock Mantle and had been silently unaffected by this OpenCode bug for months because LiteLLM itself was silently dropping the verbosity param before v1.92.0 — completion()/acompletion() omitted verbosity from the kwargs passed to get_optional_params(), so it never reached the provider at all (fixed upstream in BerriAI/litellm#32254).
We upgraded our proxy from LiteLLM v1.91.0 → v1.97.0, which includes that fix. Now that LiteLLM correctly forwards verbosity downstream, Bedrock Mantle's rejection of the parameter is exposed, and every gpt-5.x request through our @ai-sdk/openai-compatible provider fails with UnsupportedParamsError.
So: this is not a new bug in OpenCode, and not a regression from a recent OpenCode release — it's a latent bug (present since at least January 2026, per transform.ts git history) that was accidentally masked by an unrelated LiteLLM bug, and is now surfaced by LiteLLM fixing their side. The fix in #43915 is still correct and still needed — OpenCode shouldn't unconditionally send verbosity to providers that don't support it regardless of what any given proxy version happens to do with it.
Activity
github-actions commentedon Aug 21, 2026
This issue might be a duplicate of existing issues. Please check:
textVerbosityinjected for non-Azure providers on@ai-sdk/openai-compatible— same root cause (LiteLLM/Azure proxy rejecting the parameter)reasoningSummaryon@ai-sdk/openai-compatibleproviders with LiteLLM; the fix referenced in your issue ([Bug] reasoningSummary injected for Azure/openai-compatible providers — should be guarded like textVerbosity #21237 / fix(provider): guard reasoningSummary injection for @ai-sdk/openai-compatible providers #22352) addressedreasoningSummarybuttextVerbositywas not equivalently guardedjoelstucki-taulia commentedon Aug 21, 2026
Not a duplicate of either:
reasoningSummary, which was already fixed in [Bug] reasoningSummary injected for Azure/openai-compatible providers — should be guarded like textVerbosity #21237/fix(provider): guard reasoningSummary injection for @ai-sdk/openai-compatible providers #22352.textVerbositynever received the equivalent guard, which is exactly what's being reported here.Fix is up at #43915 (same allowlist approach used for
reasoningSummary), tests passing.joelstucki-taulia commentedon Aug 21, 2026
Update: identified the precise trigger for why this suddenly surfaced.
We run LiteLLM as the proxy in front of Bedrock Mantle and had been silently unaffected by this OpenCode bug for months because LiteLLM itself was silently dropping the
verbosityparam before v1.92.0 —completion()/acompletion()omittedverbosityfrom the kwargs passed toget_optional_params(), so it never reached the provider at all (fixed upstream in BerriAI/litellm#32254).We upgraded our proxy from LiteLLM v1.91.0 → v1.97.0, which includes that fix. Now that LiteLLM correctly forwards
verbositydownstream, Bedrock Mantle's rejection of the parameter is exposed, and everygpt-5.xrequest through our@ai-sdk/openai-compatibleprovider fails withUnsupportedParamsError.So: this is not a new bug in OpenCode, and not a regression from a recent OpenCode release — it's a latent bug (present since at least January 2026, per
transform.tsgit history) that was accidentally masked by an unrelated LiteLLM bug, and is now surfaced by LiteLLM fixing their side. The fix in #43915 is still correct and still needed — OpenCode shouldn't unconditionally sendverbosityto providers that don't support it regardless of what any given proxy version happens to do with it.