Files
t3code/apps/server/scripts
Julius MarmingeandClaude Fable 5 348b2495d4 test(orchestration): replay-recorded subagent narration fixture
Adds a subagent_text replay fixture recorded against the real Claude
Agent SDK (CLI 2.1.220): a background subagent that narrates, reads a
file, and answers — the exact frame sequence (task_started, ptu-tagged
narration text, ptu-tagged Read, ptu-tagged final text,
task_notification with the same summary) observed in the production
session that motivated the routing fix. The full-orchestrator replay
asserts the parent thread carries only the parent's own assistant
message while the child thread carries exactly the streamed narration
and final answer in stream order with no duplicated notification
result. Verified to fail against the pre-fix adapter with three parent
assistant messages, reproducing the reported transcript bleed.

Recording on the current CLI surfaced two gaps: replay rejected
stream_event frames (now part of the recorded diet) and TaskOutput was
missing from the known native tool table.

Only background subagents forward ptu-tagged assistant text into the
parent stream — foreground subagents return text via the Agent
tool_result — which is why the pre-existing foreground subagent fixture
never exercised this path.

Co-Authored-By: Claude Fable 5 <[email protected]>
2026-08-04 01:43:46 +02:00
..
wip
2026-08-03 11:45:00 -04:00