[BUG] /clear command automatically switches model to Opus
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
When I execute the /clear command in VSCode Claude Extension, the model automatically switches from my configured default setting to Opus without any notification. The settings still display "default" as the selected model, but the actual model being used is Opus. This silent model change caused me to unknowingly consume all my Opus tokens while thinking I was using the default model. There was no indication in the UI that the model had been switched, leading to unexpected token depletion and costs.
What Should Happen?
- The /clear command should only reset the conversation context and preserve the user's configured model selection
- If the model must be changed for any reason, users should receive a clear notification
- The model shown in settings should always match the actual model being used
- Users should be aware of which model they are currently using to manage their token usage appropriately
Error Messages/Logs
Steps to Reproduce
- Open VSCode with Claude Extension installed
- Go to Claude Extension settings
- Set the model to "default" (not explicitly selecting Opus or Sonnet)
- Start a new conversation with Claude
- Verify you're using the default model
- Execute the /clear command to reset the conversation
- Continue the conversation
- Observe that:
- Settings still show "default" as the model selection
- However, the actual model being used has been switched to Opus
- No notification or warning was displayed about this change
- Token usage reflects Opus consumption despite expecting default model usage
Result: Opus tokens are consumed without user awareness, potentially depleting the entire quota.
Claude Model
Sonnet (default)
Is this a regression?
Yes, this worked in a previous version
Last Working Version
_No response_
Claude Code Version
2.0.49 (Claude Code)
Platform
Anthropic API
Operating System
macOS
Terminal/Shell
VS Code integrated terminal
Additional Information
<img width="482" height="168" alt="Image" src="https://github.com/user-attachments/assets/3d82c607-10f7-4863-a54e-f187969572f4" />
<img width="388" height="241" alt="Image" src="https://github.com/user-attachments/assets/28e49c33-ed58-43d5-9c95-534838deced3" />
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