Repository navigation
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Summary
The setup wizard tests a newly entered API key by sending a tiny prompt, but it
does that against models that have been retired, so a valid key fails the check
and never gets saved.
claude-sonnet-4-20250514, retired 2026-06-15.gpt-4-turbo-preview, retired 2026-03-26.Both calls come back as errors, so
setupAnthropicKey/setupOpenAIKeyprint"API key validation failed" and drop the key. The OpenAI provider's
defaultModelinsrc/config/index.tsis the same retiredgpt-4-turbo-preview,so even a saved OpenAI key would point at a dead model.
Sources:
gpt-4-turbo-preview→gpt-4-0125-preview, shut down 2026-03-26)claude-sonnet-4-20250514retired 2026-06-15 →claude-sonnet-5-5)What changed
claude-sonnet-5-5(active; recommended replacement).gpt-5.6-sol, and use it as the OpenAI providerdefaultModel. I pickedgpt-5.6-solovergpt-5/gpt-4.1because those havenear-term shutdown dates, while
gpt-5.6-solcurrently has none — so thisshouldn't need touching again at the next retirement.
temperatureto the Anthropic Messages API. This part is neededfor the fix to actually work:
temperature/top_p/top_kwere removed in APIversion
2026-10-21and are already rejected (400) as non-default values onClaude 4.7+ models (which
claude-sonnet-5-5is) on earlier API versions. Theadapter sent
temperature: 0, so swapping in a current model alone would stillfail validation. Anthropic's own guidance is to omit these and use prompting.
(This also unblocks every other Anthropic call in the app, which hit the same
wall with the
claude-opus-4-8default.)Added a static invariant test in the repo's existing style
(
src/__tests__/setup-model-validation-static.test.ts, modeled onlocal-openai-wire-static.test.ts) that pins the current model ids and thedropped sampling params.
Linked issue
None — this is an unreported break (no open or recent issue references these
model ids or the validation failure).
Prior work and attribution
Contribution receipt
Verification
I didn't run the suite locally for this draft, so the checklist below is honest
about that. The change is small and pinned by a static invariant test; worth a
npm run test:prbefore merge.npm run typechecknpm testnpm run doctorRisk and rollback
temperaturemeans Anthropic calls use the API defaultsampling; the app can no longer pin temperature for Anthropic, but it couldn't
anyway on current models (the API rejects it). OpenAI is unchanged and still
accepts
temperature.🤖 Generated with Claude Code