@pilotspace/add 1.1.0 → 1.2.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.
Files changed (54) hide show
  1. package/CHANGELOG.md +40 -0
  2. package/GETTING-STARTED.md +165 -139
  3. package/README.md +13 -7
  4. package/bin/cli.js +13 -4
  5. package/docs/01-principles.md +3 -3
  6. package/docs/02-the-flow.md +15 -11
  7. package/docs/03-step-1-specify.md +13 -13
  8. package/docs/04-step-2-scenarios.md +2 -2
  9. package/docs/05-step-3-contract.md +3 -3
  10. package/docs/06-step-4-tests.md +2 -2
  11. package/docs/07-step-5-build.md +1 -1
  12. package/docs/08-step-6-verify.md +14 -5
  13. package/docs/09-the-loop.md +12 -6
  14. package/docs/10-setup-and-stages.md +27 -13
  15. package/docs/11-governance.md +2 -2
  16. package/docs/12-roles.md +3 -3
  17. package/docs/13-adoption.md +1 -1
  18. package/docs/14-foundation.md +15 -15
  19. package/docs/15-foundations-and-lineage.md +106 -0
  20. package/docs/README.md +4 -0
  21. package/docs/appendix-a-templates.md +3 -3
  22. package/docs/appendix-b-prompts.md +40 -5
  23. package/docs/appendix-c-glossary.md +42 -12
  24. package/docs/appendix-d-worked-example.md +2 -2
  25. package/docs/appendix-e-checklists.md +2 -2
  26. package/docs/appendix-f-requirements-matrix.md +8 -8
  27. package/docs/appendix-g-references.md +106 -0
  28. package/package.json +1 -1
  29. package/skill/add/SKILL.md +39 -37
  30. package/skill/add/adopt.md +13 -11
  31. package/skill/add/deltas.md +8 -6
  32. package/skill/add/fold.md +19 -17
  33. package/skill/add/graduate.md +74 -0
  34. package/skill/add/intake.md +22 -7
  35. package/skill/add/loop.md +59 -0
  36. package/skill/add/phases/0-setup.md +29 -24
  37. package/skill/add/phases/1-specify.md +23 -13
  38. package/skill/add/phases/2-scenarios.md +14 -4
  39. package/skill/add/phases/3-contract.md +24 -11
  40. package/skill/add/phases/4-tests.md +15 -5
  41. package/skill/add/phases/5-build.md +11 -4
  42. package/skill/add/phases/6-verify.md +24 -2
  43. package/skill/add/phases/7-observe.md +13 -5
  44. package/skill/add/report-template.md +65 -7
  45. package/skill/add/run.md +45 -34
  46. package/skill/add/scope.md +10 -6
  47. package/skill/add/setup-review.md +13 -10
  48. package/skill/add/streams.md +69 -19
  49. package/tooling/add.py +476 -34
  50. package/tooling/templates/CONVENTIONS.md.tmpl +1 -1
  51. package/tooling/templates/GLOSSARY.md.tmpl +23 -0
  52. package/tooling/templates/MILESTONE.md.tmpl +1 -0
  53. package/tooling/templates/PROJECT.md.tmpl +4 -3
  54. package/tooling/templates/TASK.md.tmpl +33 -12
@@ -1,4 +1,4 @@
1
- # CONVENTIONS (survivor layer — set once, kept for the whole project)
1
+ # CONVENTIONS (living documentation — set once, kept for the whole project)
2
2
 
3
3
  Language/framework: <e.g. Python 3.12 / FastAPI>
4
4
  Folders: .add/tasks/<slug>/{TASK.md, tests/, src/}
@@ -1,3 +1,26 @@
1
1
  # GLOSSARY (one name per concept — used everywhere: specs, contracts, code)
2
2
 
3
3
  <term>: <definition>
