The loop recorded every model token delta as a durable `assistant/chunk` session event AND emitted an identical live `agent/stream-chunk` Cordis event one line later. Same StreamChunk, same turn/step; the emit added only the live Agent handle, which the sole consumer discarded. This is the boundary-mirror duplication the event-domain work removed for turn/step boundaries, applied to the token stream — a follow-up the boundary RFC explicitly deferred. The premise is settled: chunk persistence is authoritative (the proposal to stop persisting chunks was rejected — replay/snapshots depend on it), so `assistant/chunk` on `session/event` is the load-bearing token stream and `agent/stream-chunk` is pure redundancy. - Remove the `agent/stream-chunk` declaration + emit; drop the now-unused StreamChunk import from dsh-agent's types. - Migrate `dsh-ui-stdio` (the only live consumer; ACP already reads assistant/chunk off session/event) to render assistant/chunk in its existing session/event listener. Consolidating to one listener also makes the inReasoning dim-SGR flag deterministic across chunk/boundary events (they no longer race across two listeners). - Repoint the agent-loop tests (cancel/loop) and ui-stdio tests to the session/event assistant/chunk feed. - New RFC (implemented/simplification/2026-07-02-remove-stream-chunk-mirror); amend the boundary RFC's retained-list entry to cross-link; update architecture, cookbook, event-domain-semantics, the ACP proposal, and the regenerated cordis catalog. Snapshot goldens unchanged (ACP never used the mirror), confirming no editor-facing transcript change.
support/ — dev/test/example infrastructure
Packages that exist to serve development, testing, and the examples rather than to ship as product API. They are real workspace packages (typed, tested, under the coverage gate), but they carry lower compatibility expectations: they may change or be removed when the development need behind them does, without the deprecation care a product package would warrant.
| Package | Role | ctx key |
|---|---|---|
invariants/ |
Dev-mode event-contract invariants + session-log freeze | (listens on session/*, agent/*) |
ui-stdio/ |
Minimal stdio (readline) UI plugin: renders agent/* events, feeds stdin lines to the agent |
(drives ctx.agents) |
llm-replay/ |
Record/replay adapter: short-circuits llm/stream from a recorded session JSONL (keyless snapshot tests) |
(listens on llm/stream) |
subagent-mock/ |
Scripted SubagentProvider for deterministic seam/tool tests |
(registers on ctx.subagents) |
invariants runs only in dev mode (contract checks, not runtime behavior). ui-stdio and llm-replay were extracted from the examples for reuse and to bring them under the per-file coverage gate; they back the demos and the snapshot test tier. subagent-mock exercises the real ctx.subagents load path without a model or child agent. A package graduates OUT of support/ into a product group only when it gains documented product consumers.