jonah-fleet 1.21.0 → 1.22.0
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.
- package/CHANGELOG.md +12 -0
- package/package.json +1 -1
- package/templates/docs/AGENTS.template.md +5 -0
- package/templates/prompts/ORCHESTRATION.md +42 -0
- package/templates/prompts/_prompt-template.md +7 -0
- package/templates/prompts/autowork.md +16 -1
- package/templates/prompts/peer-review.md +17 -0
- package/templates/skills/code-review/SKILL.md +1 -1
- package/templates/skills/tdd/SKILL.md +5 -2
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,13 @@ All notable changes to `jonah-fleet` will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [1.22.0](https://github.com/juliendurandeu/jonah-fleet/compare/v1.21.0...v1.22.0) (2026-09-20)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **orchestration:** adopt Chief of Staff verification and Red Gate discipline ([#308](https://github.com/juliendurandeu/jonah-fleet/issues/308)) ([7e669de](https://github.com/juliendurandeu/jonah-fleet/commit/7e669de7e56a0fbe0feb0f694b2d29439416b421))
|
|
14
|
+
|
|
8
15
|
## [1.21.0](https://github.com/juliendurandeu/jonah-fleet/compare/v1.20.0...v1.21.0) (2026-09-20)
|
|
9
16
|
|
|
10
17
|
|
|
@@ -16,6 +23,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
16
23
|
|
|
17
24
|
### Features
|
|
18
25
|
|
|
26
|
+
* **orchestration:** adopt Chief of Staff verification discipline, mandatory Red Gate protocol, Bogus Green Check defect taxonomy, disk read-back verification, and precision path-scoped git commits across prompts and engineering skills.
|
|
27
|
+
* **prompts:** embed 6-part Bogus Green Check defect taxonomy (Vacuous assertion, Silent no-match, Errored check, Wrong reference, Stale premise, Scope mismatch) into `peer-review.md` and `/code-review`.
|
|
28
|
+
* **prompts:** add mandatory Red Gate pre-implementation check to `autowork.md` and `/tdd`, catching already-resolved tasks and vacuous tests before code changes.
|
|
29
|
+
* **prompts:** enforce disk read-back verification directly from written files and precision path-scoped git commits (`git commit -m "..." -- <paths>`).
|
|
30
|
+
* **prompts:** enforce autonomous surfacing cadence without rhetorical permission halts ("Shall I continue?") across routines.
|
|
19
31
|
* **guard:** exempt `manage_task` status and list polling from action repetition and ping-pong circuit breaker trips in `run-with-loop-guard.js`.
|
|
20
32
|
* **housekeeping:** close `status:failure` routine log issues immediately (0-hour delay) if target is already closed or merged, and lower untargeted runner crash threshold to 12 hours.
|
|
21
33
|
* **autowork:** update Step 9 idle sweep to close resolved-target failures immediately and untargeted crashes after 12 hours.
|
package/package.json
CHANGED
|
@@ -40,6 +40,11 @@ tests/ # Test suites
|
|
|
40
40
|
- **Separation of Concerns**: Keep business logic pure and isolated from UI rendering and framework adapters.
|
|
41
41
|
- **Error Handling**: Validate inputs at server and module boundaries. Return explicit structured errors.
|
|
42
42
|
- **Testing Philosophy**: Write regression unit tests for every bug fix and integration tests for key workflows.
|
|
43
|
+
- **The Red Gate Invariant**: Always execute a failing test or verifier before modifying code. If the check passes before changes, diagnose immediately whether the issue is already resolved or the test is a vacuous assertion.
|
|
44
|
+
- **Defect Taxonomy of Bogus Green Checks**: Interrogate verification against the 6 defect shapes (Vacuous assertion, Silent no-match, Errored check, Wrong reference, Stale premise, Scope mismatch). Always prove a positive before believing a negative.
|
|
45
|
+
- **Anti-Hallucination Disk Read-Back**: Verify generated code, configs, and artifacts by reading values directly back from the file on disk, never from in-memory variables or shell command echoes.
|
|
46
|
+
- **Precision Git Scoping**: Never run bare `git commit` or blind `git add .` in multi-agent environments. Scope commits explicitly (`git commit -m "..." -- <paths>`).
|
|
47
|
+
- **Autonomous Surfacing Cadence**: Timeboxing is for surfacing progress, never for stopping. Checkpoints report status without halting execution. Never yield the turn or ask rhetorical permission questions ("Shall I continue?").
|
|
43
48
|
|
|
44
49
|
## Requirements Discovery & Inquisitive Stance
|
|
45
50
|
|
|
@@ -321,6 +321,48 @@ How autonomous routines escalate decisions, ambiguities, and blockers to human m
|
|
|
321
321
|
|
|
322
322
|
---
|
|
323
323
|
|
|
324
|
+
## The Red Gate Protocol & Verification Discipline
|
|
325
|
+
|
|
326
|
+
How agent routines ensure that tests, benchmarks, and verification commands are authoritative rather than vacuous:
|
|
327
|
+
|
|
328
|
+
1. **The Red Gate (Pre-Implementation Failure Proof)**:
|
|
329
|
+
- Before writing any production code, the agent MUST formulate a reproduction test or verifier and execute it.
|
|
330
|
+
- **The check MUST fail** (red). If the check passes before any source code is changed, the subsequent work proves nothing.
|
|
331
|
+
- **Already Green Check**: If the check passes before changes, stop and evaluate:
|
|
332
|
+
- *Already Resolved*: If the requested behavior is already present in `origin/main`, close the issue as resolved, release the claim, and proceed to the next candidate. This single command check saves hours of redundant implementation.
|
|
333
|
+
- *Vacuous Assertion*: If the feature is missing but the test is green, the test is vacuous. Refactor the test until it reliably fails against the baseline before modifying code.
|
|
334
|
+
2. **Defect Taxonomy of Bogus Green Checks**:
|
|
335
|
+
The most expensive errors in agentic engineering come from checks that report success for work they did not do. Verifiers and peer reviewers must audit for the 6 bogus green defect classes:
|
|
336
|
+
- **Vacuous assertion**: A test that passes whether or not the feature works (deleting the implementation under test leaves it green).
|
|
337
|
+
- **Silent no-match**: A grep, regex, linter, or predicate that matches nothing; zero matches falsely reads as "clean".
|
|
338
|
+
- **Errored check**: A command that failed to run or crashed (e.g. exit code 127 or syntax error), but the error was swallowed, reading absence as success. Exit codes are authoritative; agent summaries are intent.
|
|
339
|
+
- **Wrong reference**: A filter or diff baseline keyed on the wrong commit or tag (e.g. `HEAD~1` instead of `origin/main`), letting regressions slip through.
|
|
340
|
+
- **Stale premise**: An assertion whose expected value was copied directly off existing broken code, cementing the bug it was meant to catch.
|
|
341
|
+
- **Scope mismatch**: A green check executed only over a narrow subset presented as the whole (missing denominator).
|
|
342
|
+
3. **Prove a Positive Before Believing a Negative**:
|
|
343
|
+
Before accepting an assertion that a defect or pattern is absent, verify that the check or tool flags a known-bad positive control. A tool that reports "clean" and a tool that is broken produce identical zero output.
|
|
344
|
+
4. **Anti-Hallucination Disk Read-Back Verification**:
|
|
345
|
+
Always verify generated files, configs, and artifacts by reading values directly back from the written artifact on disk (`cat`, `jq`, file assertions), never from an in-memory variable, shell echo, or assumption.
|
|
346
|
+
|
|
347
|
+
---
|
|
348
|
+
|
|
349
|
+
## Durable Channels Beat Ephemeral Ones
|
|
350
|
+
|
|
351
|
+
How autonomous agents manage state, handoffs, and communication across sessions:
|
|
352
|
+
|
|
353
|
+
1. **Messages are Nudges, Files are Contracts**: Direct messaging between agents or subagents is useful for lightweight coordination, but can be dropped, delayed, or compacted. Anything that must survive and govern execution belongs in a durable channel:
|
|
354
|
+
- **Committed Policy**: Coding standards, conventions, and invariants belong in committed files (`AGENTS.md`, `.github/prompts/`).
|
|
355
|
+
- **Work Contracts**: Task descriptions, acceptance criteria, and status belong on the board (GitHub Issues, PR descriptions, or committed markdown briefs like `docs/briefs/`).
|
|
356
|
+
- **Pointer-Based Dispatch**: Pass links or file paths (`Context: <url>` or `Read docs/briefs/task.md`) in subagent launch prompts rather than pasting massive volatile blobs of text into prompts.
|
|
357
|
+
2. **Policy vs. Ephemeral Separation**:
|
|
358
|
+
Keep long-lived policy (rules that govern every cycle) strictly separate from ephemeral session scratch. Never mix temporary task artifacts into long-lived documentation.
|
|
359
|
+
3. **Autonomous Surfacing Cadence (No Permission Traps)**:
|
|
360
|
+
Timeboxing in autonomous runs is for surfacing progress, never for stopping. Checkpoints report status without halting execution. Autonomous agents MUST NEVER yield turns or ask rhetorical permission questions (e.g. "Shall I continue?", "Proceed to merge?").
|
|
361
|
+
4. **Precision Git Scoping in Multi-Agent Environments**:
|
|
362
|
+
In environments where multiple agents, subagents, or local background commands operate, never execute bare `git commit` or blind `git add .`. Always scope commits explicitly with `git commit -m "..." -- <paths>` or verify `git status --porcelain` to avoid sweeping in uncommitted scratch files or parallel agent artifacts.
|
|
363
|
+
|
|
364
|
+
---
|
|
365
|
+
|
|
324
366
|
## 3-Tier Prompt Prefix Caching Architecture
|
|
325
367
|
|
|
326
368
|
How Jonah Fleet partitions prompt structures into Static $\rightarrow$ Semi-Stable $\rightarrow$ Dynamic tiers inspired by Orbital v0.4.2's prefix-caching architecture to achieve $>90\%$ cache hit rates on modern LLMs (Gemini, Anthropic, OpenAI), drastically reducing invocation latency and safeguarding the 70% weekly token budget ceiling:
|
|
@@ -49,12 +49,19 @@ If any criterion cannot be met, stop immediately and log FAILURE with the reason
|
|
|
49
49
|
- **No speculative work**: only take actions directly required by the Definition of Done. Do not refactor adjacent code, open bonus issues, or add improvements not requested.
|
|
50
50
|
- **Language Requirement**: All GitHub issue titles, descriptions, task checklists, and comments MUST be written in **English**.
|
|
51
51
|
- **Session link footer**: sign every GitHub post with the Antigravity run footer (`_Generated by [Antigravity](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})_`).
|
|
52
|
+
- **Autonomous Surfacing Cadence (No Permission Traps)**: Timeboxing is for surfacing progress, never for stopping. Checkpoints report status without halting execution. Never yield the turn or ask rhetorical permission questions (e.g. "Shall I continue?"). Proceed autonomously.
|
|
53
|
+
- **Defect Taxonomy of Bogus Green Checks**: The most expensive errors in agentic engineering come from checks reporting success for work they did not do. Interrogate verification against the 6 defect classes (Vacuous assertion, Silent no-match, Errored check, Wrong reference, Stale premise, Scope mismatch). Exit codes decide, summaries are intent.
|
|
54
|
+
- **Anti-Hallucination Disk Read-Back Verification**: Always verify generated code, configs, and artifacts by reading values directly back from the written artifact on disk, never from in-memory variables or shell echoes.
|
|
55
|
+
- **Precision Git Scoping**: Never execute bare `git commit` or blind `git add .`. Scope commits explicitly with `git commit -m "..." -- <paths>` or verify `git status --porcelain` to avoid sweeping in uncommitted scratch files or parallel agent artifacts.
|
|
52
56
|
|
|
53
57
|
## Negative examples (DO NOT do these)
|
|
54
58
|
|
|
55
59
|
- {Example of a wasteful pattern, e.g. "Do not re-read files you already read in this run"}
|
|
56
60
|
- {Example of scope creep, e.g. "Do not fix lint warnings unrelated to the task"}
|
|
57
61
|
- {Example of token burn, e.g. "Do not retry a failing API call more than twice"}
|
|
62
|
+
- Do not pause or prompt rhetorical questions ("Shall I proceed?", "Do you want me to continue?")—execute the steps autonomously.
|
|
63
|
+
- Do not use bare `git commit` or blind `git add .` without scoping specific paths (`git commit -m "..." -- <paths>`).
|
|
64
|
+
- Do not verify generated files by checking in-memory strings; read values back out of the file on disk.
|
|
58
65
|
|
|
59
66
|
## Instructions
|
|
60
67
|
|
|
@@ -38,6 +38,10 @@ If any criterion cannot be met, stop immediately and log FAILURE with the reason
|
|
|
38
38
|
- **Language Requirement**: All GitHub issue titles, descriptions, task checklists, and comments MUST be written in **English**.
|
|
39
39
|
- **Session link footer**: sign every GitHub post (issue comments, PR comments, PR descriptions) with the Antigravity run footer (`_Generated by [Antigravity](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})_`). Inline review-thread line comments are exempt.
|
|
40
40
|
- **Headless Execution & Asynchronous Non-Yielding Guardrail**: You are running in a headless autonomous session. You MUST NEVER call `schedule` or yield the turn with plain text while waiting for background tasks or verification checks. If a verification command runs in the background, actively inspect its completion with `manage_task` or run with sufficient `WaitMsBeforeAsync` (up to `10000` ms). Never stop calling tools or yield your turn until the routine's terminal Definition of Done is fully reached.
|
|
41
|
+
- **Autonomous Surfacing Cadence (No Permission Traps)**: Timeboxing is for surfacing progress, never for stopping. Checkpoints report status without halting execution. Never yield the turn or ask rhetorical permission questions (e.g. "Shall I continue?", "Proceed with implementation?"). Proceed with the next step autonomously.
|
|
42
|
+
- **Defect Taxonomy of Bogus Green Checks & Red Gate Verification**: Always establish a failing reproduction check or verifier before modifying code (the Red Gate). Interrogate checks against the 6 bogus green defect classes (Vacuous assertion, Silent no-match, Errored check, Wrong reference, Stale premise, Scope mismatch). Exit codes decide; summaries are intent.
|
|
43
|
+
- **Anti-Hallucination Disk Read-Back Verification**: Always verify generated code, configs, and artifacts by reading values directly back out of the written artifact on disk, never from in-memory variables or shell command echoes.
|
|
44
|
+
- **Precision Git Scoping**: Never execute bare `git commit` or blind `git add .` without scoping. Always commit designated paths explicitly (`git commit -m "..." -- <paths>`) or verify `git status --porcelain` to avoid sweeping in uncommitted scratch artifacts or concurrent session files.
|
|
41
45
|
|
|
42
46
|
## Negative examples (DO NOT do these)
|
|
43
47
|
|
|
@@ -55,6 +59,10 @@ If any criterion cannot be met, stop immediately and log FAILURE with the reason
|
|
|
55
59
|
- Do not fall into the **Telemetry Rabbit Hole**: do not spend cycles instrumenting elaborate fallback telemetry or defensive error handling for features that suffer from lack of user intent rather than software bugs.
|
|
56
60
|
- Do not guess or invent arbitrary specifications for ambiguous issues — post the 4-part escalation card ('Why I believe this'), label `needs-info`, and release the claim instead of blindly writing code.
|
|
57
61
|
- Do not call `schedule` or yield the turn with plain text while waiting for background verification tasks — stay in the tool loop until the Definition of Done is met.
|
|
62
|
+
- Do not write implementation code before proving that the reproduction test or verifier fails (the Red Gate).
|
|
63
|
+
- Do not pause or prompt rhetorical questions ("Shall I continue?", "Should I start implementing?")—proceed autonomously.
|
|
64
|
+
- Do not use bare `git commit` or blind `git add .` without scoping specific paths (`git commit -m "..." -- <paths>`).
|
|
65
|
+
- Do not verify generated files by checking in-memory strings or shell variables; read values back out of the file on disk.
|
|
58
66
|
|
|
59
67
|
## Instructions
|
|
60
68
|
|
|
@@ -206,6 +214,11 @@ _Generated by [Antigravity](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/ru
|
|
|
206
214
|
- If bug: use `/diagnosing-bugs` to establish reproduction test before fixing.
|
|
207
215
|
- If large/complex: use `/domain-modeling` and `/codebase-design`.
|
|
208
216
|
- **Pre-Flight Memory Scan**: If `LESSONS.md` exists, grep matching subsystem tags (`grep -E "^### \[(subsystem)\]" LESSONS.md -A 4`) to incorporate known landmines into implementation plans before writing code.
|
|
217
|
+
- **The Red Gate Protocol (Pre-Implementation Verifier Check)**: Before writing ANY production implementation code, define the verifier or write a reproduction test, and execute it:
|
|
218
|
+
- **The check MUST fail** (red). If the verifier passes before you touch production code, the subsequent work proves nothing.
|
|
219
|
+
- **Already Green Check**: If the verifier passes *before* code changes, stop immediately and evaluate:
|
|
220
|
+
1. *Already Resolved*: If the requested behavior or fix is already present in `origin/main` (e.g. shipped under another card or refactor), verify thoroughly, close the issue immediately (`gh issue close <ISSUE_NUMBER> --comment "Closed: verified already resolved on main."`), release the claim, and proceed to the next candidate. Running the Red Gate first catches stale work in seconds and saves hours of redundant coding.
|
|
221
|
+
2. *Vacuous Assertion (Bogus Green)*: If the feature is missing but the test passes, the test is vacuous (silent no-match, erring swallowed command, or trivial assertion). Refactor the test until it reliably fails against the baseline before implementing.
|
|
209
222
|
- **Ambiguity & Missing Acceptance Criteria Gate**: Challenge underspecified or incomplete requests before writing any code. If the issue lacks observable acceptance criteria, relies on unverified assumptions, or leaves critical technical/UX decisions ambiguous:
|
|
210
223
|
- Do NOT guess or invent arbitrary requirements to force completion.
|
|
211
224
|
- Post the mandatory 4-part escalation card on the issue:
|
|
@@ -242,9 +255,11 @@ _Generated by [Antigravity](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/ru
|
|
|
242
255
|
```
|
|
243
256
|
13. **Implementation & PR creation:**
|
|
244
257
|
- Branch from freshly fetched `origin/main` with descriptive name (e.g. `feat/...` or `fix/...`).
|
|
245
|
-
- Drive implementation via `/tdd` (red-green-refactor).
|
|
258
|
+
- Drive implementation via `/tdd` (red-green-refactor): execute the Red Gate test first, write minimal code to pass, and refactor cleanly.
|
|
259
|
+
- **Precision Git Scoping**: Never use bare `git commit` or `git add .` blindly. Stage and commit only designated paths explicitly: `git commit -m "<type>(<scope>): <subject>" -- <paths>`, or verify `git status --porcelain` before committing to avoid sweeping in scratch files or parallel artifacts.
|
|
246
260
|
- **Diagnostic Reflex**: On unexpected test/build failure during TDD, grep symptom text in `LESSONS.md` before making speculative code edits.
|
|
247
261
|
- Run repository tests and verification.
|
|
262
|
+
- **Disk Read-Back Verification**: Verify written configs, schemas, and generated files by reading values directly back from disk files (`cat`, `jq`, test assertions), never from shell variables or memory.
|
|
248
263
|
- **Pre-PR Lessons Capture Gate**: If solving the issue required overcoming a non-obvious quirk not caught by tests/linters, append a 3-line structured entry on the active PR branch adhering to the 25-entry hard cap. Never write to `LESSONS.md` directly on `main`.
|
|
249
264
|
- **Milestone 2 (Verification & Tests)**: Once implementation passes tests and type checks, emit milestone card if `$ROUTINE_ISSUE_NUMBER` is set:
|
|
250
265
|
```bash
|
|
@@ -43,6 +43,10 @@ If any criterion cannot be met, stop immediately and log FAILURE with the reason
|
|
|
43
43
|
- **Session link footer**: sign every GitHub post with the Antigravity run footer (`_Generated by [Antigravity](${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}/actions/runs/${GITHUB_RUN_ID})_`).
|
|
44
44
|
- **Headless Execution & Asynchronous Non-Yielding Guardrail**: You are running in a headless autonomous CLI session. You MUST NEVER call `schedule` or yield the turn with plain text to "wait" for background tasks, timers, or long-running commands. In headless CLI mode, yielding the turn terminates the session immediately before reaching the Definition of Done. When invoking `run_command` for test runs or type checks, ALWAYS set `WaitMsBeforeAsync` high enough (up to the maximum `10000` ms) or if a command moves to the background, keep your execution turn active by checking task status (`manage_task(Action='status')`) or inspecting files; NEVER call `schedule` or emit a terminal turn with plain text before taking the final action.
|
|
45
45
|
- **Verification Command & CI Discipline**: When remote CI checks (e.g. GitHub Actions, Vercel preview deployments) are already present and passed on the PR's head commit, treat CI as verified and green. Avoid executing slow, redundant local full test suites or full type-checks when CI is already green. Run local verification commands (`npm test`, `npm run type-check`) ONLY if CI is missing, unconfirmed, or failing.
|
|
46
|
+
- **Autonomous Surfacing Cadence (No Permission Traps)**: Timeboxing is for surfacing progress, never for stopping. Checkpoints report status without halting execution. Never yield the turn or prompt rhetorical permission questions (e.g. "Shall I continue?", "Proceed to merge?"). Take authoritative final action autonomously.
|
|
47
|
+
- **Defect Taxonomy of Bogus Green Checks**: The most expensive errors in agentic engineering come from checks reporting success for work they did not do. Audit verification against the 6 defect shapes (Vacuous assertion, Silent no-match, Errored check, Wrong reference, Stale premise, Scope mismatch). Exit codes and concrete diffs are authoritative; agent summaries are merely intent.
|
|
48
|
+
- **Anti-Hallucination Disk Read-Back Verification**: Verify artifacts, generated configs, or outputs by reading values directly back out of the written artifact on disk, never from an in-memory variable, shell echo, or assumption.
|
|
49
|
+
- **Reader / Writer Separation**: Peer Review is strictly an evaluator and merge authority. Never write or commit code modifications to the PR branch directly; bounce to draft so the author or autowork session applies the fix in their warm context.
|
|
46
50
|
|
|
47
51
|
## Final action: merge or bounce to draft
|
|
48
52
|
|
|
@@ -70,6 +74,9 @@ Every review ends in exactly one of two states:
|
|
|
70
74
|
- Do not bounce an external contributor PR purely for missing `Closes #N` when the PR description provides a clear specification.
|
|
71
75
|
- Do not call `schedule` or yield the turn with plain text while waiting for background verification tasks — stay in the tool loop until the final action is taken.
|
|
72
76
|
- Do not rerun full local test suites when remote CI checks on the head commit are already green and passing.
|
|
77
|
+
- Do not write implementation code or modify the PR branch directly—bounce to draft with specific actionable findings instead.
|
|
78
|
+
- Do not accept checks or tests that pass vacantly or match zero items without positive controls.
|
|
79
|
+
- Do not pause or prompt rhetorical questions ("Shall I proceed?", "Do you want me to merge?")—execute the final action autonomously.
|
|
73
80
|
|
|
74
81
|
## Instructions
|
|
75
82
|
|
|
@@ -136,6 +143,16 @@ Check if `$PR_NUMBER` is set:
|
|
|
136
143
|
- **Funnel Completeness**: For new Tier 1 user funnels or critical workflows, verify the telemetry contract: impression denominator (`_shown`), interaction (`_clicked`), and failure states (`_failed` with `reason`) are captured, and events are documented in the custom events catalog (`ARCHITECTURE.md` / `DATA_CONTEXT.md`). Flag missing denominators on core funnels as blocking.
|
|
137
144
|
5. If PR modifies rendered UI, verify screenshots or visual components if tooling/scripts are available.
|
|
138
145
|
6. Run repository verification commands (tests, type-check) ONLY if CI status is unconfirmed or failing. If remote CI (such as GitHub Actions or Vercel preview) is already green and passing on the head commit, treat CI as verified. If verification commands must be run locally, specify `WaitMsBeforeAsync: 10000` and NEVER call `schedule` or yield the turn with plain text while waiting for background tasks.
|
|
146
|
+
7. **Anti-Vacuity & Verifier Audit Pass (The 6 Bogus Green Shapes)**:
|
|
147
|
+
Actively interrogate new or modified tests and verification commands against the 6 bogus green defect classes:
|
|
148
|
+
- **Vacuous assertion**: Test passes whether or not the feature works (e.g. deleting the implementation under test leaves it green). Require a red-gate failure or mutation check.
|
|
149
|
+
- **Silent no-match**: A grep, regex, linter, or predicate that matches nothing; 0 matches falsely reads as "clean / no errors".
|
|
150
|
+
- **Errored check**: A command that failed to run or crashed (e.g. exit code 127 or syntax error), but the failure was swallowed, reading absence as success. Exit codes decide; summaries are merely intent.
|
|
151
|
+
- **Wrong reference**: A filter or diff baseline keyed on the wrong commit, tag, or branch (e.g. `HEAD~1` instead of `origin/main`), letting intervening regressions slip through.
|
|
152
|
+
- **Stale premise**: An assertion whose expected value was copied directly off existing broken code, cementing the bug it was meant to catch.
|
|
153
|
+
- **Scope mismatch**: A green check executed only over a narrow subset presented as the whole (missing denominator).
|
|
154
|
+
- **Prove a positive before believing a negative**: Before accepting an assertion that a defect or pattern is absent, verify that the check flags a known-bad positive control.
|
|
155
|
+
- **Disk Read-Back Verification**: Verify written configs, schemas, and generated artifacts by reading values directly back from the file on disk, not from shell variables or memory.
|
|
139
156
|
|
|
140
157
|
### Step 5: Classify Findings & Make Decision
|
|
141
158
|
|
|
@@ -67,7 +67,7 @@ Each smell reads *what it is* → *how to fix*; match it against the diff:
|
|
|
67
67
|
|
|
68
68
|
- The diff command and commit list.
|
|
69
69
|
- The path or fetched contents of the spec.
|
|
70
|
-
- The brief: "Report: (a) requirements the spec asked for that are missing or partial; (b) behaviour in the diff that wasn't asked for (scope creep); (c) requirements that look implemented but where the implementation looks wrong. Quote the spec line for each finding. Under 400 words."
|
|
70
|
+
- The brief: "Report: (a) requirements the spec asked for that are missing or partial; (b) behaviour in the diff that wasn't asked for (scope creep); (c) requirements that look implemented but where the implementation looks wrong. Quote the spec line for each finding. (d) Anti-Vacuity / Bogus Green Check audit: evaluate any new or modified tests against the 6 defect shapes (Vacuous assertion, Silent no-match, Errored check, Wrong reference, Stale premise, Scope mismatch). Verify that tests would actually fail if the implementation were removed, and that checks asserting absence prove a positive control first. Under 400 words."
|
|
71
71
|
|
|
72
72
|
If the spec is missing, skip the Spec sub-agent and note this in the final report.
|
|
73
73
|
|
|
@@ -28,11 +28,14 @@ When the shape of that interface is itself in question (how deep the module is,
|
|
|
28
28
|
## Anti-patterns
|
|
29
29
|
|
|
30
30
|
- **Implementation-coupled**: mocks internal collaborators, tests private methods, or verifies through a side channel (querying the database instead of using the interface). The tell: the test breaks when you refactor but behavior hasn't changed.
|
|
31
|
-
- **Tautological**: the assertion recomputes the expected value the way the code does (`expect(add(a, b)).toBe(a + b)`, a snapshot derived by hand the same way, a constant asserted equal to itself),
|
|
31
|
+
- **Tautological / Vacuous Assertion**: the assertion recomputes the expected value the way the code does (`expect(add(a, b)).toBe(a + b)`, a snapshot derived by hand the same way, a constant asserted equal to itself), or asserts a condition that passes whether or not the feature works. Deleting the code under test must make the test fail.
|
|
32
|
+
- **Silent No-Match**: a test filter, grep, or predicate that matches zero cases and reads as clean. Always prove a positive control before believing absence.
|
|
33
|
+
- **Stale Premise**: an assertion whose expected value was copied directly off broken code, cementing the bug it was meant to catch.
|
|
32
34
|
- **Horizontal slicing**: writing all tests first, then all implementation. Bulk tests verify _imagined_ behavior: you test the _shape_ of things rather than user-facing behavior, the tests go insensitive to real changes, and you commit to test structure before understanding the implementation. Work in **vertical slices** instead: one test → one implementation → repeat, each test a **tracer bullet** that responds to what the last cycle taught you.
|
|
33
35
|
|
|
34
36
|
## Rules of the loop
|
|
35
37
|
|
|
36
|
-
- **Red before green.** Write the failing test first,
|
|
38
|
+
- **The Red Gate (Red before green).** Write the failing test first, run it, and confirm it fails. If it passes before code is written, STOP: either the feature already exists (avoiding redundant work), or the test is vacuous. Only write enough code to turn the red gate green. Don't anticipate future tests or add speculative features.
|
|
37
39
|
- **One slice at a time.** One seam, one test, one minimal implementation per cycle.
|
|
40
|
+
- **Disk Read-Back Verification.** Verify artifacts and written configs by reading values directly back from the file on disk (`cat`, `jq`, file assertions), never from in-memory variables.
|
|
38
41
|
- **Refactoring is not part of the loop.** It belongs to the review stage (see the `code-review` skill), not the red → green implementation cycle.
|