Repository navigation
Closed
Labels
enhancementNew feature or request
Description
Context
The /models picker restart-now flow (shipped in 08597a7) starts a new session on the picked model — a session's provider/model is fixed, so switching is a new CreateSession, not a hot-swap. The confirm overlay deliberately ships without a context-carryover option: [enter] starts fresh, [s] switches next time, [esc] undoes. The transcript is reset on restart.
This issue tracks the deferred follow-up: optionally seed the new session with the prior conversation so a model switch can feel like a continuation rather than a cold start.
Why it was deferred (not a small UI addition)
Carryover collides with three load-bearing invariants and needs a real design, not a picker checkbox:
- No history-seed surface.
CreateSessiontakes workspace/mode/limits/selector — no history.Promptcarries one user turn. Seeding history is a new wire contract and a new domain entry path that must satisfy "reopen-if-completed OR interrupt-if-cancelled" andSession.ReplaceHistory's tool-pairing validation. - Stateless replay + opaque reasoning blob. Adapters replay full history each turn;
Message.Reasoningcarries one opaque, provider-private blob per message. Carrying an OpenAI transcript into an Anthropic session (the exact cross-provider switch a picker invites) means replaying provider-private encrypted reasoning to a provider that can't decode it — ignored at best, HTTP 400 at worst. Cross-provider carryover needs a translate-or-strip anti-corruption layer the codebase intentionally avoids. - Turn-zero compaction. A carried-over history may exceed the new model's (possibly smaller) context window, forcing a compaction on turn zero against a model that never produced the transcript.
Scope when picked up
- A design doc covering: the history-seed wire surface, the cross-provider
Message.Reasoninghandling (strip vs translate vs same-provider-only), and turn-zero compaction. - Likely a same-provider-only first cut (no reasoning-blob ACL needed), with cross-provider as a later step.
- The picker confirm overlay then gains a
[c]carry-over option (currently absent by design).
References
Metadata
Metadata
Assignees
Labels
enhancementNew feature or request
Activity
feat(models): seamless model switch that always keeps the conversation (