feat: add sonnet[1m] to hardcoded fallback model list#1107
Open
zhangyanbo2007 wants to merge 1 commit into
Open
feat: add sonnet[1m] to hardcoded fallback model list#1107zhangyanbo2007 wants to merge 1 commit into
zhangyanbo2007 wants to merge 1 commit into
Conversation
The available models fallback list included opus[1m] but was missing sonnet[1m], making it impossible to use 1M context with Sonnet models when config.toml has no explicit models configured and the API fails to return model aliases. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
chenhg5
approved these changes
May 24, 2026
Owner
chenhg5
left a comment
There was a problem hiding this comment.
LGTM. CI green, well-structured.
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.
Problem
The available models fallback list in
agent/claudecode/claudecode.goincludedopus[1m]but was missingsonnet[1m], making it impossible to use 1M context with Sonnet models whenconfig.tomlhas no explicit models configured and the API fails to return model aliases.Solution
Add
sonnet[1m]to the hardcoded fallback model list, one-line fix.Test plan
go build ./...sonnet[1m]model selectable via config🤖 Generated with Claude Code