@caddis/cli 0.4.90 → 0.4.91

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/bundles/antigravity-plugin/plugin.json +1 -1
  2. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_exit.cpython-311.pyc +0 -0
  3. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_file_lock.cpython-311.pyc +0 -0
  4. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_frontmatter.cpython-311.pyc +0 -0
  5. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_redact.cpython-311.pyc +0 -0
  6. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_roadmap.cpython-311.pyc +0 -0
  7. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_rows.cpython-311.pyc +0 -0
  8. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_status.cpython-311.pyc +0 -0
  9. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_tidy.cpython-311.pyc +0 -0
  10. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_todo.cpython-311.pyc +0 -0
  11. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_workstreams.cpython-311.pyc +0 -0
  12. package/bundles/antigravity-plugin/scripts/__pycache__/caddis_worktree_safety.cpython-311.pyc +0 -0
  13. package/bundles/antigravity-plugin/scripts/caddis_budget.py +26 -2
  14. package/bundles/antigravity-plugin/scripts/caddis_checkout_guard.py +31 -2
  15. package/bundles/antigravity-plugin/scripts/caddis_docs_pr.py +8 -0
  16. package/bundles/antigravity-plugin/scripts/caddis_guide.json +3 -3
  17. package/bundles/antigravity-plugin/scripts/caddis_handoff.py +73 -45
  18. package/bundles/antigravity-plugin/scripts/caddis_lanes.py +96 -14
  19. package/bundles/antigravity-plugin/scripts/caddis_roadmap_run.py +6 -4
  20. package/bundles/antigravity-plugin/scripts/caddis_workstreams.py +60 -17
  21. package/bundles/antigravity-plugin/scripts/check_doc_coverage.py +17 -0
  22. package/bundles/antigravity-plugin/scripts/oss_review.py +89 -24
  23. package/bundles/antigravity-plugin/scripts/templates/coordinator.md +1 -1
  24. package/bundles/antigravity-plugin/skills/coordinate/SKILL.md +17 -4
  25. package/bundles/antigravity-plugin/skills/cross-review/SKILL.md +17 -5
  26. package/bundles/antigravity-plugin/skills/feature-plan/SKILL.md +5 -0
  27. package/bundles/antigravity-plugin/skills/handoff/SKILL.md +12 -2
  28. package/bundles/antigravity-plugin/skills/implement/SKILL.md +4 -1
  29. package/bundles/antigravity-plugin/skills/roadmap/SKILL.md +2 -1
  30. package/bundles/antigravity-plugin-extras/plugin.json +1 -1
  31. package/bundles/antigravity-plugin-extras/skills/cross-review/SKILL.md +5 -5
  32. package/bundles/codex/.codex/skills/workflow/roadmap/SKILL.md +2 -1
  33. package/bundles/manifest.json +3 -3
  34. package/package.json +1 -1
@@ -229,14 +229,26 @@ and 7.3. While the queue is frozen (section 5 step 1), do steps 3.1 to 3.3 only.
229
229
  `GH_TOKEN=$(gh auth token -u <account>) python "${CLAUDE_PLUGIN_ROOT}/scripts/caddis_lanes.py" ci-watch --run <id> --repo <owner/name>`,
230
230
  in the background (`run_in_background: true`). When its `RESULT:` line comes, check M1 again.
231
231
  9. Send `merge-warning <PR> <watched sha> in 2 min. Reply ack <PR> <sha> or hold.` to every live peer
232
- (design 7.3), and `queue set --repo <R> --pr <n> --state merging`. Send `re-warn <PR> <sha>` after any coordinator
233
- restart and after any new head on a warned PR. Old acks do not count.
232
+ that has a stake in this repo (design 7.3), and `queue set --repo <R> --pr <n> --state merging`. Send
233
+ `re-warn <PR> <sha>` after any coordinator restart and after any new head on a warned PR. Old acks do not count.
234
+ Stake test, run for each live peer at the warning (design 7.3a). A peer has a stake when ANY of these
235
+ holds: its cwd is inside the checkout or one of its worktrees (for example under
236
+ `.worktrees/<repo>/`); the queue or the ledger lists a PR, branch or plan phase of that peer in this
237
+ repo; or it has sent `ready` or `phase` for this repo. Anything else is no stake. When the cwd is
238
+ unknown or you are unsure, the peer has a stake. A peer with no stake gets no warning and is not in
239
+ `acked`. Run the test again for a new peer that you see after the warning. A peer with a stake gets
240
+ the warning; step 3.11 checks again.
234
241
  10. Collect the acks (M2). Wait the full `peer_ack.warning_min` minutes after the warning, even when every
