Files
hyperframes/packages/studio-server
Miguel Angel Simon Sierra 3c4ff64e45 feat(studio): stop and correct a run over ACP
Cancelling asks the agent to stop with session/cancel before its process
is taken away, so it can put its tools down rather than have them removed
mid-write; the kill still follows on a short leash for an agent that does
not take the hint.

Correcting is where the two transports genuinely differ. Claude Code
reads a correction into the turn it is already having. ACP has no way to
speak into an open turn, so a correction cancels this one and prompts
again on the same session: one job, one session id, everything the agent
has read still in hand — but it does start the turn over, and the run
says exactly that rather than implying the correction was slipped in.

Steering an ACP run also used to build the harness' native resume flags
for a command that is not the harness, so that path is closed.

Studio's own verdict on a run now outlives the agent acknowledging it: a
run failed for an unanswered question was being relabelled cancelled by
the stop reason its own cancel produced.

Verified against @agentclientprotocol/codex-acp: a live run told to make
the text BLUE instead of RED came back as one run, one session, the steer
recorded, and BLUE on disk.
2026-08-05 23:08:00 -07:00
..