@deftai/directive-content 0.115.0 → 0.117.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/UPGRADING.md +17 -6
- package/coding/review.md +8 -0
- package/commands.md +8 -6
- package/contracts/design-critique.md +27 -20
- package/docs/BROWNFIELD.md +10 -0
- package/docs/grok-build-subscription-setup.md +46 -0
- package/docs/plan-acceptance.md +52 -0
- package/package.json +1 -1
- package/packs/rules/rules-pack-0.1.json +112 -112
- package/packs/skills/skills-pack-0.1.json +11 -8
- package/packs/strategies/strategies-pack-0.1.json +1 -1
- package/skills/deft-directive-build/SKILL.md +8 -7
- package/skills/deft-directive-design-critique/SKILL.md +2 -2
- package/skills/deft-directive-pre-pr/SKILL.md +9 -9
- package/skills/deft-directive-release/SKILL.md +32 -5
- package/skills/deft-directive-review-cycle/SKILL.md +35 -0
- package/skills/deft-directive-setup/SKILL.md +45 -11
- package/skills/deft-directive-swarm/references/core-phase-0.md +2 -0
- package/skills/deft-directive-swarm/references/host-cursor.md +2 -0
- package/strategies/interview.md +68 -20
- package/tasks/verify.yml +3 -1
- package/templates/agent-prompt-preamble.md +1 -1
- package/templates/agents-entry.md +2 -0
- package/tools/package-manager-network.md +2 -2
- package/vbrief/schemas/vbrief-core.schema.json +1 -1
package/UPGRADING.md
CHANGED
|
@@ -211,16 +211,27 @@ npm config get registry
|
|
|
211
211
|
```
|
|
212
212
|
|
|
213
213
|
The scoped value wins when `@deftai:registry` is set; otherwise npm uses the
|
|
214
|
-
default `registry`.
|
|
214
|
+
default `registry`. `--registry` does not beat `@deftai:registry` (npm/cli#7659).
|
|
215
|
+
`npm view @deftai/directive` from a consumer cwd whose `.npmrc` maps `@deftai`
|
|
216
|
+
to GitHub Packages therefore cannot hit public npm unless you change cwd,
|
|
217
|
+
`--userconfig`, or the scoped key.
|
|
218
|
+
|
|
219
|
+
If either effective value is not
|
|
215
220
|
`https://registry.npmjs.org/`, choose a recovery path allowed by your
|
|
216
|
-
|
|
221
|
+
corporate policy:
|
|
217
222
|
|
|
218
|
-
- **
|
|
223
|
+
- **Leave the project directory** so the project `.npmrc` is not loaded
|
|
224
|
+
(for example `$HOME`), then install:
|
|
219
225
|
|
|
220
226
|
```bash
|
|
221
|
-
npm i -g @deftai/directive@<version>
|
|
227
|
+
cd "$HOME" && npm i -g @deftai/directive@<version>
|
|
222
228
|
```
|
|
223
229
|
|
|
230
|
+
- **One-shot userconfig from outside the project:** after leaving the project
|
|
231
|
+
directory, write a file containing
|
|
232
|
+
`@deftai:registry=https://registry.npmjs.org/` and pass `--userconfig` to
|
|
233
|
+
that file. `--userconfig` does not beat a project `.npmrc` `@deftai:registry`.
|
|
234
|
+
|
|
224
235
|
- **Durable scoped routing:** add this line to the user or project `.npmrc` so
|
|
225
236
|
only the `@deftai` scope bypasses the default mirror:
|
|
226
237
|
|
|
@@ -237,8 +248,8 @@ IT or the registry administrator to synchronize all Directive packages:
|
|
|
237
248
|
non-public effective registry produces an advisory warning but does not make
|
|
238
249
|
doctor fail; configured registry URLs are not printed because they can contain
|
|
239
250
|
internal hostnames or credentials. With `--network`, the release-availability
|
|
240
|
-
probe
|
|
241
|
-
the
|
|
251
|
+
probe isolates with a temp cwd whose project `.npmrc` sets `@deftai:registry`
|
|
252
|
+
to public npm, because `--registry` does not beat the scoped key.
|
|
242
253
|
|
|
243
254
|
2. **Refresh the project deposit** from your project root:
|
|
244
255
|
|
package/coding/review.md
CHANGED
|
@@ -40,8 +40,16 @@ Legend (from RFC2119): !=MUST, ~=SHOULD, ≉=SHOULD NOT, ⊗=MUST NOT, ?=MAY.
|
|
|
40
40
|
- ! Agents MUST NOT claim merge-ready while any P0 or P1 from the current review remains open
|
|
41
41
|
- ⊗ Elevate P2-only findings into a merge block without operator agreement
|
|
42
42
|
|
|
43
|
+
## Policy-anchored classification (#3452)
|
|
44
|
+
|
|
45
|
+
- ! Invariant-shaped findings (concurrency, error handling, containment/security) MUST NOT be classified out-of-model until a written policy (assumptions / guarantees / non-goals) exists on the **current HEAD** of the file under review. Absent -> write the anchor first. Anchor-wrong -> revise the anchor, then classify
|
|
46
|
+
- ! Classify then act: in-model -> patch; out-of-model -> accepted-risk reply citing the HEAD anchor. Deterministic arity/wiring claims MUST check the head blob before confirmation
|
|
47
|
+
- ! One consolidated push per review round; local review pass before push; never push per finding. Riders allowed on mechanical rebases
|
|
48
|
+
- ! More than 3 review rounds on the same file: escalate to a design pass, not round K+1 and not parking. Compose with the adapter same-fingerprint stop; do not invent a second detector
|
|
49
|
+
|
|
43
50
|
## Anti-Patterns
|
|
44
51
|
|
|
52
|
+
- ⊗ Classify invariant-shaped findings out-of-model with no HEAD policy (#3452)
|
|
45
53
|
- ⊗ Start fixing individual findings as you encounter them — read and plan the full batch first
|
|
46
54
|
- ⊗ Push one commit per finding
|
|
47
55
|
- ⊗ Push while a bot or human review of the current head is still in flight
|
package/commands.md
CHANGED
|
@@ -282,7 +282,8 @@ Current status: the validation, extractor, provider, registry, generated MAP, an
|
|
|
282
282
|
|
|
283
283
|
## Quality And Verification Commands
|
|
284
284
|
|
|
285
|
-
- `
|
|
285
|
+
- `deft check` -- named terminal verb (getting-started / #2893). Include-only consumers then use `task deft:check`. Framework source uses `task check` / `task check:merge`. Do not add a fourth probe (#4379).
|
|
286
|
+
- `task check` -- primary directive repo pre-commit gate (merge chokepoint — #1704). Not deposited at consumer root after `directive init` (#3218).
|
|
286
287
|
- `task check:merge` -- explicit merge-chokepoint alias for `check:framework-source` in the framework source repo (#1704).
|
|
287
288
|
- `task check:framework-source` -- framework-source lane.
|
|
288
289
|
- `task check:consumer` -- consumer-shape lane.
|
|
@@ -292,7 +293,7 @@ Current status: the validation, extractor, provider, registry, generated MAP, an
|
|
|
292
293
|
> **Invariant:** every change MUST pass the full gate at least once before merge.
|
|
293
294
|
|
|
294
295
|
- ! **Iteration lane (agents + humans):** during implementation, use affected/static gates — targeted tests on changed paths, relevant static `verify:*` gates, `task coverage:hotspots` / `task verify:forward-coverage` — not full `task check` on every commit.
|
|
295
|
-
- ! **Merge chokepoint:**
|
|
296
|
+
- ! **Merge chokepoint:** prefer `deft check` before push/PR. If the CLI is missing, use the tree-correct task form (`task deft:check` on include-only consumers; `task check` / `task check:merge` in framework source). These are one gate, not two sequential runs. Do not add a fourth probe (#2893 / #4379). CI in this repo still runs the monolith merge-gate job (`.github/workflows/ci.yml` runs `check:merge`, not cached `deft check`, until `#1713` can invoke internal Taskfile shims).
|
|
296
297
|
- ! **Escape-rate safety:** consume `#1703` Tier-1 telemetry (`helped/crud-metrics.jsonl`) and `task eval:health` (Tier 0) before tightening fast-lane defaults — do not invent a separate metric surface.
|
|
297
298
|
- ~ **In-engine incrementality (#1713):** content-hash cache + runner-delegated affected selection are delivered separately.
|
|
298
299
|
- ~ **Merge queue:** deferred — GitHub merge queue adoption waits until the CI monolith + escape-rate signal are stable; batch merge throughput is the next lever after `#1713` cache lands (#1704 ROI order).
|
|
@@ -310,7 +311,7 @@ Current status: the validation, extractor, provider, registry, generated MAP, an
|
|
|
310
311
|
- `task verify:lifecycle-visible` -- warn when a clone's ignore configuration hides `xbrief/` / `vbrief/` lifecycle roots (#3505). Uses `git check-ignore -v` on the stage dirs, a matching-extension sentinel under each, and bounded probes derived from ignore-rule globs in root, exclude, `core.excludesFile`, and nested lifecycle `.gitignore` files (so `2026-06-*.xbrief.json` / `2025-*.xbrief.json` cannot report clean), plus `git ls-files -v` for skip-worktree / assume-unchanged. Names the matching rule and source file. Warn-first from `session:start` (per-clone, not on `task check`). Selective `.triage-cache/*.jsonl` entries do not trip. Pass `--enforce` to fail closed.
|
|
311
312
|
- `task verify:completed-write-guard` -- fail closed when a newly added `xbrief/completed/` (or `vbrief/completed/`) artifact was not written by `scope:complete` / `scope:fail` (#3679), or when a change set deletes or renames away an `xbrief/active/` brief with no paired stamped destination (#3766). Same name-status parser covers A, R, and D. Terminal moves pass as `R active->completed` or `D active` plus `A completed` when the destination has a runTransition stamp. A `cancelled/` destination pairs only when it carries a `lifecycleWrite` cancel stamp. Delete-plus-add pairing also requires the dest `plan.title` to match the deleted source so a copied stamp cannot authorize an unrelated brief. Lone-D untracking cleanup halts and names `scope:complete` or leaving the brief untracked. Artifacts larger than 1 MiB fail closed before read. Historical corpus is advisory via doctor. Remediation names the leftover land PR after a scope-provenance strip (#3476). `scope:complete` can stamp a brief already in `completed/`. Does not change `verify:completed-tracked`.
|
|
312
313
|
- `task verify:completed-tracked` -- fail closed when closed scoped issues lack a tracked `xbrief/completed/` or `xbrief/cancelled/` artifact on the delivery tip (#3264 / #3476); remediate with `task swarm:finalize-cohort` or a lifecycle PR. `task verify:completed-tracked -- --issue N` is the drive-to DONE form (delivery tip `origin/<deliveryBranch>`, not feature HEAD). Standalone verb (not part of `task check`); use `--tip HEAD` when validating an in-flight land branch. An unresolvable delivery tip fails closed (no silent HEAD fallback) -- fetch the delivery branch or pass an explicit `--tip`. Under `--skip-gh`, a named `--issue` with no cached state fails closed; the unscoped corpus scan keeps the offline allowance. Lifecycle-only lands (completed/cancelled xBRIEFs + optional CHANGELOG) use that verb plus finalize-cohort or the lifecycle PR. ⊗ Full `task check` / the TypeScript suite. ⊗ The drive-to story envelope (pre-pr + review-cycle + suite) for a file-copy land.
|
|
313
|
-
- `task verify:ac` -- product-first acceptance gate (#3284). Runs `plan.acceptance.commands` (or #3267 literal ledger) **verbatim** before done; records AC-source rung (`stated`/`derived`/`project_floor`). Empty commands require `none_stated: true`. Empty resolution is not a green run when the project has no suite floor (`soft_empty` + stamp-acceptance remedy, #3334). Primary name used first in `task check` (fail-fast); `--soft-missing-xbrief` for check composition. Rapid ceremony = AC-only; pressure/degraded makes hygiene advisory. `--capture-only` lists resolved commands without executing. Extends #3267 / #973.
|
|
314
|
+
- `task verify:ac` -- product-first acceptance gate (#3284). Runs `plan.acceptance.commands` (or #3267 literal ledger) **verbatim** before done; records AC-source rung (`stated`/`derived`/`project_floor`). Empty commands require `none_stated: true`. Empty resolution is not a green run when the project has no suite floor (`soft_empty` + stamp-acceptance remedy, #3334). Primary name used first in `task check` (fail-fast); `--soft-missing-xbrief` for check composition. Rapid ceremony = AC-only; pressure/degraded makes hygiene advisory. `--capture-only` lists resolved commands without executing. Extends #3267 / #973. Fields the gate requires (including `ambiguity_attestation` and operator-collected `file_scope`): [`docs/plan-acceptance.md`](docs/plan-acceptance.md) (#4380). A no-oracle walk still passes (#3826); the pass lead keeps the counts (`passed (0 verified, N unverifiable)`).
|
|
314
315
|
- `task verify:literal-ac` -- #3267 mechanism alias for verbatim stated-command run (same flags/cwd); prefer `verify:ac` for product-first done-gate.
|
|
315
316
|
- `task verify:forward-coverage` / `deft verify:forward-coverage` -- fail-closed new-source-file existence (#1310) plus warn-first diff coverage of added/modified branches (#3514). Intersects `coverage/coverage-final.json` with the diff against a 90% per-change branch threshold. That 90% is coverage of new code; the project vitest floor (75) is a collapse detector for the aggregate -- they are not interchangeable. Missing coverage reports skip the diff half (existence still runs). Pass `--enforce` to fail closed on uncovered changed branches; `--staged` for pre-commit.
|
|
316
317
|
- `task coverage:hotspots` / `deft coverage:hotspots` -- read the latest coverage report, compare global metrics to the project's vitest thresholds, fail closed below the branch floor or below configured headroom (default 0.3pp), and list lowest modules plus uncovered branch samples for git-diff paths (`--json` for agents). Complements `deft verify:forward-coverage` (#1310 / #3514) and `--allow-coverage-debt=#N` (#2573); does not replace them.
|
|
@@ -459,7 +460,7 @@ Cross-link: spawn three postures and deny recoveries live under § Agent-host di
|
|
|
459
460
|
|
|
460
461
|
### Mutable ritual (mutation posture)
|
|
461
462
|
|
|
462
|
-
- ! On **mutation** session start, run `deft session:start` (or `task session:start` in framework source) after loading AGENTS.md. Records quick-tier ritual in `.deft/ritual-state.json`: alignment confirmation, branch-policy disclosure, `deft verify:tools` guidance, default-branch sync warnings, and `deft triage:welcome` one-liner. State is worktree- and HEAD-bound; stale after `plan.policy.sessionRitualStalenessHours` hours (default
|
|
463
|
+
- ! On **mutation** session start, run `deft session:start` (or `task session:start` in framework source) after loading AGENTS.md. Records quick-tier ritual in `.deft/ritual-state.json`: alignment confirmation, branch-policy disclosure, `deft verify:tools` guidance, default-branch sync warnings, and `deft triage:welcome` one-liner. State is worktree- and HEAD-bound; stale after `plan.policy.sessionRitualStalenessHours` hours (default 8). Mutation start also claims the worktree occupancy lease (`.deft/occupancy.json`); see Session routing (#3433).
|
|
463
464
|
- ! **Orientation compression Now (#3286):** mutation cold `session:start` composes `doctor` + #3282 toolchain preflight (and deposit-sha fast-paths for `agents:refresh` / `verify:cache-fresh`) as inline sections with per-section status lines — composition of existing steps, not a new monolith. When the deposit fingerprint (payload + templates + engine) is unchanged, refresh surfaces print one-line `unchanged - sha match` no-ops. Opt-in compact output: `deft session:start --compact` or `DEFT_SESSION_COMPACT=1` (verbose remains the default). #2176 read-only default is unchanged. Dual-path Later (orient) stays open until run-summary telemetry shows ritual+gate share ≥ 25% after Now ships (#2899).
|
|
464
465
|
- ! Cold `session:start` does **not** run the live agent-hook probe. Functional readiness belongs to the gated mutation path so cold ceremony retains the #2990/#2991 latency profile.
|
|
465
466
|
- ! **Hot path latency (#2991):** by default, mutation `session:start` does **not** block ritual-state write on optional network. It skips the npm release-availability probe and triage cache empty-hydrate / self-heal (`ensureTriageCacheHydrated` / `maybeSelfHealCache`). Targets (operator-facing, not CI-hard): warm hot path typically under a few seconds once tools are on PATH; cold path dominated by local `verify:tools` and git, usually well under ~30s when optional network is off. Empty-cache GitHub fetch-all and npm `view` previously accounted for multi-minute hangs in the WWYSYDH pilot — those stay off the critical path unless opted in.
|
|
@@ -469,7 +470,7 @@ Cross-link: spawn three postures and deny recoveries live under § Agent-host di
|
|
|
469
470
|
- ~ **Process-cost events (#2994 / #3508):** on mutation `session:start` completion (cold or re-arm), Directive appends a local `session:start` behavioral event to `.deft-cache/events.jsonl` with `ceremony_tier`, `duration_ms`, `exit_code`, and optional `steps[]` (same labels as `--json`). Mutation `session:start` also prints one operator-visible `ceremony <tier> <ms>` line (hidden under `--compact` / `DEFT_SESSION_COMPACT`). When PreToolUse denies for `ritual-not-ready`, a local `session:ritual-blocked` event records `tool_name`, `code`, and optional `recovery_tier` / `detail`. Always-on best-effort (never blocks ceremony or deny path); not gated on `valueFeedback`; **no remote upload** (Product Insights #2603 is a separate opt-in). Pull the rollup with `task value:show` (composed reader; CLI process time, not agent-turn wall clock). See § Process-cost events below. ⊗ Do not use the printed CLI duration as #3286 Later graduation input.
|
|
470
471
|
- ~ At safe idle points (clean tree, no in-flight story), mutation session start and `deft scope:complete` may also run the staleness tickler: an interactive, consent-based offer to upgrade Directive (`npm i -g @deftai/directive@latest`) and/or migrate xBRIEF (`deft migrate:xbrief`). Escalation tiers, snooze windows, and opt-out live under `plan.policy.stalenessTickler` — inspect with `deft policy:show --field=stalenessTickler`. State persists in `xbrief/.triage-cache/staleness-tickler-state.json`. Skips framework source checkouts, dirty trees, CI/headless (`DEFT_SESSION_RITUAL_SKIP=1`), and typed opt-out. Refs #2488 / #2489.
|
|
471
472
|
- ! Before any code-writing tool call or `start_agent` implementation dispatch, run `deft verify:session-ritual -- --tier=gated`. Gated tier fails closed unless quick-tier state is fresh; lazily records the non-deferrable `agent_hooks` readiness gate plus `deft doctor` and `task verify:cache-fresh` entrypoints. Agent-hook correctness is independent of doctor warnings and throttling. Step 0 of the pre-`start_agent` gate stack.
|
|
472
|
-
- ! **One-shot recovery (#2993 / #3100):** when PreToolUse denies writes for a stale/missing gated ritual, run `deft session:ready` (or `task session:ready`). It composes `session:start` (only when quick-tier is not green) + `verify:session-ritual -- --tier=gated` + `cache fetch-all --force` when `cache_fresh` is the remaining blocker, then re-verifies. Even when gated inspect is already fresh, the fast path forces one live `agent_hooks` check
|
|
473
|
+
- ! **One-shot recovery (#2993 / #3100 / #4399):** when PreToolUse denies writes for a stale/missing gated ritual, run `deft session:ready` (or `task session:ready`). It composes `session:start` (only when quick-tier is not green) + `verify:session-ritual -- --tier=gated` with check-class `cache_fresh` (age + live drift, no `--skip-drift-probe`) + `cache fetch-all --force` when `cache_fresh` is the remaining blocker, then re-verifies. Skip-drift ritual argv is not the ready bar — that is the `task check` / FRAMEWORK_CHECK_GATES evaluate, so stale-by-drift can still fire fetch-all. Even when gated inspect is already fresh, the fast path forces one live `agent_hooks` check and the same check-class `cache_fresh`; it still avoids unnecessary fetch-all when that evaluate is green. Flags: `--json`, `--repo OWNER/NAME`, `--with-network` (forwarded to session:start). Prefer this over juggling the multi-step recovery sequence under hook pressure.
|
|
473
474
|
- ? Postpone with `deft session:start --defer step=reason` (`alignment`, `branch_policy`, `triage_welcome`, `doctor`, `cache_fresh`). `agent_hooks` is non-deferrable.
|
|
474
475
|
- Headless workers / CI MAY set `DEFT_SESSION_RITUAL_SKIP=1`; verifier exits 0 but warns when bypass hides failure.
|
|
475
476
|
- ⊗ Self-report ritual complete without fresh `deft session:start` state; ⊗ bypass `deft verify:session-ritual` before implementation dispatch; ⊗ reorder/skip/merge ritual tiers without operator override.
|
|
@@ -600,7 +601,7 @@ Directive does not guess your mix. Either you name the next units in order (**or
|
|
|
600
601
|
- `task triage:summary`, `task triage:scope`, `task triage:scope-drift`, `task triage:subscribe`, `task triage:unsubscribe`, `task triage:classify`, `task triage:strip-withdrawn-chips`, `task triage:welcome`, and `task triage:smoketest` -- supporting workflow and onboarding commands.
|
|
601
602
|
- `task triage:classify -- --mirror` -- **Withdrawn (#4070).** Dry-run and `--apply` both fail closed with a pointer at #4070. Replacement sieve is #4071. #3579 is transitively withdrawn for the gap. Do not close #1423, #3579, #2611, or #3923. `--list` / `--validate` remain. Strip leftover chips with `task triage:strip-withdrawn-chips` (remaining-set apply, not classify).
|
|
602
603
|
- **Triage write-back pairing (#1423 / ADR-005).** When the author stamps that a lean is mechanism-shaped, write **both**: body-text field `mechanism-shaped: true` (the artifact) **and** mirrored label `design-critique:mechanism-shaped` (what `plan.policy.judgmentGates` matches and lists show). Do not compute the classification. No stamp -> the design-critique gate never fires. Clearance is a separate line on the thread: `design-critique: warranted | not warranted, because ...` -- engine evaluates presence, shape, and authority, never the because-clause content. Advisory/observe; `verify:judgment-gates --enforce` stays opt-in unused; `scope:promote` does not gain `--enforce` in this story.
|
|
603
|
-
- **Design-critique catalog chip (#3642 / #4298).** Parent attach of `ingest-ready` / `in-progress` /
|
|
604
|
+
- **Design-critique catalog chip (#3642 / #4298).** Parent attach of `ingest-ready` / `in-progress` / later-arc `mechanism-shaped` MUST use `task scm:issue:design-critique-chip -- --issue N --chip mechanism-shaped|in-progress|ingest-ready [--repo OWNER/NAME]` (or `deft scm issue design-critique-chip`). Closed catalog remaining-set replace, one write. Auto-stamp chip from `resolveAutoStampCatalogChip` is ingest-ready after the completed-arc record. ⊗ `gh api POST .../labels`. ⊗ additive `scm:issue:edit --add-label`.
|
|
604
605
|
- **Work claim (#4200).** Same-issue busy flag `status:claimed`. `task scm:issue:work-claim -- claim|show|release --issue N [--repo OWNER/NAME]` (`deft scm issue work-claim`). Session-start and `xbrief:preflight` MUST show. Warn is success; not a lock. Claim refuses read-only / no occupancy. Last-write-wins: the board can lie about who. v1 does not detect two-issue path overlap. Catalog in `.github/ISSUE_LABELS.md`; ⊗ invent the name per issue.
|
|
605
606
|
- **Operator discovery for SCM label mirror (#3124).** Withdrawn with classify `--mirror` (#4070). The session/welcome tip does not fire. #3124 discovery and #1423 Wave 1–2 apply are unusable after this lands; those issues stay open.
|
|
606
607
|
|
|
@@ -652,6 +653,7 @@ flowchart TD
|
|
|
652
653
|
- Step 3 (`Pre-flight vBRIEF lifecycle sync`) fetches GitHub issue states via REST. On HTTP 403 rate-limit exhaustion it sleeps once (capped at 120s) and retries before failing.
|
|
653
654
|
- When Step 3 still fails with rate-limit exhaustion, stderr includes a `gh api rate_limit` probe (`core.remaining`, reset time) and recovery guidance. After local `task xbrief:validate` exits 0, operators may pass `--allow-vbrief-drift` to skip Step 3 for that cut — reserved for transient SCM bucket stalls, not unreviewed lifecycle drift.
|
|
654
655
|
- `task swarm:*` -- readiness, launch, pre-dispatch deny gate (#3228), review-clean verification, and cohort completion.
|
|
656
|
+
- **Policy-anchored review-response (#3452):** classify invariant-shaped findings against a written HEAD policy before patching; one consolidated push per review round; more than 3 rounds on one file escalate to a #3434 design pass. Compose with the #3448 Same-fingerprint stop -- do not invent a second detector. Working name `review-response`. Depth: `skills/deft-directive-review-cycle/SKILL.md` and `coding/review.md`.
|
|
655
657
|
- **Operator follow-up after dual-stop / hard stop (#3273 / #3448):** one-shot *pursue residual* / *follow-up hard-stop* / *same as conf-hold* / *continue dual-stopped PR* is one pass then re-stop. Standing *until floor or loop* / *until greptile meets policy* / *pursue residuals until told otherwise* keeps class A leftovers on open cohort/plan units moving until the resolved `#3095` floor or the **Same-fingerprint stop** in `skills/deft-directive-review-cycle/SKILL.md` Dual stop (not a separate task verb). Steps in `skills/deft-directive-swarm` and `skills/deft-directive-review-cycle` § Operator follow-up after dual-stop / hard stop.
|
|
656
658
|
|
|
657
659
|
- `task slice:*` -- feature-slice helpers.
|
|
@@ -25,7 +25,7 @@ Boundaries are read off the machinery in this document, not asserted here.
|
|
|
25
25
|
- Rounds accumulate inside one arc. The auto-stamp denominator is scoped to critic posts in this arc and keeps a Stop 4 retry's post, so a retry continues the arc it retries.
|
|
26
26
|
- Same-round siblings share one ceiling and one panel-deposit. A panel is one round, not N arcs.
|
|
27
27
|
- The arc stays open through the operator-gated loop until a verified synthesis is accepted, or until the halt line. Successor leans are moves inside that loop, so revising a lean before bind is not a boundary.
|
|
28
|
-
- A **
|
|
28
|
+
- A **later arc** opens after bind: it re-applies `design-critique:mechanism-shaped`, drops `design-critique:ingest-ready`, and its new lean is not cleared by the older completed-arc record. That is a post-bind target revision.
|
|
29
29
|
|
|
30
30
|
- ! Read `arc` in this document as that unit.
|
|
31
31
|
- ⊗ Read a new ceiling, a new round, or a pre-bind lean revision as a new arc.
|
|
@@ -60,10 +60,10 @@ Record `arc-mode: no-ingest` or `arc-mode: checkout` on the Stop 1 write-back. `
|
|
|
60
60
|
- ! Recognition of `no-ingest` happens before mutation initialization. Refuse github-only when mutation `session:start` has already occurred, unless the lease is released first.
|
|
61
61
|
- ! Posting path that survives a foreign lease: `gh issue comment --body-file -` (stdin). Least-authority envelope: bounded GitHub reads and one comment post.
|
|
62
62
|
- ! Parent fetches, then creates or verifies one dest at origin/<default> tip (`ensureArcDest`). dispatch-sha equals that tip. Against-implementation dest is the fetched PR head SHA, recorded on Stop 1. ⊗ Pin dest to local HEAD.
|
|
63
|
-
- ! N>1 process-only critics share that dest with cwd-without-occupy. They are not swarm Phase 2 and not a #4066 mutating worker. Unique dest-lock stays for implement-class. Skip class is a host-visible Grok stdin marker (`subagent_type` `plan` or `process_only`), not dest-path. That marker is the
|
|
63
|
+
- ! N>1 process-only critics share that dest with cwd-without-occupy. They are not swarm Phase 2 and not a #4066 mutating worker. Unique dest-lock stays for implement-class. Skip class is a host-visible Grok stdin marker (`subagent_type` `plan` or `process_only`), not dest-path. That marker is the process-only skip class, not an implementation-gate bypass: implement-class never sets `process_only`. ⊗ Skip #2885 on destProven. Keep #4066 primary-path deny. ⊗ Pin dest / process_only skip-class rules into `templates/agents-entry.md`.
|
|
64
64
|
- ! Pin reads to `git show <dispatch-sha>:` against the recorded SHA. ⊗ A moving branch ref.
|
|
65
65
|
- ! Direct EXIT names ingest as a later operator verb after the completed-arc record. ⊗ Auto-ingest.
|
|
66
|
-
- ! After
|
|
66
|
+
- ! After an admitted completed-arc record, print ingest (`task issue:ingest`) and do not print next-envelope as the default next. Mid-arc EXIT stays next-envelope. ⊗ Add a land CLI. ⊗ Treat a body PATCH as a later arc. Keep chip `design-critique:ingest-ready` as list state.
|
|
67
67
|
- ! Target-digest / stale-target (#4243) is a different hole. ⊗ Restamp for body alignment.
|
|
68
68
|
- ⊗ Treat `arc-mode:` as ingest clearance or as a permanent ingest denial.
|
|
69
69
|
- ⊗ Record a front-door mode named `ingest`.
|
|
@@ -193,7 +193,7 @@ seat: codex launcher: codex
|
|
|
193
193
|
|
|
194
194
|
- ! For spend N≥3, the panel-deposit or a sibling-seat record names three claimed families before the first sibling spawn. Parent claims the family at dispatch. ⊗ Classify family from a model slug.
|
|
195
195
|
- ! A same-family sibling set is not a panel. ⊗ Lean it. Printed recovery is re-seat (or halt), not wait for Stop 5.
|
|
196
|
-
- ! Grok Build launcher tree: Grok seat via `spawn_subagent` (or `grok`); Claude seat via `claude` CLI; Codex seat via `codex exec`. Every arc uses one dest at origin/<default> after fetch; github-only is no-ingest, not no-worktree. Probe `claude` / `codex` on PATH before offering paste-ready. Paste-ready is the fallback when a named family's CLI is absent. Close stdin on CLI spawns (Windows `cmd /c "… <nul"`; Unix `… </dev/null`). Pointer: [`docs/grok-build-subscription-setup.md`](../docs/grok-build-subscription-setup.md).
|
|
196
|
+
- ! Grok Build launcher tree: Grok seat via `spawn_subagent` (or `grok`); Claude seat via `claude` CLI; Codex seat via `codex exec`. Every arc uses one dest at origin/<default> after fetch; github-only is no-ingest, not no-worktree. Probe `claude` / `codex` on PATH before offering paste-ready. Paste-ready is the fallback when a named family's CLI is absent. Close stdin on CLI spawns (Windows `cmd /c "… <nul"`; Unix `… </dev/null`). Pointer: [`docs/grok-build-subscription-setup.md`](../docs/grok-build-subscription-setup.md). Critic spawn argv lives under that playbook's Design-critique dispatch heading, not this contract.
|
|
197
197
|
- ! `evaluatePanelSeatComposition` (`packages/core/src/design-critique/panel-seat-families.ts`) refuses a same-family N≥3 set and refuses paste-ready-first when `claude` / `codex` resolve. It takes claimed families and PATH probe results. It does not observe live comments and does not count siblings.
|
|
198
198
|
- ! After a dispatch-composition miss, offer a prevention issue. On yolo, file it. ⊗ Only re-seat.
|
|
199
199
|
|
|
@@ -278,11 +278,16 @@ After this round's same-round siblings are posted, parent posts a successor `**L
|
|
|
278
278
|
- ! The successor lean is the disposition map. Do not post a third map type.
|
|
279
279
|
- ! The first posted map is an ADR-006 arbitration surface. Record a substantiation token when takes introduce load-bearing premises. Non-self-arbitration applies when the same party authored the triage and the proposed takes.
|
|
280
280
|
- ! Bind synthesis and the auto-stamp catalog chip (`design-critique:ingest-ready`) to the latest successor lean, never a superseded write-back.
|
|
281
|
-
- ! When the next-build contract is
|
|
282
|
-
- !
|
|
283
|
-
- !
|
|
281
|
+
- ! When the next-build contract is not this body, stamp a Lean-family line-start `Spec-path:` on that successor lean. Nine spellings: zero to two asterisks counted independently on each side, the same wrapping as `Lean:`. `Spec-path:` is a lean token, not a chip. `resolveAutoStampCatalogChip` remaining-set-replaces `ingest-ready` after the completed-arc record exists. It does not parse lean English and does not map Spec-path to a chip.
|
|
282
|
+
- ! Spec-path token plus a completed-arc record means harvest that closed Bound-remedy heading slice on the cited successor lean. Missing heading or empty list refuses, nothing written. No token stays the #4237 Outcome:ready body-is-normative path. ⊗ Let Spec-path mean both a later arc and a harvest path.
|
|
283
|
+
- ! Bound-remedy harvest is a Lean-family heading token (`## Bound remedy`, same class as `## In plain English`) plus parseListItems on that slice of the cited successor lean only. ⊗ Bind that harvest as reuse extractPlanItems. Empty on that lean refuses. A numbered list without that heading is not enough.
|
|
284
284
|
- ! Point that harvest source at plan.items, literal capture, and derived-clause taskStatement. Overview may keep the GitHub body as historical described content. ⊗ Close with an items-only patch.
|
|
285
|
-
- ⊗ Classify
|
|
285
|
+
- ⊗ Classify the path selector by NLP of the lean.
|
|
286
|
+
|
|
287
|
+
### Legacy alias
|
|
288
|
+
|
|
289
|
+
`Recut:` is a permanent alias for `Spec-path:`, same Lean-family wrapping (zero to two asterisks each side). Ingest on an old-spelling lean is identical: non-empty Bound-remedy list harvests; missing heading or empty list refuses, nothing written; no token stays body-normative. Teach only `Spec-path:` on new leans.
|
|
290
|
+
|
|
286
291
|
- ! Full template (accepted set, residual, supersedes-id, ceiling if retrying) lives only on the successor lean and on a retry disagreement map.
|
|
287
292
|
- ! Walk comments stay slim (model and role lines, Accept X, critic id, heading, decision, and when needed a token plus pointer).
|
|
288
293
|
- ⊗ Edit the ceiling write-back in place.
|
|
@@ -333,6 +338,8 @@ The summary leads both artifacts under one fixed heading token: `## In plain Eng
|
|
|
333
338
|
- ⊗ Address an implementer in the summary. No imperatives, and no instruction to a later worker.
|
|
334
339
|
- ⊗ Mandate a next-step or recommended-action field on either artifact. A closed form (a verb and an issue) was considered and refused: the summary cannot itself be closed-form, because plain language is the point, and a bounded instruction is still an instruction in the parent voice inside the ingest-clearing comment.
|
|
335
340
|
- ⊗ Put ingest-open protocol or the sentence "Ingest may proceed" under this heading. Those crowd out the problem-and-solution reading. Ingest still reads the bound lean and the verified-claims table.
|
|
341
|
+
- ! Summary may say leftover next-build, or no leftover next-build, as a reading.
|
|
342
|
+
- ⊗ Order close. "Should close" is an instruction to a later worker.
|
|
336
343
|
|
|
337
344
|
### Reserved line-starts
|
|
338
345
|
|
|
@@ -398,8 +405,8 @@ Contract stops stay internal. Parent prints these phrases when they apply. They
|
|
|
398
405
|
- ! Do not print **retry differences** until residual headings are named on that map.
|
|
399
406
|
- ! Do not skip the first-lean offer because the draft is all-accept.
|
|
400
407
|
- ! Non-empty disagree set: print **walk** / **walk all** / **retry differences** / **accept**. Walk is an option, not the only path. Do not auto-start the walk.
|
|
401
|
-
- ! When the successor lean's per-heading map is total over a **non-empty** in-envelope classified-finding set, every heading is `accept-into-contract` (no `disagree`, no `defer`), AND zero unresolved audit markers, AND the operator has confirmed or amended that map, AND no unposted same-round siblings remain: parent auto-posts the verified-claims table as its own comment, then auto-posts `design-critique: synthesis accepted, because agents agreed (empty disagreement set)` and remaining-set-replaces the chip via `task scm:issue:design-critique-chip -- --issue N --chip ingest-ready` (`resolveAutoStampCatalogChip` after the completed-arc record;
|
|
402
|
-
- ! Yolo standing on the launching utterance is that confirm for a posted all-accept successor map, including
|
|
408
|
+
- ! When the successor lean's per-heading map is total over a **non-empty** in-envelope classified-finding set, every heading is `accept-into-contract` (no `disagree`, no `defer`), AND zero unresolved audit markers, AND the operator has confirmed or amended that map, AND no unposted same-round siblings remain: parent auto-posts the verified-claims table as its own comment, then auto-posts `design-critique: synthesis accepted, because agents agreed (empty disagreement set)` and remaining-set-replaces the chip via `task scm:issue:design-critique-chip -- --issue N --chip ingest-ready` (`resolveAutoStampCatalogChip` after the completed-arc record; Spec-path: is not a chip). If that write misses, continue; do not halt. Do not print **accept synthesis**, **post the verified-claims table**, **walk**, or **walk all**.
|
|
409
|
+
- ! Yolo standing on the launching utterance is that confirm for a posted all-accept successor map, including Spec-path leans. It replaces only the confirm conjunct. Same-turn stamp uses `autoStamp: true` (no Accept widget). Parse yolo as a closed token with word boundaries on the operator chat utterance only. Same discipline as `parseOperatorRunPosture`; do not overload that function to return a mode. Issue, comment, and critic English are data.
|
|
403
410
|
- ⊗ Treat yolo as confirm of a non-empty `disagree` or `defer` set. Defer is not disagree. Print **walk** / **retry differences** / **accept** as today. Walk still prints only when a take is `disagree`.
|
|
404
411
|
- ⊗ Waive non-empty classified set, stub, footnote-only, dispatch-fail, unresolved markers, or unposted-sibling refusals because yolo is standing.
|
|
405
412
|
- ⊗ Treat yolo-confirm as ingest, next-envelope, or chip hygiene beyond the existing auto-stamp remaining-set write.
|
|
@@ -494,7 +501,7 @@ Two bind paths authorize:
|
|
|
494
501
|
design-critique: synthesis accepted, because …
|
|
495
502
|
```
|
|
496
503
|
|
|
497
|
-
1. #3640 auto-stamp: when the successor lean map is total over the auto-stamp denominator (critic posts in this arc, including Stop 4 retry output, plus still-open residual headings) and that set is non-empty and every heading is `accept-into-contract` AND zero unresolved audit markers AND the operator has confirmed or amended that map AND no unposted same-round siblings remain, parent posts `design-critique: synthesis accepted, because agents agreed (empty disagreement set)` and remaining-set-replaces the chip via `task scm:issue:design-critique-chip -- --issue N --chip ingest-ready` (`resolveAutoStampCatalogChip` after the completed-arc record;
|
|
504
|
+
1. #3640 auto-stamp: when the successor lean map is total over the auto-stamp denominator (critic posts in this arc, including Stop 4 retry output, plus still-open residual headings) and that set is non-empty and every heading is `accept-into-contract` AND zero unresolved audit markers AND the operator has confirmed or amended that map AND no unposted same-round siblings remain, parent posts `design-critique: synthesis accepted, because agents agreed (empty disagreement set)` and remaining-set-replaces the chip via `task scm:issue:design-critique-chip -- --issue N --chip ingest-ready` (`resolveAutoStampCatalogChip` after the completed-arc record; Spec-path: is not a chip). If that write misses, continue; do not halt. Do not print **accept synthesis**. Do not auto-stamp on a partial map, an unconfirmed parent draft, or when any audit marker is unresolved, or while same-round siblings remain unposted. Yolo standing on the launching utterance is the confirm conjunct for that posted all-accept map, including Spec-path leans. It does not satisfy ingest.
|
|
498
505
|
2. Explicit operator **accept synthesis** (or a listed short form), subject to the two non-empty refusals below. Parent may post that line and cite the verb. Then apply the exclusive catalog chip `resolveAutoStampCatalogChip` selects (`design-critique:ingest-ready`) via remaining-set write. If that write misses, continue; do not halt.
|
|
499
506
|
|
|
500
507
|
Closed catalog (last chip wins): `design-critique:mechanism-shaped` (in-flight, gate match), `design-critique:in-progress` (live after first panel-deposit or `role: critic`; not gate-matched), and `design-critique:ingest-ready` (the only bind chip after a complete record). No halt chip. Halt leaves the standing in-flight chip. No clear-to-none. `CHIP_ALIASES` in `packages/core/src/scm/design-critique-chip.ts` is the same three names. Old `design-critique:triage-ready` and `design-critique:recut-needed` fail closed. Unknown `--chip` fails closed.
|
|
@@ -505,14 +512,14 @@ Closed catalog (last chip wins): `design-critique:mechanism-shaped` (in-flight,
|
|
|
505
512
|
- ⊗ `gh api POST .../labels` or additive `scm:issue:edit --add-label` for this facet.
|
|
506
513
|
- ⊗ Intercept mixed `scm issue edit` adds/removes for this facet.
|
|
507
514
|
- ⊗ General-purpose labels CLI.
|
|
508
|
-
- ! After the completed-arc record is present, `triage:accept` / `scope:promote` / `issue:ingest` / build may proceed unless `evaluateCompletedArcRecord` returns `cancelled` or `
|
|
509
|
-
- ! Per-thread body ingest stays the mapper after a set-level bind. Stories the bind wants are
|
|
510
|
-
- !
|
|
511
|
-
- ! A later successor lean after cancel starts a
|
|
512
|
-
- ! A complete record whose latest `target shape:` field is `set-level` is `
|
|
515
|
+
- ! After the completed-arc record is present, `triage:accept` / `scope:promote` / `issue:ingest` / build may proceed unless `evaluateCompletedArcRecord` returns `cancelled` or `set-level-body` (#4057). Any identity may run those verbs. Same-session parent continuation is not required. ⊗ Treat `arc-mode:` as ingest clearance or as a permanent ingest denial. Ingest stays `issue:ingest` after the completed-arc record. Direct EXIT names it as a later operator verb. After an admitted completed-arc record, print ingest and do not print next-envelope as the default next. Mid-arc EXIT stays next-envelope. GitHub Triage on the implementer is not required. They read the accepted verified synthesis (latest successor lean plus the verified-claims table).
|
|
516
|
+
- ! Per-thread body ingest stays the mapper after a set-level bind. Stories the bind wants are rewritten bodies or newly filed issues. Derived AC stays on that body.
|
|
517
|
+
- ! Dominated portfolio members fail closed on `cancelled`. Parent posts `design-critique: cancelled, because ...` on that number. Parent `role: parent` dominate prose is not that record. Critic, quoted, or fenced cancel-shaped prose is not that record. Leftover `mechanism-shaped` without cancel stays `missing-record` and is not this control.
|
|
518
|
+
- ! A later successor lean after cancel starts a later arc. Completing a superseded thread without a later lean would mint the harvest.
|
|
519
|
+
- ! A complete record whose latest `target shape:` field is `set-level` is `set-level-body`. Rewrite the body (and record a non-set-level shape) or file a new issue. Ingest the anchor only is not supported while that field remains set-level.
|
|
513
520
|
- ⊗ Select an author-blind latest successor lean as CurrentShape.
|
|
514
521
|
- ⊗ Put a set-level graph (dominate / split / corpus parsed from comment English) inside ingest.
|
|
515
|
-
- ! Ingest clearance cites the latest successor lean. An older completed-arc record does not clear a later
|
|
522
|
+
- ! Ingest clearance cites the latest successor lean. An older completed-arc record does not clear a later lean. A panel-deposit is in-flight even when the catalog chip missed and no critic has posted.
|
|
516
523
|
- ! The lexical form of that citation, and the requirement that the occurrence be affirmative, are published in `## Citation grammar`. Ingest reads that grammar, not prose intent.
|
|
517
524
|
- ! Keep `plan.policy.judgmentGates` matching only `design-critique:mechanism-shaped`. After `ingest-ready` replaces it, the issue leaves the gate match. Carry not-started vs live on `in-progress`, which is not in the gate match, so Stop 1 clearance scope stays H({mechanism-shaped}).
|
|
518
525
|
- ! Chip is list-visible state, not consent. Do not drop `mechanism-shaped` without the synthesis-accepted line (or the #3640 empty-disagreement path).
|
|
@@ -522,7 +529,7 @@ Closed catalog (last chip wins): `design-critique:mechanism-shaped` (in-flight,
|
|
|
522
529
|
- ! Leftover `design-critique:mechanism-shaped` after a chip apply miss does not block ingest. `judgmentGates` match is advisory/observe.
|
|
523
530
|
- ⊗ Use the halt line for a chip apply miss.
|
|
524
531
|
- ! Write-back `mechanism-shaped: true` is history after replace. The last catalog chip is list-visible state, not current-state authority. Ingest keys off the completed-arc record and cited lean.
|
|
525
|
-
- !
|
|
532
|
+
- ! A later lean applies `design-critique:mechanism-shaped` with the same remaining-set write and drops `ingest-ready`.
|
|
526
533
|
- ~ A live `design-critique:*` count!=1 check is SHOULD, not a new `judgmentGates` match.
|
|
527
534
|
- ⊗ Add `design-critique:ingest-ready` to `judgmentGates` labels.any-of.
|
|
528
535
|
- ⊗ Add `design-critique:recut-needed` to `judgmentGates` labels.any-of.
|
|
@@ -595,8 +602,8 @@ The intake cross-ref scanners (`packages/core/src/intake/markdown-scanners.ts`)
|
|
|
595
602
|
| `unshaped-table-cite` | a typed table claim names a comment on this thread that opens no line with the verified-claims-table heading |
|
|
596
603
|
| `ambiguous-table-cite` | two typed table claims name different tables |
|
|
597
604
|
| `cancelled` | `design-critique: cancelled, because ...` is the latest terminal record; no later successor lean |
|
|
598
|
-
| `
|
|
599
|
-
| `stale-target` | cited successor lean carries `Target-digest:` and the live REST issue body hash does not match; nothing written. Legacy leans with no digest stay admitted.
|
|
605
|
+
| `set-level-body` | completed-arc is present and the latest `target shape:` field is `set-level` |
|
|
606
|
+
| `stale-target` | cited successor lean carries `Target-digest:` and the live REST issue body hash does not match; nothing written. Legacy leans with no digest stay admitted. Spec-path without digest stays on #4237 |
|
|
600
607
|
|
|
601
608
|
- ! Publish a reason in that table before the evaluator returns it. An unpublished reason code is the same gap as an unpublished citation form.
|
|
602
609
|
- ⊗ Merge two states under one reason when their remedies differ. `missing-table-cite` and `unshaped-table-cite` were one reason and one detail until #3942, and the shared detail asserted an absent id in both, so an author whose table was on the thread read a true citation being called false and had no path to the missing heading.
|
package/docs/BROWNFIELD.md
CHANGED
|
@@ -145,6 +145,16 @@ This file has been migrated to `xbrief/PROJECT-DEFINITION.xbrief.json`.
|
|
|
145
145
|
|
|
146
146
|
---
|
|
147
147
|
|
|
148
|
+
## Process-only (keep Phase 2 identity)
|
|
149
|
+
|
|
150
|
+
When Phase 2 identity already exists (xbrief/PROJECT-DEFINITION.xbrief.json) and you want Directive as the process layer without a spec write, pick **Process-only (keep Phase 2 identity)** on the setup Phase 2 gate (option 2) or the matching interview leave-strategy. Do not use Back or Other for that exit.
|
|
151
|
+
|
|
152
|
+
Then-path: session ritual / deft check / later Add scope when a slice is ready. Skip Lifecycle Bridge, export, Acceptance Gate, and build. GitHub issues stay cache/queue inputs. Docs stay described content.
|
|
153
|
+
|
|
154
|
+
⊗ Treat existing docs or GitHub issues as the next-build plan. Work selection stays plan-sequence then triage:queue. An active running xBRIEF is still required before xbrief:preflight / swarm dispatch.
|
|
155
|
+
|
|
156
|
+
---
|
|
157
|
+
|
|
148
158
|
## 4. Pre-Cutover Detection Guard
|
|
149
159
|
|
|
150
160
|
On first interactive session after adding Deft, the agent-driven path runs a **pre-cutover detection guard** from `skills/deft-directive-setup/SKILL.md` and `skills/deft-directive-build/SKILL.md`. The guard detects legacy artifacts and redirects to the migration command instead of silently proceeding with a mismatched project layout.
|
|
@@ -131,6 +131,52 @@ Run from a **Grok** `run_terminal_command` child after the new session. Close st
|
|
|
131
131
|
|
|
132
132
|
When a Grok Build parent runs an N≥3 design-critique panel, this playbook's CLIs are the other-family launchers. Probe `claude` / `codex` on PATH and CLI-spawn those seats. Paste-ready is the fallback when a CLI is absent, not the default recovery. Normative stop: [`contracts/design-critique.md`](../contracts/design-critique.md) Envelope and ceiling (#4067).
|
|
133
133
|
|
|
134
|
+
The Verification pong above stays the auth probe. Critic spawn is a second recipe. Do not launch a critic by copying the issue-body spawn snippet. Recipe source: field instance 5628651806 plus the critic inventory.
|
|
135
|
+
|
|
136
|
+
### Critic spawn (second recipe)
|
|
137
|
+
|
|
138
|
+
Write the envelope to a dest file. Never put the prompt on stdin. Claude `-p` and Codex's trailing arg are prompt text, not an automatic file read — pass `Read and follow <envelope-path>`. Grok last-resort uses `--prompt-file`.
|
|
139
|
+
|
|
140
|
+
Close-stdin is the spawned child's stdio, not this host's `cmd /c "… <nul"` (not enough on the Grok wrapper) and not PowerShell `RedirectStandardInput "NUL"` (resolves to `<cwd>\NUL`). Node `spawn` with `stdio: "ignore"` or an open fd (`fs.openSync`, then pass the integer fd). `stdio: ["ignore", writeStream, writeStream]` throws `ERR_INVALID_ARG_VALUE` on Node 24 because `fd` is null. Parent Node waits until the child exits. `detached` + `unref` plus parent exit closes the fd; the critic dies with a 0-byte log.
|
|
141
|
+
|
|
142
|
+
Dest is per-arc (`ensureArcDest`) at origin/<default> after fetch. Not primary. Not another panel dest.
|
|
143
|
+
|
|
144
|
+
**Claude** (cwd = dest). Unset Process-scope `ANTHROPIC_API_KEY` and `CLAUDE_API_KEY`.
|
|
145
|
+
|
|
146
|
+
```text
|
|
147
|
+
claude -p "Read and follow <envelope-path>" --model opus --permission-mode bypassPermissions --output-format text
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
- ⊗ `--bare` (skips OAuth/keychain; with Process-scope `ANTHROPIC_API_KEY` unset the child prints not-logged-in).
|
|
151
|
+
- ⊗ `--dangerously-skip-permissions` as a synonym for `--permission-mode bypassPermissions`.
|
|
152
|
+
- `--model opus` is the CLI alias. Self-attest the `model:` slug the critic actually posts. Do not treat a comment slug as argv.
|
|
153
|
+
|
|
154
|
+
**Codex** (`-C` dest):
|
|
155
|
+
|
|
156
|
+
```text
|
|
157
|
+
codex exec --ephemeral --skip-git-repo-check --dangerously-bypass-approvals-and-sandbox -C <dest> "Read and follow <envelope-path>"
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
On ChatGPT omit `-m gpt-5.6` (HTTP 400). Self-attest the model the CLI ran.
|
|
161
|
+
|
|
162
|
+
**Grok.** Seat remains `spawn_subagent`. The host schema omits `process_only`. `subagent_type: plan` cannot post (read-only, no Shell) — dispatch-fail, not a hung critic.
|
|
163
|
+
|
|
164
|
+
Native admit without skip-class (`spawn-process-only-ready`) is not a critic seat. Count selects the class: 2+ leftover eligible briefs on payloadRoot is Deny 1; 0 is #2885; 1 eligible + dest cwd + parent id is spawn-ready implement-class (dest-lock, leftover `file_scope`). Documenting the 2-deny retry loop does not close the 1-eligible admit. Either dest-rooted CLI after any native outcome that is not that skip-class, or wait on #4315 so native can express `process_only`. Implement-class pin is `DEFT_ACTIVE_SCOPE`, not a critic recovery.
|
|
165
|
+
|
|
166
|
+
`isolation=worktree` without `cwd` is dest-missing. `isolation=worktree` plus `cwd` is invalid-extra-destination, not dest-missing.
|
|
167
|
+
|
|
168
|
+
grok CLI is last-resort after a recorded native deny:
|
|
169
|
+
|
|
170
|
+
```text
|
|
171
|
+
grok --cwd <dest> --prompt-file <path> --permission-mode bypassPermissions --always-approve --output-format plain
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
That CLI is envelope-only process-only until #4219. Dest still required (#4066 dest-proven). Do not skip dest.
|
|
175
|
+
|
|
176
|
+
⊗ Dual-launch native + CLI. ⊗ Retarget the contract Grok seat to CLI.
|
|
177
|
+
|
|
178
|
+
Keep process-only plus one `gh issue comment --body-file` post. `claude agents` may report print-mode as `kind: interactive`; do not kill it as a TTY leftover.
|
|
179
|
+
|
|
134
180
|
## Out of scope
|
|
135
181
|
|
|
136
182
|
- [#4027](https://github.com/deftai/directive/issues/4027) — N≥3 design-critique lean-timing. This playbook is host auth. Do not launch a 3-panel unless the operator asks.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
# `plan.acceptance` fields `verify:ac` requires (#4380)
|
|
2
|
+
|
|
3
|
+
Fields the product AC gate actually reads. Not a schema dump. Derivation
|
|
4
|
+
(`#3323` / `#3360`) owns the stamp. Setup stays silent on this block.
|
|
5
|
+
|
|
6
|
+
Legend (RFC2119): `!`=MUST, `~`=SHOULD, `⊗`=MUST NOT, `?`=MAY.
|
|
7
|
+
|
|
8
|
+
Load when authoring a scope xBRIEF, when `verify:ac` names a missing field, or
|
|
9
|
+
when a pass line shows `0 verified`.
|
|
10
|
+
|
|
11
|
+
## Exclusive writer
|
|
12
|
+
|
|
13
|
+
- ! `#4374` derivation is the exclusive writer of `plan.acceptance`.
|
|
14
|
+
- ⊗ Setup MUST NOT emit `plan.acceptance` (no schema-complete block, no
|
|
15
|
+
hand-authored `clauses[]`). Hand-authored clauses skip derivation, so
|
|
16
|
+
`needsClauseDerivation` is false and missing `ambiguity_attestation` fires.
|
|
17
|
+
- ⊗ Recut `#4374` clause derivation from this issue.
|
|
18
|
+
|
|
19
|
+
## Fields the gate requires
|
|
20
|
+
|
|
21
|
+
| Field | When required | Who writes it |
|
|
22
|
+
| --- | --- | --- |
|
|
23
|
+
| `commands` + `none_stated` | Empty commands are allowed only with `none_stated: true` | Intake / derivation |
|
|
24
|
+
| `source_rung` | `stated` / `derived` / `project_floor` | Intake / derivation |
|
|
25
|
+
| `ambiguity_attestation` | Required when `clauses[]` is non-empty and no clause has ambiguous readings. Value `none_found` | Derivation (`prepareClauseStamp`). ⊗ A second `none_found` default on the derivation path |
|
|
26
|
+
| `clauses[].artifact_path` | Bound from declared `plan.metadata.swarm.file_scope` when `source_rung === "derived"` (`#4008`) | Promote bind, not setup |
|
|
27
|
+
| `plan.metadata.swarm.file_scope` | Operator-collected declared members for derived-stamp bind | Operator. ⊗ Agent-invented paths. ⊗ Approved-scope digest mint (`#3145` / `#3110` / `#4383`) |
|
|
28
|
+
|
|
29
|
+
Missing attestation is **not** "derivation forgot `none_found`". It fires when
|
|
30
|
+
setup or an agent wrote clauses and skipped `#3323` / `#3360`. Provenance is a
|
|
31
|
+
derivation/ingest constraint, not a `verify:ac` config field.
|
|
32
|
+
|
|
33
|
+
## Pass lead vs fail-closed (`#3826`)
|
|
34
|
+
|
|
35
|
+
A clause with no bound artifact is `unverifiable` and non-adjudicable. On
|
|
36
|
+
pre-product `verify:ac` / `task check`, that walk is **not** fail-closed solely
|
|
37
|
+
because it has no oracle yet (`#3826`). `scope:complete` is a different reader.
|
|
38
|
+
|
|
39
|
+
The pass **lead** carries the counts on the first line:
|
|
40
|
+
|
|
41
|
+
```
|
|
42
|
+
verify:ac passed (#3284) (0 verified, N unverifiable) [rung=derived]
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
A later lean that wants zero-verified to fail closed MUST reverse `#3826` and
|
|
46
|
+
name the reader (`standalone` / `check` / `complete`).
|
|
47
|
+
|
|
48
|
+
## See also
|
|
49
|
+
|
|
50
|
+
- `task verify:ac` in [`../commands.md`](../commands.md)
|
|
51
|
+
- Clause bind: `packages/core/src/verify-ac/clauses.ts` (`bindClausesToDeclaredScope`)
|
|
52
|
+
- Attestation: `packages/core/src/intake/clause-derivation.ts` (`evaluateAmbiguityAttestation`)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deftai/directive-content",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.117.0",
|
|
4
4
|
"deftConsumerDeposit": true,
|
|
5
5
|
"description": "Shippable Directive framework content in the consumer .deft/core/ layout (C1 flatten), plus the engine surfaces (.githooks/, Taskfile.yml, tasks/) the deposit wires. Python-free per #2022 Phase 3. Refs #11, #1669, #1967.",
|
|
6
6
|
"license": "MIT",
|