Feature Enhancement: Specify Model per Prompt
Current Behavior
Currently, when using Claude Code, switching between different models (Opus and Sonnet) within the same workflow requires manual intervention (_/model_). Specifically, if I wish to plan using Opus due to its superior reasoning capabilities and subsequently implement code changes using Sonnet for its higher limits, I need to:
- Submit the initial prompt using Opus for planning.
- Reject the plan returned by Opus.
- Manually switch the model from Opus to Sonnet using "_/model_".
- Prompt Sonnet explicitly to implement the plan previously outlined by Opus.
- Repeat this manual process each time.
This workflow significantly impacts productivity and efficiency.
Requested Feature
Implement the ability to explicitly specify which model to use directly within each individual prompt. Ideally, this would be a simple parameter or option within the prompt UI or through a clearly defined syntax within the prompt itself.
Example use case:
- Prompt:
[model:opus] Please outline a detailed plan for the requested feature.
- Follow-up prompt:
[model:sonnet] Now implement the outlined plan as Python code.
_Alternative Approach_
Another viable solution could be adding settings to the ./.claude/settings.local.json file, allowing users to configure default behaviours based on workflow modes. For example, users could specify:
{
"plan_mode_model": "opus",
"auto_accept_edits_model": "sonnet"
}
This would automatically select Opus when "plan mode" is activated and Sonnet when "auto-accept edits" mode is on, reducing manual intervention
Benefits
- Streamlines workflow, significantly reducing manual steps.
- Allows optimized use of models based on their strengths (Opus for deep planning, Sonnet for coding).
- Enhances productivity and efficiency by avoiding repetitive and unnecessary manual model-switching.
- Reduces unnecessary consumption of resources from more limited or expensive models.
Thank you!
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