Model selection should be per-session, not global

Resolved 💬 3 comments Opened Apr 8, 2026 by NYTC69 Closed Apr 12, 2026

Problem

When switching models via /model inside a session, the change applies globally to all running sessions. This means if I'm running two sessions — one intentionally on Sonnet for a lightweight task, and another on Opus for a complex task — switching the model in one session unexpectedly changes the other.

Current behavior

  1. Start session A with claude --model claude-sonnet-4-6
  2. Start session B with claude --model claude-opus-4-6
  3. In session A, run /model and switch to Opus
  4. Session B is now also affected — the global model setting has changed

Expected behavior

Model selection should be scoped to the current session. /model should only affect the session where it's invoked. Other running sessions should retain whatever model they were started with or last switched to.

Use case

Multi-session workflows where different tasks need different models:

  • Lightweight tasks (quick fixes, documentation) → Sonnet (faster, cheaper)
  • Complex tasks (architecture, multi-file refactors) → Opus (more capable)

Running these in parallel is common, and having them interfere with each other's model settings is disruptive.

Suggested approach

Store the model selection in session-level state rather than (or in addition to) the global config. The --model flag at startup already implies per-session intent — /model during the session should follow the same principle.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