Add a shared interrupt flag that the conversation loop polls at safe points: before each model request, when a stream call fails, and before each pending tool execution. When the flag is set the turn winds down instead of failing: tools that have not run yet receive synthesized error tool_results so every tool_use stays answered and the session remains valid for the next request. TurnSummary gains an interrupted field so callers can distinguish a user-initiated stop from a completed turn, and the session tracer records a turn_interrupted event (with iteration and phase) instead of turn_failed / turn_completed. Groundwork for Esc-to-interrupt (#3196): a follow-up wires this signal into the streaming API client and the CLI input listener. |
||
|---|---|---|
| .. | ||
| api | ||
| claw-analog | ||
| claw-rag-service | ||
| commands | ||
| compat-harness | ||
| mock-anthropic-service | ||
| plugins | ||
| runtime | ||
| rusty-claude-cli | ||
| telemetry | ||
| tools | ||