Uh oh!
There was an error while loading. Please reload this page.
fix(provider): guard textVerbosity injection for @ai-sdk/openai-compatible providers - #43915
Merged
neriousy merged 1 commit intoAug 21, 2026
Conversation
…tible providers Only enable the gpt-5.x textVerbosity default for integrations known to implement OpenAI's verbosity parameter (@ai-sdk/openai and @ai-sdk/amazon-bedrock/mantle). Previously the guard excluded only Azure, so generic @ai-sdk/openai-compatible providers (e.g. LiteLLM proxies) received textVerbosity as well. When such a proxy routes to AWS Bedrock behind the scenes, Bedrock rejects the resulting verbosity parameter with litellm.UnsupportedParamsError, breaking every request (including configured fallbacks) to any gpt-5.x model on that provider. This mirrors the existing reasoningSummary guard pattern fixed in anomalyco#21237 / anomalyco#22352, which textVerbosity never received. Fixesanomalyco#43911
neriousy
enabled auto-merge (squash)
August 21, 2026 22:07
neriousy
commented
Aug 21, 2026
Contributor
Thanks for the PR! |
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 freeto 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.
Issue for this PR
Closes#43911
Type of change
What does this PR do?
options()intransform.tssetstextVerbosity: "low"for anygpt-5.xmodel as long asproviderID !== "azure". That guard allows the default through for generic@ai-sdk/openai-compatibleproviders too (e.g. a LiteLLM proxy), which is wrong:verbosityis an OpenAI-specific parameter, and non-OpenAI backends behind such a proxy reject it outright.Concretely, a
gpt-5.6model routed through a LiteLLM@ai-sdk/openai-compatibleprovider to AWS Bedrock ("Bedrock Mantle") fails every request with:This is the same bug class already fixed for
reasoningSummaryin #21237 / #22352 (unconditional injection for gpt-5.x, guarded only against Azure instead of an explicit allowlist).textVerbositynever got the equivalent fix.The fix switches the check from a denylist (
providerID !== "azure") to an allowlist of providers known to actually implementverbosity:@ai-sdk/openaiand@ai-sdk/amazon-bedrock/mantle. Everything else (including@ai-sdk/openai-compatible,@ai-sdk/azure,@ai-sdk/github-copilot) no longer receivestextVerbosity, matching howreasoningSummary/includeare already scoped a few lines above in the same function.How did you verify your code works?
bun test test/provider/transform.test.ts— 411 pass, 0 fail (added an explicitexpect(result.textVerbosity).toBeUndefined()assertion to the existingopenai-compatible gpt-5 models omit Responses-only reasoningSummarytest).bun turbo typecheck— 30/30 packages pass.textVerbosityis correctly omitted from the request and the call succeeds.Screenshots / recordings
N/A — no UI change.
Checklist