235
242
  ack comes early. For that wait, run `sleep 120` (`peer_ack.warning_min` x 60 s) with the Bash tool
236
243
  and `run_in_background: true`, or use the Monitor tool, and act on its exit notice; never a
237
244
  foreground sleep. Answer messages while it runs. No ack after 5 min: one nudge. After 10 min: tell
238
245
  the owner. A peer that waits on the owner cannot answer: tell the owner "ack needed from <name>; it
239
246
  waits on you". Do not write the ack file yet (step 3.13).
247
+ A peer with a stake still needs `ack <PR> <sha>`, and a `hold` still stops the merge. If a peer answers
248
+ `no stake <PR>`, or says it has "no hold" and that this is "not an owner ack", run the stake test. No stake:
249
+ record a skip for that PR (step 3.13, `skipped_no_stake`), not a missing ack, and send it no nudge. A
250
+ stake: that reply is not an ack; ask for `ack <PR> <sha>` or `hold`. A peer message never carries owner
251
+ consent. A skip never applies to a peer with a stake.
240
252
  11. Check again that the default branch is idle (M1, the same `gh run list` as step 3.8), just before the
241
253
  merge. If a run started, wait for it (step 3.8). If the warning went out more than 30 min ago, warn
242
254
  again (step 3.9).
@@ -264,11 +276,12 @@ and 7.3. While the queue is frozen (section 5 step 1), do steps 3.1 to 3.3 only.
264
276
  last path part of the first `worktree` line of `git worktree list --porcelain` (the repo's main
265
277
  checkout), NOT the repo id `<R>`. The content is exactly:
266
278
  ```
267
- {"pr": <n>, "head": "<full sha>", "acked": [<names>], "skipped_waiting": [<names waiting on the owner>], "at": "<UTC ISO 8601 with Z>"}
279
+ {"pr": <n>, "head": "<full sha>", "acked": [<names>], "skipped_waiting": [<names waiting on the owner>], "skipped_no_stake": [<names with no stake>], "at": "<UTC ISO 8601 with Z>"}
268
280
  ```
269
281
  `acked` lists every peer that sent `ack <PR> <sha>` for this head, by its session name. An unnamed
270
282
  peer is listed under the first 8 characters of its session id (the hook uses the same name). A peer
