Incorrect model displayed in Claude Code
Quick fix
Configure a Custom Command for ccstatusline to read the model name from the current cc-switch provider configuration.
Symptom
Section titled “Symptom”状态栏显示固定模型(例如 `Sonnet-4.6`),与代理接管后的真实模型不一致。The status bar shows a fixed model (for example, `Sonnet-4.6`), which does not match the actual model after proxy takeover.
After enabling cc-switch proxy takeover, the local session’s default model shown by ccstatusline may not update to the upstream model after proxy routing. It can remain `Sonnet-4.6` or `claude-sonnet-4-6`. The same issue also reported that billing-model details in the proxy dashboard may differ from the actual routing result, suggesting a possible discrepancy in the model attribution data source.
Add a Custom Command to ccstatusline so the status bar reads the model environment variable in the current cc-switch provider configuration. A macOS script approach was proposed; a user verified it works in Windows WSL.
On Windows, create a JavaScript file and set the ccstatusline Custom Command to `node <文件名>`; the script reads the current Claude provider's `settings_config` from `~/.cc-switch/cc-switch.db`, then outputs the model name based on the Opus, Sonnet, Haiku, or default-model environment variable.
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”This page is distilled from 1 real issues
- After switching providers in proxy mode, the model does not switch with it. Is there no solution?
- Use ccstatusline's Custom Command to read the model environment variable from the current cc-switch provider configuration; a Windows WSL user reported that this works.
- How do I use this Custom Command on Windows?
- Create a JavaScript file and enter `node <文件名>` in ccstatusline's Custom Command.
Related problems
Section titled “Related problems”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.