@pilotspace/add 1.12.0 → 1.14.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.
@@ -213,7 +213,7 @@ _DELTA_RE = re.compile(
213
213
  )
214
214
  _EVIDENCE_RE = re.compile(r"^(.*?)\s*\(evidence:\s*(.*?)\)\s*$")
215
215
  _SPEC_DELTA_RE = re.compile(
216
- r"\s*-\s*\[\s*(SPEC)\s*·\s*(open|seeded|dropped)\s*\]\s*(.+)$"
216
+ r"\s*-\s*\[\s*(SPEC)\s*·\s*(open|seeded|dropped|carried)\s*\]\s*(.+)$"
217
217
  )
218
218
 
219
219
 
@@ -46,9 +46,9 @@ def _key_decisions_for(root: Path, slug: str) -> list[str]:
46
46
  if st.startswith(("-", "*")) and slug in st]
47
47
 
48
48
  def _build_in_flight(state: dict) -> bool:
49
- """release_tests_red proxy (PURE): is any ACTIVE task mid-build without a recorded green gate
50
- — phase ∈ {build, verify} AND gate == 'none'? The tool-agnostic engine never runs the suite,
51
- so an entered-but-ungated build is the recorded-evidence stand-in for 'the suite is red'."""
49
+ """release_build_in_flight proxy (PURE): is any ACTIVE task mid-build without a recorded green
50
+ gate — phase ∈ {build, verify} AND gate == 'none'? The tool-agnostic engine never runs the
51
+ suite, so an entered-but-ungated build is the recorded-evidence stand-in for 'the suite is red'."""
52
52
  return any(t.get("phase") in ("build", "verify") and t.get("gate") == "none"
53
53
  for t in (state.get("tasks") or {}).values())
54
54
 
@@ -1,7 +1,7 @@
1
1
  # TASK: {{title}}
2
2
 
3
3
  slug: {{slug}} · created: {{date}} · stage: {{stage}}
4
- autonomy: {{autonomy}}
4
+ autonomy: {{autonomy}} <!-- Multi-component repo? add a `component: <name>` line (declared in .add/components.toml) to bind this fast task to a component — its root joins §5 Scope and its green-bar/verify surface at the gate. Omit for single-component projects. -->
5
5
  phase: ground <!-- fast lane: ground -> specify -> contract -> tests -> build -> verify -> observe -> done -->
6
6
  fast: true <!-- the fast lane: a small task, collapsed flow + minimal template. Omit --fast for full rigor. -->
7
7
 
@@ -55,6 +55,8 @@ Tests live in: `./tests/` · MUST run red (missing implementation) before Build.
55
55
  ## 5 · BUILD — AI writes code
56
56
 
57
57
  Scope (may touch): `./src/` <every file the build may write — declared before the §3 freeze>
58
+ Strategy & known-problem fixes: <ordered build steps · the trap each known problem must dodge>
59
+ Strategy actually used: <fill at verify — what you ACTUALLY did, or "as planned"; harvested into §7 Decisions>
58
60
  Code lives in: `./src/` · Constraints: change no test, no contract; allow-list packages only.
59
61
 
60
62
  ---
@@ -108,6 +108,8 @@ Tests live in: `./tests/` · MUST run red (missing implementation) before Build.
108
108
 
109
109
  Scope (may touch): `./src/` <fill before the §3 freeze — every file the build may write>
110
110
  Strategy (ordered batches): <1. … 2. … — the planned build order; guidance, not enforced>
111
+ Known-problem fixes: <trap → planned fix — the failure modes this build must dodge; guidance, not enforced>
112
+ Strategy actually used: <fill at VERIFY — the strategy you ACTUALLY used (or "as planned"); harvested into the §7 Decisions (ADR) block as the [AI] build decision>
111
113
  Safety rule (feature-specific): <e.g. debit+credit in one atomic transaction>
112
114
  Code lives in: `./src/`
113
115
  Constraints: do NOT change any test or the contract; allow-list packages only; ask if unclear.
@@ -117,7 +119,8 @@ Constraints: do NOT change any test or the contract; allow-list packages only; a
117
119
  outside-root resolutions are dropped fail-closed · a DIRECTORY token covers its
118
120
  whole subtree (containment — diverges from §4's non-recursive counting) ·
119
121
  absent line = UNDECLARED (pre-existing tasks grandfathered, never retro-red) ·
120
- engine enforcement (touched ⊆ declared) lands in scope-gate-enforce.
122
+ engine enforcement (touched ⊆ declared) is live: a completing verify gate refuses an
123
+ out-of-scope build (scope_violation → self-heal) and add.py check surfaces it.
121
124
  EXIT: all green; coverage held; no test/contract touched; no unlisted dependency. -->
122
125
 
123
126
  ---
@@ -145,6 +148,14 @@ Constraints: do NOT change any test or the contract; allow-list packages only; a
145
148
  - [ ] DEAD-CODE (code) — no new unused or orphaned symbol introduced
146
149
  - [ ] SEMANTIC (prose / non-code) — read in full, not skimmed: <what read · what confirmed>
147
150
 
151
+ ### Refute-read verdict — the earned-green check (record it; required for an auto-PASS)
152
+ > Under autonomy: auto the AI auto-resolves Verify, so the earned-green refute-read MUST be
153
+ > recorded here (the engine never spawns it — you do; NOT-EARNED -> `add.py heal`). The engine
154
+ > MEASURES it is filled (`audit: refute_unrecorded`); it never auto-blocks — a human spot-audit
155
+ > is the backstop. A human-gated (conservative/manual) task may leave it for the human's judgment.
156
+ Verdict: <EARNED | NOT-EARNED>
157
+ By: <self | agent-id> · adversarially checked: <what was probed>
158
+
148
159
  ### GATE RECORD
149
160
  Outcome: <PASS | RISK-ACCEPTED | HARD-STOP>
150
161
  If RISK-ACCEPTED -> owner: <name> · ticket: <link> · expires: <date> (never for a security gap)
@@ -158,6 +169,9 @@ Reviewed by: <name> · date: <date>
158
169
 
159
170
  Watch (reuse scenarios as monitors): <error rate / per-rejection rate / latency>
160
171
 
172
+ ### Decisions (ADR)
173
+ <harvested at done from §1/§3/§5/§6 — do not hand-edit; one actor-tagged line per decision, refilled only while this placeholder stands>
174
+
161
175
  ### Spec delta
162
176
  Forward changes for the next loop — each re-enters at Specify as the next task. One line
163
177
  each, tagged `[SPEC · open|seeded|dropped]`, with evidence (e.g. `[SPEC · open] rate-limit