Two people can share an agent daemon without sharing the same model choice. That sounds obvious until an idle session goes away and comes back: if a model switch also rewrites the global setting, Session A can wake up configured like Session B.
Qwen Code’s merged session-model change takes that leak seriously. The public commit credits Cursor as a co-author; the attribution establishes coding-agent involvement in this implementation, not how the work was divided. What matters for builders is the craft in the source: a successful daemon-side switch records a compact session_model entry with the canonical model, auth type, and, only when appropriate, the configured registry route.
Restore the choice before it becomes a failed login
The inspected design note draws an important boundary. New sessions may still inherit the current settings default; cold daemon loads and resumes may instead read the last valid session record. Resume remains read-only, so merely reopening a conversation does not manufacture a transcript for an otherwise empty session.
The restore code applies that record before authentication, but does not trust it as a free-form endpoint. It accepts only known authentication types and registry-resolved routes; a missing runtime snapshot or unavailable credential can fall back to the settings model and retry authentication. The matching test file adds 1,117 lines around malformed records, legacy assistant-model fallback, route mismatches, snapshots, and failure recovery. That is not a preference toggle. It is a recovery protocol with a deliberately small record format.
The transferable skill: record intent at the right boundary
For anyone building durable agents, the reusable move is to persist the user’s session-level intent only after the switch succeeds, then replay it before the systems that depend on it initialize. Make the record last-wins but validate it like untrusted state; keep an explicit fallback; and do not let recovery writes mutate the thing they are trying to restore. That separates a session’s identity from the mutable default meant for the next new session.
The public evidence is main-branch code and focused tests, not a release receipt or a guarantee that every provider configuration will restore cleanly. The next useful signal is a released daemon build with an end-to-end reproduction: two sessions select different providers, the daemon restarts, one stored route disappears, and the surviving session retains its own model without borrowing the other one’s default.