fix(provider_registry): case-insensitive model name lookup for context_limit#8906
Open
bzqzheng wants to merge 1 commit intoaaif-goose:mainfrom
Open
fix(provider_registry): case-insensitive model name lookup for context_limit#8906bzqzheng wants to merge 1 commit intoaaif-goose:mainfrom
bzqzheng wants to merge 1 commit intoaaif-goose:mainfrom
Conversation
…t_limit Custom provider model names with case mismatches (e.g. 'GLM-5.1' in config vs 'glm-5.1' in GOOSE_MODEL) silently failed the known_models context_limit lookup and fell back to the default 128k. Use eq_ignore_ascii_case instead of strict equality in normalize_model_config so the lookup works regardless of case. Fixes aaif-goose#8752 Signed-off-by: Bright Zheng <bzqzheng@gmail.com>
Bojun-Vvibe
added a commit
to Bojun-Vvibe/oss-contributions
that referenced
this pull request
Apr 29, 2026
- aaif-goose/goose#8910 (merge-after-nits): cumulative-tokens display fix - aaif-goose/goose#8906 (merge-as-is): case-insensitive provider lookup - INDEX: append drip-179 section, table, and verdict-mix paragraph
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
Custom provider model names with case mismatches (e.g.
GLM-5.1in the provider JSON config vsglm-5.1inGOOSE_MODEL) silently failed theknown_modelscontext_limitlookup innormalize_model_configand fell back to the default 128k.Fixes #8752.
Change
Use
eq_ignore_ascii_caseinstead of strict equality when matchingmodel.model_nameagainst entries inmetadata.known_models.This is the smallest possible fix: it only affects the lookup, does not mutate stored model names, and does not change what gets sent to provider APIs.
Verification
Checklist