Repository navigation
Description
Problem
Reloading or continuing a mecatui session restores the snapshot-derived conversation (user/assistant text and top-level tool calls/results), but not every visible piece of the live session. Known losses include reasoning/thinking summaries (already tracked in #2079) and the f6 Subagents, Parallel, and Teams inventories and their bounded activity. Other event-derived UI content may also disappear; we need an inventory rather than fixing only the examples we have noticed.
Production reload rebuilds from Conversation.Messages (cmd/mecatui/ui/sessions_surface.go, internal/adapter/server/transcript.go). Live delegation projections and reasoning deltas take separate paths. The activity EventLog is optional and not an authoritative, complete replay source under ADR 0217; reaching its end does not prove that history is complete. Provider-private reasoning replay data must not be rendered as the human-visible summary.
Scope
- Inventory meaningful live conversation and session-derived UI data across the conversation, tool details, Agents/Parallel/Teams, notices, usage, changed files, and other relevant views. For each item, identify its producer, durable authoritative source (if any), reload behavior, privacy/retention boundary, and the desired restore / refetch / explicitly unavailable decision. Distinguish session data from ephemeral UI focus, filters, scroll position, and spinners, which need not survive a process restart.
- Cover the known gaps: human-visible reasoning summaries (coordinate with Restore display-only reasoning summaries when reloading sessions #2079, without reusing provider-private replay fields); Subagent child inventory/usage/traces; Parallel branch and winner state; Team roster/member activity/tasks/findings. Check other live event-derived facts rather than assuming this list is exhaustive.
- For information we agree should survive reload, define an authorized, bounded durable read/projection contract that works for both embedded and server-backed sessions. Specify interrupted runs, compaction, forks/carryover, legacy snapshots, failed writes, redaction, and missing history. Do not silently reconstruct authoritative state from best-effort EventLog events or tool-result prose.
- Test a representative live session against a new client process/model rehydrated through the production transcript and metadata path. Assert parity for durable data and honest absence for data whose contract does not support restoration. Preserve pending-approval recovery's existing exact-run, fail-closed path.
Outcome
A reviewed state-source matrix and acceptance plan(s) for any persistence/API decisions, followed by fixes and regression tests. This omnibus tracks completeness across reload surfaces; #2079 owns the reasoning-summary-specific design and should be linked, not duplicated. Follow-on to #2089 and #1361.
Activity
jbeda commentedon Oct 5, 2026
From human review of #2078: aim for reload to replace server-owned session facts from an authoritative snapshot, rather than reconstructing or merging them from an old client projection. Where a desired fact is unavailable, show honest absence for now; decide explicitly what must survive reload in this issue instead of silently preserving stale client state. This is a design direction for the fidelity work, not an instruction to change #2078 during review. #2078's approved plan currently requires specific legacy fallbacks and preservation of view-only state; revising those promises would need an explicit contract decision.
Please add to the state-source matrix the following candidate snapshot or authorized bounded-read data (not a mandate to put unbounded history into
GetSession):f6projections are built from live events, not restored by the message-only transcript.SessionSnapshotalready projects title, mode/state, placement, resolved model, main and auxiliary usage, context occupancy, and capabilities (cmd/mecatui/client/session.go). Audit their source and completeness before adding more fields. Keep ephemeral local input/selection/focus/filters/scroll position outside the server session snapshot unless separately justified. For each proposed durable addition specify owner, retention/redaction, boundedness, interruption/fork/restart behavior, and a new-client-process parity test. An optional EventLog is not a complete authoritative snapshot.The
model.goreload fields in #2078 mix request/feed ordering and retry state with conditional counter/legacy-fallback policy. Even if we simplify adoption, request/session/feed fencing is still needed to reject out-of-order responses; #2114 should distinguish that synchronization from merging session facts.