4
+
5
+ # ADD method vocabulary (domain-standard names; bridges to legacy terms)
6
+ GOAL: the one durable outcome a project (and each milestone) runs toward — the loop's orientation anchor, declared as the lowercase `goal:` line in PROJECT.md / MILESTONE.md and surfaced by status/guide every session; distinct from a task's §1 Must (a single required behavior, not the whole-project outcome).
7
+ deep verify: the deepened Verify evidence (v20) required beyond passing tests — for a task that produced code, that every new symbol is referenced (wiring) and no new dead/unused code exists; for prose/non-code, a recorded no-skim semantic read; which path applies is resolver-judged and the engine never classifies (a rubric, not add.py).
8
+ onboarding: the install -> first-milestone path (formerly "on-ramp").
9
+ primary flow: the solid forward path of the flow diagram — a phase starts only when its input exists (formerly "forward spine").
10
+ cross-cutting concern: a concern running through every step rather than being one step — security, testing, observability, cost (formerly "spine / continuous concern").
11
+ working state: everything an agent loads each session — skill router, active phase, PROJECT/MILESTONE/TASK, state.json (formerly "state surface").
12
+ audit trail: the reference record read by people, never auto-loaded into agent context (formerly "story surface").
13
+ method rationale: the why behind every rule — the AIDD book, loaded on demand, never duplicated (formerly "trust layer").
14
+ failing-first suite: the test suite written before code, confirmed red for the right reason — a missing implementation (formerly "red safety net").
15
+ non-functional review: the deliberate post-evidence check of what tests rarely catch — concurrency, security, architecture (formerly "blind-spot checks").
16
+ change scope: the files a locked run may and may not touch (formerly "touch-boundary"; the <touch_boundary> XML prompt tag keeps its name).
17
+ automated quality gate: the evidence-based Verify resolver under autonomy auto — may auto-PASS on complete evidence; security always escalates (formerly "evidence auto-gate").
18
+ autonomy level: the per-task Verify resolver setting — auto (default) or conservative; declared in the TASK.md header, human-reviewed at the freeze (formerly "autonomy dial").
19
+ living documentation: the durable project artifacts — conventions, glossary, frozen contracts — that outlive any particular code (formerly "survivor layer").
20
+ scope level: the granularity a decision lives at — intake level (request -> versioned scope), milestone level, setup/foundation level, task level (formerly "altitude").
21
+ baseline approval: the one human gate that freezes the AI-drafted foundation, first scope, and first contract together — runs as `add.py lock` (formerly "the lock-down").
22
+ lesson learned: a single learning a loop produces, tagged by the competency it improves — the `- [DDD · open]` grammar and deltas.md/`add.py deltas` machine names stay (formerly "competency delta").
23
+ lowest-confidence flag: the AI's ranked declaration of the 1–2 points most likely to be wrong in what a human is asked to approve — each with why + cost-if-wrong; the ⚠ glyph keeps its name as the machine marker (formerly "least-sure flag").
24
+ decision point: a stop for human judgment — the contract-freeze approval, an escalated verify gate, intake confirmation, milestone close; the machine names seam (--json owner enum, decide key) and seam-audit (CI job) keep their names (formerly "seam").
25
+ retrospective consolidation: gathering confirmed lessons learned at milestone close and writing them append-only into the versioned foundation — human-confirmed, never self-approved; the machine names fold.md, the folded status, and add.py deltas keep their names (formerly "the fold / fold ritual").
26
+ specification bundle: a task's spec, scenarios, contract, and failing tests drafted as one piece and approved by a person once at the contract freeze (formerly "the one-approval front").
@@ -1,6 +1,7 @@
1
1
  # MILESTONE: {{title}}
2
2
 
3
3
  goal: {{goal}}
4
+ rationale: <why this scope — the confirmed intake classification (bucket + reason)>
4
5
  stage: {{stage}} · status: active · created: {{date}}
5
6
 
6
7
  > SDD living doc for this milestone. Keep it THIN: breadth, shared decisions, and
@@ -1,4 +1,4 @@
1
- # PROJECT — survivor layer (cross-milestone context)
1
+ # PROJECT — living documentation (cross-milestone context)
2
2
 
