Skip to main content

Module user_stop

Module user_stop 

Source
Expand description

The user’s Stop on an agent’s turn, and the grace window after it. The turn end a Stop causes is the user’s own action: the notification router sends no “finished” for it, and the Swarm Supervisor neither judges nor continues it (SPEC_SWARM_SUPERVISOR_2026_10_16.md §3.4). Recorded by notify.emit’s TurnStopped (server/notify_handlers.rs) at once, for the Supervisor, and again by the notification router when it reaches that event in its queue, so a turn start queued before the Stop can’t erase it.

Constants§

STOP_GRACE_MS
How long after a user Stop the turn end it causes counts as the user’s own action.

Functions§

forget
A new turn started on this block: an earlier Stop no longer applies to it.
note_user_stop
The user pressed Stop on this block’s turn.
stopped_recently
Whether the user stopped this block’s turn within the grace window.
stopped_since
Whether the user stopped this block’s turn at or after since_ms (epoch ms), however long ago that is within [STOP_KEEP_MS]: a continuation that waited asks this, not the grace window.