feat: write loop-status snapshots

This commit is contained in:
Affaan Mustafa
2026-04-30 11:41:11 -04:00
committed by Affaan Mustafa
parent bb40978e31
commit 20154ddb22
3 changed files with 160 additions and 0 deletions

View File

@@ -49,6 +49,9 @@ tool calls that have no matching `tool_result`.
number of times, then exits with the highest status seen.
- `ecc loop-status --watch --watch-count 3` emits a bounded watch stream for
scripts and handoffs.
- `ecc loop-status --watch --write-dir ~/.claude/loops` maintains
`index.json` and per-session JSON snapshots for sibling terminals or
watchdog scripts.
## Watch Mode
@@ -56,6 +59,18 @@ When `--watch` is present, refresh status periodically. With `--json`, each
refresh is emitted as one JSON object per line so another terminal or script can
consume the stream.
## Snapshot Files
Use `--write-dir <dir>` when a separate process needs to inspect loop state
without waiting for the current Claude session to dequeue `/loop-status`. The
CLI writes:
- `index.json` with one row per inspected session.
- `<session-id>.json` with the full status payload for that session.
These files are snapshots of local transcript analysis. They do not control or
timeout Claude Code runtime tool calls.
## Arguments
$ARGUMENTS: