# loop.config.yaml — one OUTER-loop definition. # Scaffolded by loop-scaffold.sh, scored by loop-check.sh. Flat YAML on purpose: every # key sits at column 0 so the audit parses it without a yq dependency. # Full field semantics: skills/loop-ops/references/state-spine.md # # >>> ADAPT every below. The audit errors on unbounded scope, a # missing gate, an undefined escalation rule, or a tier/permission mismatch. # ── identity ──────────────────────────────────────────────────────────────── name: # matches the .loops// directory pattern: # a catalog key (pr-watch, ci-watch, …) or "custom" # ── autonomy ──────────────────────────────────────────────────────────────── tier: L1 # L1 report-only | L2 assisted (worktree+gate) | L3 unattended permission_mode: dontAsk # plan | dontAsk | auto | acceptEdits | bypassPermissions # L1 → plan or dontAsk · L2 → dontAsk/auto · L3 → bypassPermissions (container only) # ── cadence ───────────────────────────────────────────────────────────────── cadence: 1h # 10m | 1h | 6h | 1d, or a cron string ("*/10 * * * *") # ── purpose & bounds ──────────────────────────────────────────────────────── goal: "" scope: # bounded globs the loop may touch — NEVER "*" or "**" - "" # ── the gate (required at L2+) ────────────────────────────────────────────── verify: "" # a loop with no gate is invalid at L2+ guard: "" # required at L2+ # ── isolation & landing (required at L2+) ─────────────────────────────────── worktree: true # isolate code changes in a git worktree (required L2+) land_via: fleet-ops # who test-gates + lands winning branches (L2+) # ── the escalation rule (required) ────────────────────────────────────────── # What the loop ESCALATES instead of doing. Mirror the never-auto-land classes: # force-push, push to main, prod deploy/migration, mass delete, IAM grants, .claude edits. escalation: "" # ── safety rails ──────────────────────────────────────────────────────────── budget_tokens: 200000 # per-run output-token ceiling (stop the run when reached) kill_switch: ".loops//PAUSED exists, OR the loop-pause label is set"