fix(web): record which preset a session actually runs
The creation header names the preset a session STARTED with and is frozen, which is correct — it is a creation fact. Switching is legal only while a session is blank, and that looked like enough: no history exists yet. It is not, because the switch's effect outlives the blank window. The user switches, then sends the first message; every turn from there runs under the new composition while the header still names the old one. The session is then locked around a misrecorded preset, and resume reads the header to rebuild it — composing one preset's tools over a history another produced, which is exactly the replay the blank-only lock exists to prevent, reached by another route. A picker showed `standard` for a session running `core-web`. A switch is now an `agent-preset/selected` event appended after the swap commits, and `resolveSessionPreset()` (last selection, else the header) is what every reconstruction reads: the summary, resume, the conflict guard, and the fork introduced one layer down.
This commit is contained in:
3
pnpm-lock.yaml
generated
3
pnpm-lock.yaml
generated
@@ -1113,6 +1113,9 @@ importers:
|
||||
'@deepseek-ai/dsh-client-runtime':
|
||||
specifier: workspace:^
|
||||
version: link:../../client/runtime
|
||||
'@deepseek-ai/dsh-client-ui-agent-preset':
|
||||
specifier: workspace:^
|
||||
version: link:../../client/ui-agent-preset
|
||||
'@deepseek-ai/dsh-client-ui-command':
|
||||
specifier: workspace:^
|
||||
version: link:../../client/ui-command
|
||||
|
||||
Reference in New Issue
Block a user