Repository navigation
internal/clients/claudecode: let Claude Code pick its model when Claude is offered - #60
Merged
Merged
Conversation
…de is offered A first headless `aperture claude` took the provider's first model, and on ai.corp that sorts to alibaba/qwen3.8-max. Claude Code in auto mode asks the API for server-side classification, Qwen returns none, and the session falls back to billed classifier requests with the "this session isn't eligible" notice. Once a release drops that fallback, every checked action would be prompted or denied. Taking the first Claude model instead would launch claude-haiku-4.5, an old small model, because the list is alphabetical. Leaving ANTHROPIC_MODEL unset lets Claude Code use its own current default, which Aperture resolves. Providers with no Claude model keep the first-model default. Revisit if providers advertise a preferred model, or if Claude Code's default stops resolving on some Aperture.
A provider listing "Anthropic/Claude-Opus-5-5" next to "openai/gpt-5" got gpt-5 as the default, because the Claude check was case-sensitive. Aperture model ids are usually lowercase, but aliases come from operator config.
lkosewsk
approved these changes
Nov 20, 2026
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.
A first
aperture claudewith no--modelnow leavesANTHROPIC_MODELunset when the provider offers any Claude model, so Claude Code uses its own default. Providers with no Claude model still get their first model.Before this, the default was the provider's first model, and the list is alphabetical. Claude Code in auto mode asks the API for server-side classification and the session falls back to billed classifier requests with the "this session isn't eligible" notice. Once Claude Code drops that fallback, every checked action would be prompted or denied.
Picking the first Claude model instead would launch
claude-haiku-4.5, an old small model, for the same alphabetical reason. Claude Code's own default is current and Aperture resolves it.The check is a substring match:
An explicit
--modeland a replayed last model on the same provider still win over this default.