| index a05cc3c01..2991abc7f 100644 |
| --- a/AGENTS.md |
| +++ b/AGENTS.md |
| @@ -31,6 +31,70 @@ Always name the model explicitly when dispatching; an omitted model silently |
| inherits the session's (usually the most expensive). A precise brief beats a |
| capable model — exact values, file paths and interfaces go in the brief. |
| |
| +## Stopping rules (Paul's rule, 2026-10-26) |
| + |
| +Work here spins when review rounds have no budget. In October three |
| +sessions ran 22 to 25 days each, one of them made 520 Astra runs, the |
| +region HA 1b-next plan reached review round 13, and `main` holds 508 |
| +Astra brief and findings files. Each time Paul found out by asking |
| +"still going?". These rules bind every agent here, Claude and Codex, |
| +sessions and subagents, and the reviewers they brief. |
| + |
| +1. **A review stops at the first round with no P1.** This holds for |
| + specs, plans, tasks and branches. Apply that round's P2 fixes without |
| + reopening the review. P3s go on a follow-up list on the branch and |
| + never start a round. A fourth round needs Paul's go: ask with what |
| + rounds 1-3 found and what a fourth would buy. The count follows the |
| + design or change, not the file: a revision, a rename, a split into |
| + two documents, a new reviewer or a session handoff does not restart |
| + it, so every brief and handoff carries the round history. Two checks |
| + still apply to the diff the P2 fixes produce, inside the same budget: |
| + the census, and review of any newly changed security, root, |
| + termination or production-storage behaviour. |
| +2. **Two rounds in the same fault family: stop fixing.** A fault family |
| + is the set of findings against one invariant or trust boundary, |
| + whatever file or symptom they show up in; name that invariant beside |
| + each finding. When fixes produce another finding in the same family |
| + two rounds running, do not write a third fix. Offer Paul the choice: |
| + - refuse the case up front, with a gate before the work starts and a |
| + report for an operator (hostfiles, `RestorableWithinCap`); |
| + - cut the feature that produces it (instance policy, live memory |
| + growth); |
| + - state the invariant, enforce it in one place, and check it with a |
| + guard test or a randomized simulation (rootfs, the per-unit lock). |
| +3. **Size per-task review to risk.** A task gets its own Astra or Opus |
| + review only when it touches a security gate, root or termination, a |
| + cache, production storage, billing or a redirect. Everything else is |
| + covered by one whole-branch review before merge. |
| +4. **Never review against unmerged work.** A plan that depends on a |
| + design still changing on another branch waits until that design |
| + merges. Region HA's plans were reviewed against the declared |
| + interfaces of unmerged claim plans, so every claim revision reopened |
| + them. One design in flight per area. |
| +5. **No dormant feature without a switch-on date.** Every later plan |
| + touching its packages has to be reviewed against a feature merged |
| + behind an off switch. Before building one, name what a user gets, |
| + who is asking for it, and when it switches on. With no answer, keep |
| + it on its branch. Claims, region HA and nearest-region placement all |
| + sat dormant on `main`; claims was shelved on 2026-10-25 at spec |
| + rev 6.34. |
| +6. **Something Paul can see lands first.** Order a plan so its first |
| + merge changes something a user or Paul can observe. Measurement and |
| + scaffolding ride with that slice, not ahead of it. |
| +7. **One session per plan, with a finish line.** A session owns one plan |
| + or a stated slice, and ends when that merges. After three days or |
| + three context compactions, write the handoff (`amadan branch |
| + handoff`) and stop; a fresh session picks up from there. |
| +8. **Say so before Paul has to ask.** When 24 hours pass with no merge, |
| + or rule 1 or 2 triggers, post on the branch's discussion and tell Paul |
| + in the session: what is blocking, what the last two rounds found, and |
| + the cut you recommend. The clock starts when the plan or slice starts, |
| + or at its latest merge; a session handoff does not reset it. Report |
| + again every further 24 hours. |
| + |
| +Review briefs follow `docs/superpowers/reviews/REVIEW-BRIEF-TEMPLATE.md`, |
| +which carries the round budget and the three-way verdict to the reviewer. |
| + |
| ## Operate via API and CLI (Paul's rule, 2026-08-06) |
| |
| Day-to-day CARLOS administration goes through the console API and the |
| @@ -113,16 +177,15 @@ The steps, for agents and people alike: |
| |
| amadan branch describe carlos/platform <branch> -body - |
| |
| -3. **Squash it to one commit** before landing, with a message that says |
| - what the change is and why. `amadan branch merge` has no squash mode, |
| - so this is done on the branch: `main` then gets the hub's merge commit |
| - and exactly one change commit under it, not the branch's iterations. |
| - The iterations are not lost: the description and the reviews record |
| - them. Squashing moves the tip, so CI runs again on it. |
| -4. **Land it once CI is green on that tip:** |
| +3. **Land it as one commit** with `amadan branch merge -squash` (Paul, |
| + 2026-09-22: no branch histories on `main`). The hub squashes, so |
| + don't squash or force-push the branch yourself. The message says what |
| + the change is and why. The iterations are not lost: the branch page |
| + keeps its commits, description and reviews after the merge. |
| +4. **Land it once CI is green on the tip:** |
| |
| amadan ci status carlos/platform -branch <branch> |
| - amadan branch merge carlos/platform <branch> -expect <tip> -message "..." |
| + amadan branch merge carlos/platform <branch> -squash -expect <full 40-char tip> -message "..." |
| |
| The merge refuses a branch whose CI is not green (exit 2) and, with |
| `-expect`, one that moved after you checked it. That ordering is the |