Skip to content

There's an issue with the selected model — model mapping failure - CC Switch

Quick fix

Upgrade CC Switch, restart the target tool, and start a new session so local routing strips the [1m] suffix and rematches the mapping.

Error output
There's an issue with the selected model (claude-haiku-4-5[1m]). It may not exist or you may not have access to it. Run --model to pick a different model.

With a 1M context or in some mapping scenarios, Claude Code and Claude Desktop send the model name with a [1m] suffix, for example claude-haiku-4-5[1m]. Older cc-switch local routing matched that raw model name against the routes on the provider (claude-haiku-4-5), so nothing matched, model mapping never ran, and Claude Code reported that the selected model may not exist. A maintainer explained in issue #3588 that the trailing [1m] is now stripped at runtime before model mapping.

The same family extends to incomplete or overwritten config writes after switching or editing a provider for Codex/Hermes/OpenCode: model_provider forced back to ccswitch (#2934/#3029), the Codex model name still holding its old value (#5229/#3416/#6225), Hermes base_url/api_key not updating (#4176), OpenCode small_model disappearing (#3856), settings.json not overwritten (#2539). All of these point at the same config-overwrite path. The issues sometimes contradict each other — #5591 argues the UI only shows the internal Claude model name and does not necessarily indicate a real mapping error — so when troubleshooting, check the model name actually sent upstream.

  1. Upgrade CC Switch to the latest version, at minimum one containing the #3588 fix that strips the [1m] suffix, plus the Codex/routing fixes in #3029/#3999/#4996.

  2. Quit and restart CC Switch and Claude Code / Claude Desktop / Codex completely. An existing Claude Code session may still cache the wrong model name, so start a new session and try again.

  3. Switch the target provider once more in CC Switch. If the target app is Codex/Hermes/OpenCode, open its actual config file and confirm model_provider, base_url, api_key, and small_model now hold the new values; fill in anything missing by hand, or switch again.

  4. If the problem only appears in VS Code plugin sessions, restart VS Code or start a new session — older plugin versions do not hot-reload model config (#4269).

ToolClaude Code
VersionUnknown
PlatformsWindowsmacOS

This page is distilled from 23 real issues

The session reports this selected model error right after I upload an image. Why?
In #3388 a user reported this error triggered after uploading one image, and a new session recovered it. It is related to the [1m] model name failing to match, not necessarily to broken image support.
I changed the model in CC Switch — why does Codex still use the old model name?
Older versions may not update model_provider or the model catalogue when writing Codex config. Upgrade, switch once more, and check the actual config file.
The mapping error shows an internal Claude model name. Does that mean mapping failed?
A maintainer explained in #5591 that a failed request records the internally mapped Claude model name, which does not necessarily indicate a real mapping error. Check the model name actually sent upstream.
Do I have to restart the VS Code plugin after switching provider?
#4269 reports that older versions needed a VS Code restart to hot-load the model. If it still happens after upgrading, try restarting or starting a new session.

This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.