fix(opencode): guard reasoningSummary for azure in options()#21575
fix(opencode): guard reasoningSummary for azure in options()#21575jeanibarz wants to merge 1 commit intoanomalyco:devfrom
Conversation
Azure OpenAI rejects reasoningSummary as an unknown parameter. The textVerbosity guard already excludes azure but reasoningSummary in the same block did not — align them. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
The following comment was made by an LLM, it may be inaccurate: The search results show PR #21575 (the current PR itself) and two potentially related historical PRs that dealt with
No duplicate PRs found |
Issue for this PR
Closes #21237
Type of change
What does this PR do?
ProviderTransform.options()setsreasoningSummary = "auto"for all gpt-5 models unconditionally. ThetextVerbosityparameter in the same block already has&& input.model.providerID !== "azure", butreasoningSummarydoes not. This adds the same guard.Scope note:
ProviderTransform.variants()also setsreasoningSummaryfor Azure variants — that's left intentional. The existing test at line 2372 ("standard azure models return custom efforts with reasoningSummary") explicitly expects it, and the default Azure path usessdk.responses()which tolerates the parameter. This PR only fixes the asymmetric default inoptions(), which fires unconditionally regardless of API path.How did you verify your code works?
Wrote a verification script that imports the real
ProviderTransformmodule (not mocks) and exercisesoptions(),variants(), andproviderOptions()with Azure model configs matching the repo'smodels-api.jsonfixtures. Confirmed:options()no longer setsreasoningSummaryfor Azure gpt-5 modelsvariants()still does (intentional, tested by maintainers)providerOptions()wrapping correctly reflects the changeUnit tests added and all 123 existing
transform.test.tstests pass:Could not run the full repo-wide
bun typechecklocally — it fails on pre-existingBuffertype errors in unrelated files (clipboard.ts,cross-spawn-spawner.ts,db.node.ts,filesystem.ts). These same errors exist on a clean checkout ofupstream/devwithbun@1.3.11. CI should pass as it uses a different environment.Screenshots / recordings
N/A
Checklist
Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com