Once a plan is approved (via ExitPlanMode or explicit user go-ahead), execute end-to-end. This file governs what happens AFTER planning — see `planning.md` for the interview/research/challenger flow that precedes it.
## 1. Default posture — run through, no mid-task gates
**Keep working until the user's request is satisfied.**
- Don't stop after research, after a single commit, after each "phase" or "batch" — keep going.
- No "Should I proceed with X?" / "Want me to continue?" prompts between steps of an approved plan.
- No mid-task checkpoints or batch approvals. The user interrupts if something drifts.
- Course-correct on user interruption, not by polling.
Stopping is the exception that needs a reason. The ONLY reasons to stop mid-execution are listed in §2.
## 2. When to stop and ask (the ONLY ASK FIRST list)
Pause and surface to the user (or, if you're a subagent, to the session that spawned you) for:
- **Destructive ops** — force-push, `git reset --hard`, `rm -rf`, dropping DB tables, killing processes the user didn't start
- **Schema / public API changes** — REST, GraphQL, gRPC, DB schema
- **Deleting tested code** — anything that has tests covering it
- **Interface / contract changes** that affect other teams
- **Scope changes** — work beyond the approved plan
- **New genuine ambiguity** discovered mid-execution that the research didn't resolve
- **Configuration changes with external impact** — credentials, DNS, firewall rules, production configs
Anything NOT on this list → just do it. Don't invent new reasons to pause.
## 3. Push / merge behaviour
On personal repositories (this monorepo and similar):
- **Push after every commit** — don't batch, don't wait for approval
- **Direct to master** — no feature branches, no PRs unless the user explicitly asks
- **Wait for CI / deployment** to complete before marking the task done — a green local build isn't the finish line if CI still runs
- **`git add` specific files by name** — never `git add -A` or `git add .`, which can sweep in secrets, worktree cruft, or untracked experiments
- **Never skip hooks** (`--no-verify`, `--no-gpg-sign`) unless the user explicitly requests it
- **Never force-push to master** — warn the user if they request it
Shared / corporate repos follow whatever PR flow the project uses; when in doubt, ask.
## 4. When to dispatch subagents
**Default: do the work inline.** The main session reads files, writes code, runs tests, commits. Every handoff costs clarity and context.
Spawn a subagent only when one of these is true:
- **Parallel independent work** — two or more genuinely independent investigations can run at the same time
- **Context protection** — raw output would be huge (wide codebase sweeps, long log dumps, 50+ files) and would pollute the main context; let a subagent digest and summarise
- **User asked** — the user explicitly requested an agent
- **Long-running stand-alone task** — something that runs for a while and doesn't need your attention (use `run_in_background: true`)
- Add lint-ignore or type-error suppression comments
- Edit generated / auto-generated files
- Write implementation before tests (see `quality.md`)
- Commit temp / one-off / test scripts to the repo — store them outside the repo instead
## 6. Before touching any directory
Check if it (or any parent up to repo root) contains project-specific rules (e.g., `.claude/CLAUDE.md`, `.cursor/rules`). If found, read those files first — they may override anything in this file.
## 7. Docs — keep `infra/docs/` current
For any infra change that alters state described in
`infra/docs/architecture/` or `infra/docs/runbooks/`:
- **Update affected docs in the same commit.** Never land infra
changes that leave docs stale.
- **New architecture-visible component** (new service, storage class,