# Proof audit, pass 1

Scope: [#29835](https://git.cafe/pingdotgg/t3code/pull/29835), also mirrored as [#29835](https://github.com/pingdotgg/t3code/pull/29835). Reviewed the complete six-file local diff `git diff origin/main...5fb9d0e979` in `/home/ubuntu/wt/pr-29835`, branch `pr-29835`, against the local `origin/main` ref. Local head: [5fb9d0e979](https://git.cafe/pingdotgg/t3code/commit/5fb9d0e979c2f061f40f9b01b06d3851156072b8). The local commit was not pushed at audit time; the forge still reports [827452e468](https://git.cafe/pingdotgg/t3code/commit/827452e4684d16a15076c2305a615327e62c4d09). Its existing checks, review statements and old evidence do not prove this local revision. No worktree edits, provider turns, browsers, servers, tests, pushes or PR comments were performed in this pass. This document is a fixture plan, not a runtime transcript.

## Findings

1. **Proof is missing at the requested local revision.** Three new integration-test scenarios cover background work, delegated follow-up completion and ineffective compaction followed by replacement. Source inspection is not an executed test result. There is no new runtime capture in this pass. The added test adapter implements `compactThread` by calling its ordinary `startTurn`, emits an assistant response and usage, and does not emit a compaction item. It proves neither the native compaction protocol nor the finished client marker. The minimum proof is focused test execution plus short, explicitly labelled runtime transcripts. Screenshots alone cannot prove native session identity, backlog delivery, queue ordering or parent task settlement.
2. **The claimed finished marker has a provider-dependent exception.** Both client renderers need a compaction turn item to turn an `onReturn` prompt into “Context compacted before sending”. Without an item, their finished fallback is “Context compaction”. Cursor exposes `compactThread` and sends native `/compress` with SDK summarization, but its adapter contains no compaction-item emission. The current synthetic integration adapter also omits one. R07 therefore contradicts a universal marker claim. Either demonstrate an actual item through an additional path, narrow the claim, or have the lead address the missing marker. This is a source-derived proof-contract mismatch, not a claim that the new recovery necessarily fails.
3. **Queue and recovery exits need their own proof.** The new three-case test does not enqueue another request or a notification, hold a queue, Stop a run, fail compaction, reject a stale terminal event, or observe delegated failure/Stop through the parent. Those are distinct branches of the changed handler. The snooze test adds a server-source case, but a full recovery through both server messages is not captured. The changed `automaticWake` condition covers all agent-created/server-sourced messages, not only this recovery.
4. **No client render code or prop contract changes.** This is new data flowing through existing web, desktop, mobile and guest render paths. `compactionRecoveryOfRunId` is an optional dispatch-command field; clients do not render it. Its server effect is preserving an existing `delegatedTaskId` on the new runs. The new failure code is carried by the existing failure shape (`class: provider_error`, `retryable: null`), with no new client-specific failure branch. No viewport-by-theme screenshot expansion is justified for this server-only change.

## Complete changed-path inventory

Source locations below refer to the reviewed local checkout. Local source links are for the reviewer in that workspace; the unpublished commit is not yet available from the forge.

| Changed unit | Callers and consumers | Branches and observable data | Fixture coverage |
| --- | --- | --- | --- |
| [ProviderTurnStartService.ts:1282](/home/ubuntu/wt/pr-29835/apps/server/src/orchestration-v2/ProviderTurnStartService.ts:1282) | `EffectWorker` executes `provider-turn.start` and retry paths through `ProviderTurnStartServiceV2.start`; chat, mobile, agent/MCP, scheduled and notification intake converge on the same orchestration path. Recovery reaches the same service. `RunExecutionService` chooses `compactThread` for the bare `/compact` message. | New branch only after successful native resume and budget rejection, with `compactThread`, no effective handoffs, ordinary input, no goal command, and no previously started compaction. Otherwise preserve fit/resume, fresh-session, failed-resume, uncertain-delivery, switch, unsupported and replacement paths. New error item precedes failed run/attempt/root-node settlement; provider receives no ordinary turn for that failed run. | R01–R02, R15–R18, R24–R30 |
| [Orchestrator.ts:2363](/home/ubuntu/wt/pr-29835/apps/server/src/orchestration-v2/Orchestrator.ts:2363) and [terminal handler:13812](/home/ubuntu/wt/pr-29835/apps/server/src/orchestration-v2/Orchestrator.ts:13812) | `handleRunUpdate` consumes persisted `run.updated` events; internal recovery dispatch uses `dispatchWithReceiptEffect`, then optionally starts the queued recovery by run ID. Other terminal processing still releases unattended holds and promotes queued runs. | Failed latest root with matching code => server `/compact`, no attachments, `idleCompaction: onReturn`; completed server-source `onReturn` compaction => server “Continue where you left off.” Other statuses, non-recovery completions, nonlatest events, root failures with a different code, or any run-interrupt request produce no recovery dispatch. Deterministic command/message IDs must not create duplicate steps. Catching recovery dispatch errors logs a warning and follows normal queue handling; a dispatch/start failure must not masquerade as successful recovery. | R02–R18, R24–R26, R31 |
| [Orchestrator.ts:5578](/home/ubuntu/wt/pr-29835/apps/server/src/orchestration-v2/Orchestrator.ts:5578) | Shared `message.dispatch` planning; `continuedTaskId` is copied at the queued, same-provider and provider-switch run-construction sites. Source run uses `restartContinuationOfRunId` first, otherwise `compactionRecoveryOfRunId`. Parent finalization reads the newest run for that delegated task. | Both new steps keep the follow-up task. Parent must not settle from the intermediate compaction-needed failure or the compaction run's answer. Final success/failure/interruption comes from the continuation or last recovery run. No task ID is invented for a normal standalone thread. | R08, R19–R21 |
| [Orchestrator.ts:5609](/home/ubuntu/wt/pr-29835/apps/server/src/orchestration-v2/Orchestrator.ts:5609) | Same dispatch planning, after settlement override handling. | Notification, delegated completion, or agent+server source preserves snooze; an ordinary user send clears it. Both recovery messages use agent+server. | R22–R23, R26 |
| [orchestrationV2.ts:3166](/home/ubuntu/wt/pr-29835/packages/contracts/src/orchestrationV2.ts:3166) | Optional command schema field consumed only by server dispatch planning. Existing WebSocket command transport uses this schema; existing projections already carry delegated task IDs. | Field omitted remains valid; present field preserves task linkage. Public RPC stamps user provenance, so a driver cannot honestly fabricate server-created recovery simply by setting `createdBy: agent`. | R08, R19–R21, R31 |
| [failure.ts:38](/home/ubuntu/wt/pr-29835/packages/provider-core/src/server/failure.ts:38) | Only production constructor call is in `ProviderTurnStartService`; `settleStartFailure` passes the error's own message and `makeProviderFailure` reads its code. Orchestrator tests the latest root error code. Existing clients read title/message/class. | Title “Conversation compaction needed”; code `context_compaction_required`; exact message “The conversation is too long to continue as is. T3 Code is compacting it and will continue automatically.” It is a normal failed provider-error row, not a usage-limit warning or a workspace Retry control. | R02, R08, R12, R19 |
| Changed test files | `ProviderSwitch.integration.test.ts` adds three parameterized scenarios; `runtimeLayer.test.ts` adds server-source snooze to an existing table. | Synthetic context usage, native-generation count, failed run code, completed recovery sequence, Request 3 delivered, delegated parent result; server-source message preserves snooze. No compaction-item or real-provider proof. | Source support for R02–R03, R07–R08, R17, R19, R22; capture missing for all |

## Existing render paths, shapes and interactions

| Surface / caller chain | Existing renderers and layout-relevant inputs | Interaction/time variants relevant to this diff |
| --- | --- | --- |
| Web main chat: `ChatView -> ThreadTimeline -> MessagesTimeline` | `MessagesTimeline.logic` maps run IDs, latest/running run, status, start times and `isWorking`; `TimelineWorkEntryRow` shows error title/message/class; `WorkingTimelineRow` shows compacting activity; `ContextCompactionTimelineRow` shows compaction divider; `TimelineUserMessageRow` shows continuation attribution; existing assistant rows show streamed/final output. | Latest failure becomes historical when recovery starts and remains visible. Bare compact prompt is suppressed in favor of working/divider rows. Before a native item exists, working state is “Compacting…”; active item, terminal item and failed item differ. Completed token counts render before → after; absent counts use label/title substitution. A failed item shows failure icon and optional truncated summary. No item leaves the generic fallback. Continuation has “Sent by T3 Code”; generated messages have empty attachments and no schedule/guest attribution. Run/work folds, copy actions and timestamps retain their existing behavior. |
| Web shared guest: `GuestPage -> MessagesTimeline` directly | Same row renderer; guest supplies projected runs/items and activity state, disables rollback and uses its existing guest controls. No changed guest component. | Same data-dependent failure/compaction/continuation rows if shared. Existing guest permissions do not become recovery controls. A guest path is a compatibility read of synthetic shared data, not a reason for another token-filling run. |
| Desktop | Wraps the same web chat/timeline; no changed Electron/IPC path. | Same transcript and row decisions. No desktop-only layout branch added. |
| Mobile: `ThreadRouteScreen -> ThreadDetailScreen -> ThreadFeed` | `threadActivity` builds feed and labels; `ThreadFeed` uses `ThreadContextDivider` for compaction prompt/item, user bubble for continuation, existing assistant rows; `thread-work-log` shows full normal failure message. | Before-item compact prompt and compaction activity item are separate feed shapes; active/terminal, counts/no-counts, failed/summary and no-item fallback differ. Mobile copy is long-press; failed normal error is not a usage-limit warning. Grouped work/run disclosures and assistant streaming use existing logic. Compacting activity need not have the same geometry as web. |
| Queue and Stop: web `ChatView -> QueuedRunsControl` plus `ChatComposer`; mobile `ThreadQueueControl` and `ThreadComposer` | Existing `queuePosition`, `queueHeld`, active run and status drive queued preview/count, held/resume and Stop state. | Automatic work must wait behind both recovery steps; unattended holds release after successful continuation, human holds persist; Resume/Stop/promote/cancel are existing interactions. Proof must follow sequence, not only final empty queue. |
| Parent task: web `V2LifecycleRow -> SubagentTimelineLink`, `SubagentNotificationLink`, `ProviderSubagentBar`/tooltip; mobile `ThreadSubagentGroup -> SubagentRow` and existing agent inspector | Existing task ID, child link, status, result, progress and timestamps. Live parent projection can override historical task item. | Waiting/running through recovery versus final completed result, final failed result, or interrupted task. Opening child thread / expanding result is existing UI. Parent result must be continuation output, not compact output. A normal native background agent is not itself the app-owned follow-up task under test. |
| Snooze/sidebar and attention | Web `Sidebar`, `BackgroundThreadAnnouncer`; mobile `ThreadNavigationSidebar`; shared settled/snoozed state. | Recovery preserves exact `snoozedUntil`, so it does not unexpectedly return a snoozed thread to the active shelf or announce it. Human send and explicit unsnooze remain ways back. No reason to wait until a real snooze deadline. |

No changed frontend component has additional new callers or props. Existing unrelated attachment grids, Markdown/table rendering, settings layouts and provider picker layouts are not new fixture dimensions. Every incoming request entry point uses the server branch; there is no new Settings/command-palette/keybinding control or new MCP tool to capture.

## Provider feasibility on this VM

Observed without sending any model requests:

- `codex login status`: API-key login, not a demonstrated first-party OAuth session.
- `claude auth status`: logged in, first-party OAuth-token method. This is credential status, not proof that a live turn will succeed.
- OpenCode, Pi and Grok executables are installed. OpenCode auth listing reports no stored credentials and an environment-provided xAI credential. The brief supplies the proxy reachability assumption; this pass did not validate model routing.
- Cursor's API-key environment variable is present. Its adapter uses the SDK, so a missing standalone Cursor CLI is not decisive.

| Provider family | `compactThread` route at reviewed source | Realistic proof route |
| --- | --- | --- |
| Codex | Native `thread/compact/start` | Possible with the configured API-key service if routing accepts it; do not claim first-party OAuth or a successful turn from login status. Native integration proof can use labelled adapter replay/harness. |
| Claude | Native `/compact` through `startTurn` | OAuth status makes a smoke turn plausible, but availability and any launch restrictions remain untested. No need to depend on it for this pass. |
| OpenCode, including v2 | Native `/compact`; emits compaction items | Viable with the proxy configuration from the brief after a routing smoke check. Suitable for count-free finished-marker proof. |
| Pi | Native `/compact`; emits compaction items and optional token counts | Viable with the proxy configuration from the brief; suitable for a live marker/count path if telemetry supplies both counts. |
| Grok | ACP flavor explicitly sets `supportsCompaction: true`; ACP emits a completed compaction item | Strong live candidate given installed CLI, environment credential and reachable proxy in the brief. Count-free marker path. |
| Cursor | Native `/compress`, SDK `summarize: true` | API key makes a live smoke plausible. Treat completed no-item fallback as R07 until actual event evidence establishes otherwise. |
| Muse; Kiro; other ACP flavors | Muse exposes compaction; Kiro uses ACP `compactSession`; generic ACP only when flavor supports compaction | Not established as available here; use labelled harness where relevant, not an availability claim. |
| Antigravity / ACP without compaction | No `compactThread` (`supportsCompaction: false` for Antigravity) | R28 control uses a harness adapter with the method omitted; no need to install another provider. |

Cheapest realistic proof: run the existing server integration harness with synthetic usage and a tiny missed prompt; record the events/adapter calls. It avoids paying to fill a real context window and avoids native auto-compaction racing the desired state. For a native smoke, choose the least expensive available model with the smallest *reported real* context window, retain synthetic codewords and stop once the budget guard is reached; exact model identifiers must stay out of uploaded evidence. A manually sent `/compact` proves native compact support only, not this recovery trigger. A lowered handoff cap or fabricated usage must be labelled as a forced-budget/harness case, not a naturally full native session.

## Seeding recipes and evidence format

**A — real app, fresh DB.** The lead, not this review sub-agent, can start the dev server with `T3CODE_DEV_SEED=0`, explicit isolated home under the lead's scratch directory, and its tracked spawn PID. Do not copy a database or use live userdata. Drive `projects.mutate` as appropriate and `orchestration.dispatchCommand` (`thread.create`, `message.dispatch`, `provider-session.detach`, `thread.snooze`, `run.interrupt`, queued-run commands and `delegated_task.request`) using the real authenticated RPC client, or perform the same actions in UI. Read `orchestration.getThreadProjection` and subscribe to stored events. Use existing instance settings RPC only inside this isolated server. Public RPC stamps user provenance; it cannot be used to forge server-created recovery messages. Let the server produce those. Normal app RPC cannot set token usage, provider events or arbitrary terminal run states.

**A-full — live trigger, optional.** Create a synthetic conversation; obtain genuine usage near the server's handoff guard, which reserves at least 16,000 tokens or one quarter of the window. Retain a small unique original codeword. Create one genuinely undelivered request containing a second codeword by a controlled isolated provider launch/start failure, then restore the provider and detach/resume. Use a supported dev-only provider instance setting or a scratch launch wrapper where the provider permits it; do not corrupt native sessions or change global credentials. Send the final short query. Require missing backlog history, not just a large current prompt. Keep native background work alive for the corresponding row. If controllably failing startup or attaining the usage threshold is impractical for a provider, use H and label the row; do not silently inject state into the app database.

**H — labelled server integration harness.** Use the existing `ProviderReplayHarness.layerWithRegistry`/`ProviderSwitch.integration.test.ts` pattern with an isolated scratch driver and synthetic adapter. All scratch, temp roots, native fake files and logs belong under `/tmp/lead-29835-r1/proof-audit-1/`; the lead can redirect `TMPDIR` and all runner caches there for execution. Reproduce the existing test's synthetic window 258,400 / used 250,164, original accepted request, a fail-before-provider-turn second request containing a short codeword plus 6,000 synthetic filler characters, two detach/resumes and third request. Emit 20,000 usage after compact, or retain 250,164 for ineffective compact. Capture adapter `compactThread` versus ordinary `startTurn`, injected/inline history and native identity. The existing helper emits no compaction item; H must explicitly emit the row-specific provider item to exercise marker/count variants, or use labelled native-adapter replay. Do not call this a live provider capture. Parent/event-sink synthetic setup is allowed inside the isolated harness and must never be represented as app RPC seeding. It writes no real app database.

**H-gates.** Gate provider acceptance, compaction item start/end, terminal run handling and queue intake with Deferred/Queue milestones; drain the effect worker and await persisted events. No sleeps, clock deltas, polling or timeouts to manufacture order. Public RPC/UI cannot reliably hit these boundaries; use H for races/Stop-at-terminal/stale-event/dispatch-failure variants.

**H-parent.** Use `delegated_task.request` and a follow-up to the same child in the harness, or reproduce the new test's synthetic app-owned parent/task event-sink setup. The original task is completed; the follow-up has a distinct waiting task ID. Assert that all recovery runs keep that ID, and record parent task status/result and completion delivery. For a real app use actual delegate intake/UI/agent tools, not forged lineage.

**T — minimum capture type.** `recording`: an ordered, normalized runtime transcript with command receipts, persisted event sequence, run/message IDs, statuses, failure title/message/code/class, idleCompaction/provenance, compaction item/status/counts/summary, native thread equality, adapter operations, history codewords, queue holds and parent task result as applicable. Include post-reconnect projection for R31. Normalize synthetic IDs, omit runtime model identifiers and credentials, and distinguish observed data from source-inferred client labels. Each row can be a segment of a shared transcript. No viewport/theme dimension is required for T. If the lead chooses visual confirmation, one ordinary web viewport/theme is sufficient to corroborate existing rendering; mobile/guest-specific rendering needs its own labelled client recording if claimed. A still image cannot replace the ordered server transcript.

## Fixture matrix

Status applies to evidence at the local reviewed head, not to the existence of test source. **MISSING** means planned, not captured or executed in this pass. All temporal/interaction fixtures are explicitly marked **recording**. “Control” means the diff should preserve the existing behavior.

| ID / fixture | Diff impact | Minimum synthetic data and observable result | Existing client paths | How to seed | Minimum capture / status |
| --- | --- | --- | --- | --- | --- |
| R01 Fits resumed session | Control | Same provider/native ref, ordinary message, missed-history budget fits. Ordinary run completes; no classified failure or generated recovery. | Main/guest/mobile timeline, run status | A small conversation; or H with low usage | T recording; MISSING |
| R02 Needs compaction | New | Successful native resume, missed history, exhausted budget, compact method, no effective handoff, previous started run ordinary. Error item with exact title/text/code/class; run/attempt/root fail before provider ordinary turn acceptance. | Normal error work row; current then historical failure | A-full; cheapest H base | T recording; MISSING; new test asserts code/terminal sequence only |
| R03 Compaction before native item | New data | Recovery message `/compact`, empty attachments, `onReturn`, agent+server source, recovery link; compact run starts on the original native ref, no item yet. Web compacting working row; mobile prompt divider. | Web working row; mobile compact prompt | H-gates before item; A-full may pass through briefly | T recording; MISSING |
| R04 Native compaction running | New data | R03 plus running compaction item. Active compacting display, prompt suppressed/folded, no duplicate active divider/working row on web; no premature continuation. | Working/compaction rows; mobile activity divider | H-gates emit running item; Pi/OpenCode native stream where available | T recording; MISSING |
| R05 Completed compaction with counts | New data | Completed compaction item, before/after token counts, matching `onReturn` message. Finished title “Context compacted before sending” plus counts; one continuation is dispatched. | Web token-count divider; mobile token-count label | H emit both counts; A-full with Pi or other count-emitting provider | T recording; MISSING; helper lacks item |
| R06 Completed compaction without counts | New data | Completed item titled “Context compacted”, no counts. Same onReturn title without numeric transition; continue once. | Web/mobile label replacement | H omit counts; native Grok/OpenCode is realistic | T recording; MISSING; helper lacks item |
| R07 Completed compaction without item | New data / claim exception | Compact run completes but emits no compaction item. Continue still starts, generic “Context compaction” fallback remains; no finished onReturn title. | Web prompt fallback; mobile prompt fallback | Existing H helper, or Cursor native SDK compact | T recording; MISSING; universal finished-marker claim CONTRADICTED by source |
| R08 Continuation and recovered requests | New | Generated “Continue where you left off.” agent+server message; same native ref, ordinary startTurn, both original and previously undelivered codewords available, streaming then completed answer, no second compact. Classified failure remains historical. | User attribution, assistant streaming/final, failure history | H base or A-full; read event stream and final projection | T recording; MISSING; new test checks Request 3, not all requested codeword fidelity |
| R09 Ordinary queued work waits | New queue path | An unheld background notification/queued ordinary request waits before compaction; compact then continue run first, then queued work starts. No loss or duplicate prompt. | Queue previews/count and status, notification row | H-gates enqueue before terminal handling; A-full queue via UI/RPC | T recording; MISSING; not in new three-case test |
| R10 Unattended held queue releases | New queue path | R09 with `queueHeld: true` automatic notification/agent/scheduled work. Recovery bypasses hold by ID; successful continuation releases unattended hold and work resumes. | Held/resume queue display | H-gates with held unattended messages; real app needs a prior genuine failure to establish hold | T recording; MISSING |
| R11 Human held queue remains | New queue path / existing reverse action | R10 with genuinely user-authored queued work. Recovery completes; human hold remains. Explicit Resume starts it. | Queue Resume and held count; composer | H with user provenance/hold; A UI/RPC Resume after recovery | T recording; MISSING |
| R12 Stale or ineligible terminal event | New guard/control | Older run terminal arrives after newer execution, or failure's latest root code differs/non-root error merely contains new code; nonterminal/rolled-back statuses do not create recovery. Record only guard-relevant deltas. | Existing newer run/status and ordinary error data | H-gates; not reliably seedable through app RPC | T recording; MISSING |
| R13 Stop wins terminal race | New guard | Latest failed/completed candidate already has `run_interrupt_request`, including compaction completion arriving late. No automatic compact/continue from stopped run. | Stop/status and historical error/divider | H-gates record interrupt request before terminal reaction | T recording; MISSING |
| R14 Stop during compact | New reachable exit | Compact run interrupted/cancelled; optional interrupted compaction item, no continuation. Background/task effects follow existing Stop behavior. | Interrupted compaction/status, composer Stop | A run.interrupt/UI Stop; deterministic H-gates | T recording; MISSING |
| R15 Compaction start fails before item | New reachable exit | Compact adapter call/start fails with ordinary failure and no compaction item. No continue; queued work follows normal failure hold; generic compact placeholder plus error, not a success marker. | Error row, generic placeholder, held queue | H adapter start failure; real app needs controlled native compact failure | T recording; MISSING |
| R15a Compaction item fails without summary | New reachable exit | Running compact item becomes failed, no summary. Failed icon/title and ordinary error, no continuation; queue held. | Failed compaction divider and error | H-gates emit failed item without summary | T recording; MISSING |
| R15b Compaction item fails with summary | New reachable exit | R15a plus synthetic failure summary. Summary appears in divider/accessibility text; web truncates long summary while ordinary error text remains visible. | Failed divider with summary; error | H-gates emit failed item with summary | T recording; MISSING |
| R16 Continuation fails | New reachable exit | Compact succeeds, continuation ordinary turn fails. Preserve final ordinary failure, no compaction retry loop; queue held as existing failure policy requires. | Historical marker plus final error and queue | H fail ordinary continuation; A controlled provider failure after compact | T recording; MISSING |
| R17 No room after compact; replace | New guard/fallback | Compact reports unchanged high usage, last started run is compact, no background work. Continuation replaces native ref once, transfers history, completes; no second compact. | Existing handoff/recovery data and final assistant | H unchanged usage, pending work false | T recording; MISSING; new “no room after compacting” test source |
| R18 No room after compact; replacement blocked | New guard/fallback | R17 with native commands/subagents still pending. Existing background-work handoff error, no replacement, no second compact/continue loop; queue held. | Existing error row and queue | H unchanged usage plus pending-work true | T recording; MISSING; absent from new test table |
| R19 Delegated follow-up succeeds | New task linkage | App-owned child with original task complete and a later follow-up task waiting. Failure, compact and continuation share follow-up task ID. Parent stays pending/running until continuation completes; final result “Request 3 done”, not compact output. | Child timeline; parent subagent status/result/link and notification | H-parent plus base; A actual delegate follow-up | T recording; MISSING; new delegated-follow-up test checks final parent result |
| R20 Delegated recovery fails | New task linkage exit | R19 plus compact or continuation failure. Parent settles failed with correct final task/result, rather than early intermediate failure or indefinite waiting. | Parent failed task/result, child failure | H-parent + R15/R16; no lineage fabrication through RPC | T recording; MISSING |
| R21 Delegated recovery stopped | New task linkage exit | R19 plus Stop during recovery. Parent receives interrupted/cancelled final status matching the actual terminal run; no completed compact result reported as success. | Parent interrupted task/result and child Stop state | H-parent + H-gates; A actual child Stop | T recording; MISSING |
| R22 Snoozed automatic recovery | New automaticWake | Snooze is future timestamp; trigger recovery from background/automatic intake. Both generated server messages preserve exact snoozedUntil; sidebar/announcements retain snoozed behavior. Include ordinary agent+server message as added predicate case. | Sidebar snoozed shelf, attention; child/main transcript | H dispatch thread.snooze after original turn; automatic follow-up; A automatic wake, not a human send | T recording; MISSING; source test covers a server message only |
| R23 Human send wakes snoozed thread | Control/reverse | Snoozed thread receives actual user web/mobile send; snooze clears. Explicit unsnooze also remains available. | Existing snoozed/active shelves and chat | A UI/RPC; existing snooze table supports control | T recording; MISSING |
| R24 Manual compact does not auto-continue | New completion guard/control | User `/compact`, no idle reason, completed native item. Ordinary “Context compacted”; no server “Continue…” merely because compact completed. Literal recovery-looking message ID alone must not qualify. | Ordinary compaction divider | A manual `/compact`; H use recovery-looking ID with user provenance | T recording; MISSING |
| R25 Client onReturn compact does not duplicate continuation | New completion guard/control | Client-origin compact with explicit `onReturn`; pending client prompt managed by existing composer. Finished before-sending marker, but no additional server-generated “Continue…” from this compact. | Existing composer compact-then-send; marker | A existing composer flow; H dispatch web/mobile provenance and observe no generated server follow-up | T recording; MISSING |
| R26 Cache-expiry server compact | New completion guard + snooze/control | Agent+server `/compact`, `beforeCacheExpires`; completed item uses cache-expiry title. Preserve snooze under broadened automaticWake; do not add recovery continuation. | Cache-expiry divider, sidebar | H direct orchestrator dispatch; A existing idle timer if configured, without waiting merely for proof | T recording; MISSING |
| R27 Effective handoff/provider switch | Control/exclusion | Pending cross-provider handoff (merge/import handoff is equivalent for this guard), budget rejection even though target supports compact, no pending background work. Existing replacement/handoff; no new same-native recovery. | Existing handoff rows | H provider-switch fixture with exhausted target; A provider switch if cheap | T recording; MISSING; existing switch tests are source support only |
| R27a Effective handoff; replacement blocked | Control/exclusion | R27 plus pending native background work. Existing background-work refusal, no compact or replacement. | Existing failure and held queue | H exhausted target plus pending work | T recording; MISSING |
| R28 Adapter lacks compactThread | Control/exclusion | Successful resume and exhausted budget, no compact method or background work. Existing fresh-session fallback completes. | Existing handoff/assistant paths | H omit method; no install needed | T recording; MISSING |
| R28a Unsupported adapter; replacement blocked | Control/exclusion | R28 plus pending native background work. Existing handoff failure; no compact or replacement. | Existing failure and held queue | H omit method and set pending work true | T recording; MISSING |
| R29 Goal budget exception | Control/exclusion | `/goal` control while history cannot fit. Existing deferred-history handling and goal output; no “needs compaction” recovery. Explicit compact recursion control is R24. | Existing goal output | A command through UI/RPC; H force budget rejection/deferred delivery | T recording; MISSING |
| R30 New native session | Control/exclusion | Native ref absent. Existing ensure/start; no resume, compaction-needed failure or recovery steps. | Existing ordinary start/output | A fresh thread; H native-null fixture | T recording; MISSING |
| R30a Resume failed | Control/exclusion | Native resume returns an error. Existing fresh-session replacement, portable history and subsequent output; no new compaction branch. | Existing handoff/start/output | H resume-error fixture; A isolated unavailable native session | T recording; MISSING; existing fallback tests are source support only |
| R30b History delivery uncertain | Control/exclusion | Existing pending history injection is ambiguous. Existing replacement with recovery handoff, no same-session compact. | Existing handoff/output | H pending-delivery fixture; app RPC cannot manufacture provider acknowledgement loss reliably | T recording; MISSING; existing fallback tests are source support only |
| R31 Reconnect and shared transport | Compatibility | Recovery events plus final projection retain messages, failures, task links and counts. A second local/remote connection/reload sees the same sequence/state without dispatching another compact. Guest projection uses its existing renderer. Omission of optional command field remains valid. | Web, desktop shared web, mobile; guest direct timeline | A second RPC client/reconnect to the same synthetic fresh-DB thread; H reconstruct projection and command replay. Guest uses actual share UI/RPC if visual claim is made. | T recording; MISSING |

## Minimum capture set

These are transcript groups, not one independent expensive provider run per row. Each group is a **recording**, with parameterized segments where listed. Each segment must identify the local reviewed revision and whether it is synthetic harness, native adapter replay or live provider. Provider/model operational metadata must be stripped before upload.

| Capture group | Rows | Required content |
| --- | --- | --- |
| C1 Baseline recovery | R01–R08, R31 | A fit control then classified failure, same native identity, compact pre-item/running/completed, continuation, both codewords, final and reconnected projections. Completed item has counts, lacks counts, or is absent in three labelled segments. Source-inferred labels are identified as such. |
| C2 Queue ordering | R09–R11 | Unheld automatic work, held unattended work and held human work; compact/continue priority, subsequent release or retained hold, explicit Resume. |
| C3 Terminal guards and failure exits | R12–R16 | Deferred gates establish stale/non-root/ineligible/Stop races and native compact/continue failures. Include recovery dispatch/start failure as a failure-injection parameter, recording the warning/fallback state; do not claim automatic completion when dispatch itself fails. |
| C4 Ineffective compact | R17–R18 | Usage unchanged after compact; exactly one replacement without work, existing refusal with work; no recursive compact. |
| C5 Parent follow-up | R19–R21 | Same follow-up task ID on all recovery steps, parent stays open, final successful result, final failure, final interruption in separate segments. |
| C6 Snooze and compact provenance | R22–R26 | Automatic versus human wake; manual, client onReturn and server cache-expiry compactions; title/provenance/no duplicate continuation. |
| C7 Exclusions | R27–R30 | Effective-handoff, unsupported-adapter, control-command, fresh/resume-error/uncertain-delivery cases take established paths. |

All seven groups are still missing. A labelled H transcript can satisfy deterministic server-state rows; if a live/native success is advertised, attach its own native adapter/runtime transcript instead of relabelling H. The existing test helper alone cannot satisfy R04–R06. No screenshot is needed for this server-only proof contract; if visuals are later added, cover actual observed renderer variants and record motion/interactions rather than substituting a final still for the sequence.

## Audit limits and cleanup

Covered all changed production code, both changed tests, service/effect entry points, compaction adapters for available provider families, shared command/failure contracts, existing web/mobile/guest renderers, task finalization, queue promotion/holds and snooze consumers. Tests were inspected, not run. No live provider saturation, runtime event capture, browser/device verification or process-restart fault injection occurred. Reconnect compatibility is planned; a server crash between recovery stages is not demonstrated by reconnecting a client and must not be advertised as such.

Disk availability at start was 30 GiB, above the 5 GiB floor. No persistent process or dev server was started; all diagnostic commands completed. No files were deleted. Only this scratch matrix was created. Upload authorization was explicit in the brief. Public content contains synthetic fixture data and no runtime model identifiers or credentials.

FRICTION: none

VERDICT: INSUFFICIENT R01–R31 including R15a/R15b/R27a/R28a/R30a/R30b uncaptured; R07 contradicts a universal finished-marker claim