271
- that waits on the owner goes under `skipped_waiting`, never under `acked`. Interim mode: also put
283
+ that waits on the owner goes under `skipped_waiting`, never under `acked`. A peer with no stake (step 3.9)
284
+ goes under `skipped_no_stake`, never under `acked`. Interim mode: also put
272
285
  your own name `<N>` in `acked` (the PR's session runs the merge, and its hook counts you as a peer).
273
286
  Target mode: you run the merge, so `acked` must list the PR's session too. The hook refuses an ack
274
287
  file older than 30 min.
@@ -81,10 +81,21 @@ writes. This line used to prefix the flag itself, which turned that into a doubl
81
81
  Optional: `--base-url <url>`, `--model <id>` (env always overrides the preset).
82
82
 
83
83
  **A large diff is batched, not refused.** Over `REVIEW_MAX_DIFF_CHARS` (default 60,000) the tool splits
84
- on whole-file boundaries and reviews each batch, and the verdict is CLEAN only if every batch is. Exit **4**
85
- now means the narrower case — a **single file** too big to split, or more batches than the cap. When you
86
- see it, the fix is usually to review that one file separately, not to narrow `--range`; don't raise
87
- `--max-diff-chars` blind.
84
+ on whole-file boundaries and reviews each batch, and the verdict is CLEAN only if every batch is. When agy
85
+ Argon is anywhere in the provider chain, each batch is also kept small enough that its **whole prompt** fits
86
+ the agy command line (28,000 chars once quoted, so under about 27,000 diff chars, fewer when the diff has many `"`). A **single file** too
87
+ big for agy gets its own batch: agy skips it and the next provider reviews it. With no other provider (no
88
+ DeepSeek or GLM key), that file gives exit **3**. Exit **4** means a **single file** over the 60,000 ceiling,
89
+ or more batches than the cap. When you see either, review that one file separately (or add a key for an
90
+ HTTP provider), not a narrower `--range`; don't raise `--max-diff-chars` blind.
91
+
92
+ **The verdict is the last line.** Only the last non-empty line of the reply counts, and it must be
93
+ exactly `REVIEW: CLEAN` or `REVIEW: BLOCKING`. A reply that quotes the marker earlier and ends some other
94
+ way has no verdict (exit 4). An explicit `--range` with no changes is exit **3** (a review of nothing is not
95
+ CLEAN); the working tree with no changes is still CLEAN. When the secret filter drops some files, the
96
+ output ends with `REVIEW-SCOPE: PARTIAL (<n> file(s) excluded by the secret filter: <names>)` and then the
97
+ overall `REVIEW:` line. The exit code does not change, but the excluded files were **not reviewed**: say so,
98
+ and never report the result as a full CLEAN.
88
99
 
89
100
  **Do not alternate providers on a schedule.** The order is the owner policy (21 Oct 2026): **agy Argon,
90
101
  then DeepSeek, then GLM** (`REVIEW_ORDER` in `oss_review.py`). A named `--provider` goes first; on a provider failure
@@ -103,7 +114,8 @@ a reason.
103
114
  - **1 — REVIEW: BLOCKING** → read the printed findings, then **FIX each blocking item** (or explicitly
104
115
  justify why one is a false positive). Fix it, then re-review only the fix diff. After 3 rounds, ask the owner (rule 3).
105
116
  - **4 — error** → no verdict parsed, or a git/endpoint failure. Read stderr; do NOT treat as clean.
106
- - **3 — could not run** → no key (see Prerequisite), the secret filter refused, or every provider
117
+ - **3 — could not run** → no key (see Prerequisite), the secret filter refused, an explicit `--range` has
118
+ no changes, or every provider
107
119
  failed (429, 5xx, timeout, empty reply). Read stderr. A provider failure is not a verdict: re-run later.
108
120
 
109
121
  ## Three rules: one attempt, one review
@@ -422,6 +422,11 @@ Status words (one vocabulary, `scripts/caddis_status.py`): done is `done`, `merg
422
422
  `in progress`, `blocked` and `moved` name the other states; anything else (`not started`, `☐`) is to do. A cell
423
423
  that says `pending` is never done.
424
424
 
425
+ The plan's frontmatter `status:` is a different axis from these cells. Use only the known words:
426
+ `draft` (being written), `proposed` (written, not agreed), `ready` (agreed, waiting), `current` (work is under
427
+ way), then `done` or `superseded`. Never `in-progress`, `active` or `wip`: `check_doc_coverage.py` warns on
428
+ them and suggests the nearest known word.
429
+
425
430
  ## Per-symbol grep preflight (before the plan is committed)
426
431
  Check every name a card gives: each symbol, file, line number and CSS variable. Use one grep per name
427
432
  (Grep, or `git grep -n`) before you commit the plan. Fix the card when a name or a line number differs.
@@ -24,6 +24,8 @@ them into its commit, so check first, before Step 1.
24
24
  ```
25
25
  It prints `SHARED: yes <reason>` or `SHARED: no` and exits 0. It says yes when the root `AGENTS.md`
26
26
  has a line `Shared checkout: yes`, or when `git status` lists a path this session did not change.
27
+ Files that caddis writes itself (the generated index `.caddis/relay.md`, `*.jsonl` logs, locks and `.bak`
28
+ copies in `.caddis/`) never count as another session's change.
27
29
  3. **On `SHARED: no`,** do the steps below as written.
28
30
  4. **On `SHARED: yes`,** write NO tracked file in this checkout. Run:
29
31
  ```
@@ -31,6 +33,11 @@ them into its commit, so check first, before Step 1.
31
33
  ```
32
34
  It makes a new worktree from `origin/<default>` on a `docs/handoff-<utc>` branch and prints
33
35
  `WORKTREE: <path>`. That worktree is this session's only; no other session's edits can enter it.
36
+ **If the repo has no `origin` remote,** it exits 3 and prints
37
+ `no remote: commit explicit paths in place (git add <named files>; git commit)`. A docs PR needs a
38
+ remote, so skip the worktree path: name each file this session changed, `git add` those files only
39
+ (never `-A` or a directory), commit them, and leave every other dirty path alone. The tool commits nothing
40
+ itself. Then do the steps below as written, in this checkout.
34
41
  Then, in the steps below:
35
42
  - Step 1: tell the `knowledge-transfer` subagent to edit files ONLY under the `WORKTREE:` path.
36
43
  - Step 3, point 4: make the plan's Tracker edit in `<worktree>/.caddis/plans/<feature>.md`, and write
@@ -200,8 +207,11 @@ Nothing to say is the normal answer. Say nothing and move on — this must not b
200
207
  <!-- /shared:harness-friction-question -->
201
208
 
202
209
  ## Step 3 — write the resume doc (overwrite) with exactly these sections
203
- Write the relay from scratch with the current state only. Never append to the old text: git keeps the
204
- history, and the relay has a 4,000-character budget (`caddis_budget.py`).
210
+ Write the relay from scratch with the current state only. Never append to the old text. The relay has a
211
+ 4,000-character budget (`caddis_budget.py`), and `put`/`write` refuse a longer relay. `.caddis/relay/` is
212
+ git-ignored, so git keeps no history of it: before you rewrite a long relay, copy it to
213
+ `.caddis/relay/<name>.md.bak`. Keep any other note in `.caddis/relay/` under the same 4,000 characters (the
214
+ budget covers every `*.md` file there); put a longer note elsewhere, for example under `.caddis/kb/`.
205
215
 
206
216
  > **Where to write:** this session's own workstream relay, `.caddis/relay/<name>.md`, through the
207
217
  > locked script — never with a plain file edit, which would skip the conflict check. `.caddis/relay.md`
@@ -259,7 +259,10 @@ row, visible to any later reader without anyone having to catch it live.
259
259
  refusal). If you checked the finding and it is false, add