3
3
  > The durable foundation that outlives every milestone and feeds context into each
4
4
  > TDD⇄ADD loop. Read this FIRST in any session. Keep it lean — one screen, not a
@@ -7,6 +7,7 @@
7
7
  > that is the re-entrant arrow from the engine down to the foundation.
8
8
 
9
9
  slug: {{project}} · stage: {{stage}} · updated: {{date}}
10
+ goal: <the one durable outcome this whole project runs toward — set this at setup; status/guide surface it every session>
10
11
 
11
12
  ---
12
13
 
@@ -22,8 +23,8 @@ slug: {{project}} · stage: {{stage}} · updated: {{date}}
22
23
  <!-- The spec is a living document, not a frozen plan. This section POINTS to the
23
24
  active milestone + frozen contracts; it does not duplicate them. -->
24
25
  - Active milestone → `.add/milestones/<slug>/MILESTONE.md` (see `add.py status`)
25
- - Frozen contracts (survivor): the contracts other work builds against.
26
- - Settled vs still open:
26
+ - Frozen contracts (living docs): the contracts other work builds against.
27
+ - Settled vs still open: <frozen contracts · open questions>
27
28
 
28
29
  ## Users (UDD) — UI/UX: design before code
29
30
  <!-- UI/UX-Driven Development: users use the interface, not the spec. Capture the
@@ -3,7 +3,7 @@
3
3
  slug: {{slug}} · created: {{date}} · stage: {{stage}}
4
4
  phase: specify <!-- specify -> scenarios -> contract -> tests -> build -> verify -> observe -> done -->
5
5
  <!-- high-risk/method-defining scope? declare `risk: high` on the slug line above and lower
6
- the dial with `autonomy: conservative` — the engine refuses an unguarded completion
6
+ the autonomy level with `autonomy: conservative` — the engine refuses an unguarded completion
7
7
  (`unguarded_high_risk_auto`, run.md guard). A comment is never a declaration. -->
8
8
 
9
9
  > One file = one task. Fill sections top-to-bottom; the `add` skill drives each phase.
@@ -17,21 +17,31 @@ phase: specify <!-- specify -> scenarios -> contract -> tests -> build -> veri
17
17
  Feature: <name>
18
18
  Framings weighed: <chosen> (chosen) · <alternative> · <alternative>
19
19
  Must:
20
+ <must>
20
21
  - <required behavior>
22
+ </must>
21
23
  Reject:
24
+ <reject>
22
25
  - <bad input / situation> -> "<error_code>"
26
+ </reject>
23
27
  After:
28
+ <after>
24
29
  - <state that is true once it succeeds>
25
- Assumptions — least-sure first:
26
- <the one assumption most likely to be wrong> least sure because <why>; if wrong: <cost>
30
+ </after>
31
+ Assumptionslowest-confidence first:
32
+ <assumptions>
33
+ ⚠ <the one assumption most likely to be wrong> — lowest confidence because <why>; if wrong: <cost>
27
34
  - [ ] <next assumption, ranked> — confirm or deny; never carry an open one forward
35
+ </assumptions>
28
36
 
29
- <!-- EXIT: every rule stated, every rejection named; assumptions ranked least-sure first, the top one or two ⚠-flagged with why + cost (or, for trivial scope, an honest "none material" that still names the single biggest risk). -->
37
+ <!-- EXIT: every rule stated, every rejection named; assumptions ranked lowest-confidence first, the top one or two ⚠-flagged with why + cost (or, for trivial scope, an honest "none material" that still names the single biggest risk). -->
30
38
 
31
39
  ---
32
40
 
33
41
  ## 2 · SCENARIOS — pass/fail cases ▸ docs/04-step-2-scenarios.md
34
42
 
43
+ <scenarios>
44
+
35
45
  ```gherkin
36
46
  Scenario: <short name>
37
47
  Given <starting situation>
@@ -40,6 +50,8 @@ Scenario: <short name>
40
50
  And <what must remain unchanged> # required for every rejection
41
51
  ```
