# Session transcript media, code and action states

The browser now uses one renderer for restored sessions and live tool events. Tool calls, their measured progress, diagnostics, validated artifacts and the final assistant answer remain under their original turn. Exact action IDs pair parallel work; duplicate or late events cannot change a terminal outcome. Legacy results pair by name only when one unmatched call exists. Missing outcomes remain explicitly unrecorded.

Image, video and audio previews use the invocation project's artifact identity. Authenticated HEAD validation and revision-pinned GET precede preview, Open and Download activation. Explicit artifact receipts, including an empty list, remain authoritative. External, foreign-project and traversal identities cannot become media requests. Switching sessions aborts pending acquisitions, revokes object URLs and releases action timers; stale session polling cannot repaint another project or clear its newer poller.

Code fences use scoped local syntax styles, an exact-text Copy control and a bounded cache of completed highlights. Incomplete and very large fences stay escaped text. JSON formatting changes whitespace only, retaining large integers, exponent notation, escapes and duplicate keys. Syntax classes cannot style unrelated telemetry. Complete JSON fences display with indentation while Copy retains the exact source, including original line endings. Delayed startup preferences cannot replace an explicit session/New selection, and stale project hydration cannot overwrite the current project. Local cached tool provenance uses the same escaped renderer as canonical history.

Verification:

- 105 tests passed across seven suites, including all required chat transport lifecycle, client runtime and inline-script gates. CLI TypeScript no-emit passed.
- Actual Chromium rendered current source-bundled production HTML at 320, 768 and 1440 pixels, dark and light. All 48 checks passed: canonical restore/grouping, three decoded media formats, video/audio playback, byte-exact downloads, keyboard detail modal, Unicode clipboard, scoped syntax, correlated synthetic working states and session- and project-switch cleanup.
- Dark desktop and light phone screenshots were visually reviewed. No shared compiled output, publish package, real daemon, model, GPU workload or service was changed by this validation.

Run the isolated browser proof with:

```sh
node scripts/test-web-session-live.mjs --run --out /tmp/omnius-web-session
```

The harness compiles only browser source into an owned temporary directory and serves an API fixture. Every session, artifact, progress event and media byte is synthetic. It forbids inference/execution requests and foreign-origin traffic. The [durable report](evidence/session-transcript-browser-20261016.json) records source hashes, individual checks and selected screenshots.