260
260
  `--override-review "<why the finding is false>"`. For a `MISSING` review, re-run the review
261
261
  first; add the override only if the owner accepts a phase with no vendor verdict. The reason
262
- must not be empty. The script records it in the packet.
262
+ must not be empty. The script records it in the packet. It also refuses a `PARTIAL` review
263
+ (the secret filter dropped files, so CLEAN covers only part of the diff); review the dropped
264
+ files yourself before you add an override. A lane that committed gets no review
265
+ (`COMMITTED`, `NEXT: redo`), and accept refuses any lane commit, even with an override.
263
266
  4. Allow at most **2 attempts** per phase on a non-Claude lane. An out-of-budget switch is not an
264
267
  attempt. The owner can request TAKEOVER at any time.
265
268
  5. A UI phase needs a `ui-design-reviewer` screenshot review before ACCEPT. This rule applies
@@ -183,7 +183,8 @@ unattended; `-Plan <slug>` runs one plain plan instead (the two are exclusive).
183
183
  and deletes the claim.
184
184
  CONTINUE with the phase already merged on origin: `rollup` when every phase is merged, then back to 1. CONTINUE
185
185
  with no new commits and nothing merged stops FAILED. `STATUS: OWNER-GATE <r>` becomes an `owner-gate` blocker,
186
- `STATUS: BLOCKED <r>` an `external` one; then back to 1. `STATUS: FAILED` stops.
186
+ `STATUS: BLOCKED <r>` an `external` one; then back to 1. `STATUS: FAILED` stops. A relay the session did not
187
+ change (the same hash as before it, whatever its status line) stops `FAILED no relay written`.
187
188
  5. Every `**Risk:** high` phase done on the branch and not yet reviewed clean (record in the runner's own folder:
188
189
  `<git common dir>/caddis-runner/roadmap-<slug>/reviewed/<plan>.json`; another runner's record does not count) is
189
190
  reviewed BEFORE step 4 writes the claim and publishes
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "caddis-extras",
3
- "version": "1.3.48",
3
+ "version": "1.3.49",
4
4
  "description": "caddis-extras — the long-tail skills for the Antigravity (agy) caddis plugin; install alongside caddis for the full set."
5
5
  }