42
52
 
53
+ </scenarios>
54
+
43
55
  <!-- EXIT: one scenario per Must AND per Reject; each result is observable. -->
44
56
 
45
57
  ---
@@ -53,20 +65,24 @@ Scenario: <short name>
53
65
  Schema: <tables/fields touched, and access pattern>
54
66
  ```
55
67
 
56
- Status: DRAFT <!-- becomes: FROZEN @ v1 once approved. Changing a frozen contract = change request back to SPECIFY. -->
57
- <!-- The freeze IS the one approval. Lead it with the bundle's least-sure flag: the 1–2 points
58
- most likely wrong across the whole bundle, tagged [spec|scenario|contract|test], with why + cost.
59
- The §1 ⚠ assumptions are its first feeder; a flag may point at a scenario or the contract too. See run.md. -->
60
-
61
- <!-- EXIT: frozen + every spec rejection has a contracted response + names match GLOSSARY + the bundle's least-sure flag was surfaced at the freeze (or an honest "none material"). -->
68
+ Status: DRAFT
69
+ <!-- The freeze IS the one approval lead it with the bundle's lowest-confidence flag: the 1–2
70
+ points most likely wrong across the whole bundle, tagged [spec|scenario|contract|test], each
71
+ with why + cost (the §1 ⚠ assumptions feed it; a flag may point at a scenario or the contract
72
+ too — see run.md). Approved -> Status: FROZEN @ vN — approved by <name>. Changing a frozen
73
+ contract = change request back to SPECIFY.
74
+ EXIT: frozen + every spec rejection has a contracted response + names match GLOSSARY + the
75
+ bundle's lowest-confidence flag was surfaced at the freeze (or an honest "none material"). -->
62
76
 
63
77
  ---
64
78
 
65
- ## 4 · TESTS — red safety net ▸ docs/06-step-4-tests.md
79
+ ## 4 · TESTS — failing-first suite (red) ▸ docs/06-step-4-tests.md
66
80
 
67
81
  Coverage target: <e.g. 90%>
68
82
  Plan (one test per scenario, asserting behavior not internals):
83
+ <test_plan>
69
84
  - test_<scenario>: arrange <Given> / act <When> / assert <Then> + assert <unchanged>
85
+ </test_plan>
70
86
 
71
87
  Tests live in: `./tests/` · MUST run red (missing implementation) before Build.
72
88
  <!-- declare paths as backticked tokens on this line: `./…` = this task dir ·
@@ -88,7 +104,7 @@ Constraints: do NOT change any test or the contract; allow-list packages only; a
88
104
 
89
105
  ---
90
106
 
91
- ## 6 · VERIFY — evidence + blind-spot checks ▸ docs/08-step-6-verify.md
107
+ ## 6 · VERIFY — evidence + non-functional review ▸ docs/08-step-6-verify.md
92
108
 
93
109
  - [ ] all tests pass
94
110
  - [ ] coverage did not decrease
@@ -98,6 +114,11 @@ Constraints: do NOT change any test or the contract; allow-list packages only; a
98
114
  - [ ] layering & dependencies follow CONVENTIONS.md
99
115
  - [ ] a person reviewed and approved the change
100
116
 
117
+ ### Deep checks — do not skim (fill the path that applies; the resolver judges which)
118
+ - [ ] WIRING (code) — every new symbol is referenced; record where / how confirmed
119
+ - [ ] DEAD-CODE (code) — no new unused or orphaned symbol introduced
120
+ - [ ] SEMANTIC (prose / non-code) — read in full, not skimmed: <what read · what confirmed>
121
+
101
122
  ### GATE RECORD
102
123
  Outcome: <PASS | RISK-ACCEPTED | HARD-STOP>
103
124
  If RISK-ACCEPTED -> owner: <name> · ticket: <link> · expires: <date> (never for a security gap)