Install any skill in seconds. Free to start, no credit card required.
Get Started Free →hashgraph-online/autonomous-loop
How Cavekit's autonomous execution loop works — state machine, stop hook, completion sentinel, lock, budgets, iteration cap. Read this skill any time you are about to run /ck:make, debug a stuck session, or write a new command that needs the loop. Trigger phrases: "how does the loop work", "stop hook", "autonomous", "completion sentinel", "why is the session looping".
Passed 22 of 22 test cases with the skill, and 4 of 22 without it.
and 21 more in the full report
18 fixed4 passed either way0 still failing0 broke
Tokens, turns and time describe resource use, not a dollar price.
One of 18 test cases the skill fixed. Same model, same prompt, with and without the skill.
Which file under .cavekit/ stores the zero-context UI snapshot generated by progress-tracker?
| Checked | Without skill | With skill |
|---|---|---|
| Identifies .progress.json as the zero-context snapshot file | Missed | Passed |
The instructions your model reads when the skill loads.
The loop lets a single /ck:make invocation run dozens of agent iterations
without user intervention, while still respecting per-task budgets, session
budgets, and explicit user-approval gates.
┌─────────────────┐ Stop event ┌────────────────────┐
│ Claude Code │──────────────▶│ stop-hook.sh │
│ session │ │ (.cavekit/loop │
└─────────────────┘ │ active?) │
▲ └─────────┬──────────┘
│ │ route()
│ next prompt injected ▼
│ ┌────────────────────┐
│ │ cavekit-tools.cjs │
│ │ routeDecision() │
│ │ + status-block │
│ │ + backprop- │
│ │ directive │
│ └─────────┬──────────┘
│ │
└───────── {decision:"block", │
reason:<next prompt>} ◀─┘
All under <project>/.cavekit/:
| File | Writer | Purpose |
|---|---|---|
.loop.json | setup-loop | Sentinel; stop-hook no-ops without it. |
.loop.lock | stop-hook (heartbeat) | Single-writer lock. PID + hostname + ts. |
state.md | cavekit-tools | phase, current_task, iteration. |
token-ledger.json | token-monitor hook | Session + per-task token tallies. |
task-status.json | commands | Authoritative task registry. |
.progress.json | progress-tracker | Zero-context UI snapshot. |
test cases passed, vs 4 / 22 without
More skills from the same source and nearby in the registry, with their headline benchmark lift.