@@ -80,10 +80,10 @@ python "$TOOL" --range origin/main..HEAD # review a branch's c
80
80
  ```
81
81
  Optional flags: `--cwd <repo>`, `--base-url <url>`, `--model <id>` (override the env).
82
82
 
83
- **Diff-size ceiling.** A diff over `REVIEW_MAX_DIFF_CHARS` (default 60,000 chars) is **split into batches** on whole-file boundaries and each batch reviewed separately (verdict is CLEAN only if every batch is). Exit 4 means a *single unsplittable file* over the ceiling, or too many batches — not an ordinary large diff. Previously it was refused before any LLM call
84
- *before* any LLM call — an oversized diff has been observed to come back either an empty response, or
85
- worse, a `REVIEW: CLEAN` with zero real engagement. If you hit this, narrow `--range` or review in
86
- smaller chunks; don't just raise `--max-diff-chars` without knowing the endpoint's real limit.
83
+ **Diff-size ceiling.** A diff over `REVIEW_MAX_DIFF_CHARS` (default 60,000 chars) is **split into batches** on whole-file boundaries and each batch reviewed separately (verdict is CLEAN only if every batch is). When agy Argon is anywhere in the provider chain, each batch is also kept small enough that its **whole prompt** fits the agy command line (28,000 chars once quoted, so under about 27,000 diff chars, fewer when the diff has many `"`). A *single file* too big for agy gets its own batch: agy skips it and the next provider reviews it; with no other provider (no DeepSeek or GLM key) that is exit 3. Exit 4 means a *single unsplittable file* over the 60,000 ceiling, or too many batches — not an ordinary large diff. The ceiling exists because an oversized diff has been observed to come back either an empty response, or
84
+ worse, a `REVIEW: CLEAN` with zero real engagement. If you hit this, review that file separately or narrow `--range`; don't just raise `--max-diff-chars` without knowing the endpoint's real limit.
85
+
86
+ **Verdict and scope.** Only the last non-empty line of the reply counts, and it must be exactly `REVIEW: CLEAN` or `REVIEW: BLOCKING`; a reply that quotes the marker earlier and ends some other way has no verdict (exit 4). An explicit `--range` with no changes is exit 3 (a review of nothing is not CLEAN); the working tree with no changes is still CLEAN. When the secret filter drops some files, the output ends with `REVIEW-SCOPE: PARTIAL (<n> file(s) excluded by the secret filter: <names>)` and then the overall `REVIEW:` line. The exit code does not change, but those files were not reviewed: say so, and never report it as a full CLEAN.
87
87
 
88
88
  ## Interpret the exit code
89
89
  - **0 — REVIEW: CLEAN** → no blocking issues. Proceed.
@@ -92,7 +92,7 @@ smaller chunks; don't just raise `--max-diff-chars` without knowing the endpoint
92
92
  Fix it, then re-review only the fix diff. After 3 rounds, ask the owner (rule 3).
93
93
  - **4 — error** → no verdict parsed, a git failure, or an endpoint/parse failure. Read stderr; do not
94
94
  treat this as CLEAN — investigate.
95
- - **3 — could not run** → no reviewer is available (no agy on PATH and no API key), or every provider failed. Fix it (see Prerequisites) and re-run.
95
+ - **3 — could not run** → no reviewer is available (no agy on PATH and no API key), an explicit `--range` has no changes, or every provider failed. Fix it (see Prerequisites) and re-run.
96
96
 
97
97
  ## Three rules: one attempt, one review
98
98
  1. **Think before you send.** Before a task goes to any coder, write its edge cases and check the facts it depends on (one query or one file read).
@@ -183,7 +183,8 @@ unattended; `-Plan <slug>` runs one plain plan instead (the two are exclusive).
183
183
  and deletes the claim.
184
184
  CONTINUE with the phase already merged on origin: `rollup` when every phase is merged, then back to 1. CONTINUE
185
185
  with no new commits and nothing merged stops FAILED. `STATUS: OWNER-GATE <r>` becomes an `owner-gate` blocker,
186
- `STATUS: BLOCKED <r>` an `external` one; then back to 1. `STATUS: FAILED` stops.
186
+ `STATUS: BLOCKED <r>` an `external` one; then back to 1. `STATUS: FAILED` stops. A relay the session did not
187
+ change (the same hash as before it, whatever its status line) stops `FAILED no relay written`.
187
188
  5. Every `**Risk:** high` phase done on the branch and not yet reviewed clean (record in the runner's own folder:
188
189
  `<git common dir>/caddis-runner/roadmap-<slug>/reviewed/<plan>.json`; another runner's record does not count) is
189
190
  reviewed BEFORE step 4 writes the claim and publishes
@@ -1,8 +1,8 @@
1
1
  {
2
- "poolVersion": "1.3.174",
2
+ "poolVersion": "1.3.175",
3
3
  "bundles": {
4
- "antigravity-plugin": "1.3.174",
5
- "antigravity-plugin-extras": "1.3.48",
4
+ "antigravity-plugin": "1.3.175",
5
+ "antigravity-plugin-extras": "1.3.49",
6
6
  "codex": "unknown"
7
7
  }
8
8
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@caddis/cli",
3
- "version": "0.4.90",
3
+ "version": "0.4.91",
4
4
  "description": "Install, update and diagnose the caddis dev harness across every coding agent you use (Claude Code, agy/Antigravity, and more).",
5
5
  "keywords": [
6
6
  "caddis",