mandrel 2.36.0 → 2.38.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/.agents/README.md +16 -16
- package/.agents/agents/plan-critic.md +1 -1
- package/.agents/docs/SDLC.md +40 -40
- package/.agents/docs/configuration.md +41 -16
- package/.agents/docs/execution-reference.md +3 -3
- package/.agents/docs/quality-gates.md +2 -2
- package/.agents/docs/workflows.md +6 -6
- package/.agents/instructions.md +5 -5
- package/.agents/rules/changelog-style.md +3 -3
- package/.agents/rules/ci-remediation.md +1 -1
- package/.agents/rules/git-conventions-reference.md +4 -4
- package/.agents/rules/testing-standards.md +56 -0
- package/.agents/schemas/agentrc.schema.json +9 -9
- package/.agents/schemas/story-deliver-terminal.schema.json +2 -2
- package/.agents/schemas/validation-evidence.schema.json +1 -1
- package/.agents/scripts/acceptance-eval.js +1 -1
- package/.agents/scripts/apply-quality-bootstrap.js +1 -1
- package/.agents/scripts/audit-to-stories.js +2 -2
- package/.agents/scripts/boot-sweep.js +7 -1
- package/.agents/scripts/check-context-budget.js +195 -103
- package/.agents/scripts/check-cyclomatic.js +112 -42
- package/.agents/scripts/check-doc-links.js +32 -4
- package/.agents/scripts/check-generated-validator.js +202 -0
- package/.agents/scripts/check-lifecycle-lint.js +2 -68
- package/.agents/scripts/check-schema-references.js +2 -28
- package/.agents/scripts/check-test-temp-hygiene.js +1 -1
- package/.agents/scripts/check-workflow-cli-lint.js +1 -1
- package/.agents/scripts/deliver-light.js +10 -10
- package/.agents/scripts/deliver-recover.js +1 -1
- package/.agents/scripts/drain-pending-cleanup.js +19 -2
- package/.agents/scripts/evidence-gate.js +1 -1
- package/.agents/scripts/generate-workflows-doc.js +1 -1
- package/.agents/scripts/lib/audit-suite/selector.js +1 -1
- package/.agents/scripts/lib/audit-to-stories/audit-label-taxonomy.js +1 -1
- package/.agents/scripts/lib/audit-to-stories/build-story-body.js +1 -1
- package/.agents/scripts/lib/audit-to-stories/seed-from-findings.js +5 -5
- package/.agents/scripts/lib/audit-to-stories/wire-dependencies.js +1 -1
- package/.agents/scripts/lib/baselines/components.js +32 -2
- package/.agents/scripts/lib/baselines/env-overrides.js +1 -1
- package/.agents/scripts/lib/bdd-runner-detect.js +1 -1
- package/.agents/scripts/lib/bdd-scenario-budget.js +1 -1
- package/.agents/scripts/lib/bdd-scenario-scanner.js +3 -3
- package/.agents/scripts/lib/bdd-step-index.js +1 -1
- package/.agents/scripts/lib/bootstrap/branch-protection.js +2 -2
- package/.agents/scripts/lib/bootstrap/commit-push.js +2 -2
- package/.agents/scripts/lib/bootstrap/install-ledger.js +1 -1
- package/.agents/scripts/lib/bootstrap/issue-forms-template.js +1 -1
- package/.agents/scripts/lib/bootstrap/prompt.js +1 -1
- package/.agents/scripts/lib/bootstrap/quality-bootstrap.js +2 -2
- package/.agents/scripts/lib/checks/core-bare-clean.js +1 -1
- package/.agents/scripts/lib/checks/loop-health.js +1 -1
- package/.agents/scripts/lib/checks/story-init-not-backgrounded.js +1 -1
- package/.agents/scripts/lib/cli-args.js +1 -3
- package/.agents/scripts/lib/close-validation/gates.js +1 -1
- package/.agents/scripts/lib/close-validation/process.js +1 -1
- package/.agents/scripts/lib/command-header.js +1 -1
- package/.agents/scripts/lib/config/delivery-routing.js +1 -1
- package/.agents/scripts/lib/config/explain.js +1 -1
- package/.agents/scripts/lib/config/runners.js +2 -2
- package/.agents/scripts/lib/config/runtime.js +1 -1
- package/.agents/scripts/lib/config/sync-agentrc.js +1 -1
- package/.agents/scripts/lib/config/temp-paths.js +2 -2
- package/.agents/scripts/lib/config-settings-schema-delivery.js +3 -3
- package/.agents/scripts/lib/config-settings-schema-quality.js +6 -6
- package/.agents/scripts/lib/config-settings-schema.js +49 -9
- package/.agents/scripts/lib/coverage-baseline.js +2 -2
- package/.agents/scripts/lib/cpu-pool.js +90 -10
- package/.agents/scripts/lib/crap-utils.js +6 -2
- package/.agents/scripts/lib/cyclomatic-ceiling.js +28 -6
- package/.agents/scripts/lib/cyclomatic-scope.js +144 -0
- package/.agents/scripts/lib/dependency-version.js +86 -0
- package/.agents/scripts/lib/duplicate-search.js +2 -2
- package/.agents/scripts/lib/errors/index.js +1 -1
- package/.agents/scripts/lib/feedback-loop/graduator-core.js +2 -2
- package/.agents/scripts/lib/feedback-loop/prior-feedback-fetcher.js +5 -5
- package/.agents/scripts/lib/feedback-loop/retro-proposals-graduator.js +2 -2
- package/.agents/scripts/lib/findings/classify-finding.js +1 -1
- package/.agents/scripts/lib/findings/promote-finding.js +12 -12
- package/.agents/scripts/lib/findings/route-finding.js +2 -2
- package/.agents/scripts/lib/generated/agentrc-validator.js +16 -0
- package/.agents/scripts/lib/git-branch-lifecycle.js +2 -2
- package/.agents/scripts/lib/install-cmd-parser.js +1 -1
- package/.agents/scripts/lib/knip-entry-sync.js +1 -57
- package/.agents/scripts/lib/label-constants.js +2 -2
- package/.agents/scripts/lib/label-taxonomy.js +1 -1
- package/.agents/scripts/lib/maintainability-utils.js +108 -10
- package/.agents/scripts/lib/observability/source-classifier.js +1 -0
- package/.agents/scripts/lib/onboard/init-tail.js +4 -4
- package/.agents/scripts/lib/onboard/scaffold-docs.js +2 -2
- package/.agents/scripts/lib/orchestration/acceptance-eval-decision.js +1 -1
- package/.agents/scripts/lib/orchestration/code-review.js +4 -4
- package/.agents/scripts/lib/orchestration/complexity-gate.js +5 -5
- package/.agents/scripts/lib/orchestration/deliver-recover.js +3 -3
- package/.agents/scripts/lib/orchestration/docs-digest.js +3 -3
- package/.agents/scripts/lib/orchestration/lease-guard-shared.js +2 -2
- package/.agents/scripts/lib/orchestration/light-backstop.js +1 -1
- package/.agents/scripts/lib/orchestration/light-escalation.js +6 -6
- package/.agents/scripts/lib/orchestration/light-suitability.js +19 -19
- package/.agents/scripts/lib/orchestration/plan-context.js +4 -4
- package/.agents/scripts/lib/orchestration/plan-critic-conditions.js +2 -2
- package/.agents/scripts/lib/orchestration/plan-critics-evaluate.js +2 -2
- package/.agents/scripts/lib/orchestration/plan-metrics.js +1 -1
- package/.agents/scripts/lib/orchestration/plan-persist/persist-helpers.js +1 -1
- package/.agents/scripts/lib/orchestration/plan-persist/plan-context-source.js +3 -3
- package/.agents/scripts/lib/orchestration/plan-persist/run-plan-persist.js +6 -6
- package/.agents/scripts/lib/orchestration/plan-persist/story-ops.js +86 -25
- package/.agents/scripts/lib/orchestration/plan-persist/summary.js +3 -3
- package/.agents/scripts/lib/orchestration/plan-persist/supersede-ops.js +6 -6
- package/.agents/scripts/lib/orchestration/planning/authoring-context.js +7 -7
- package/.agents/scripts/lib/orchestration/planning/decomposer-context.js +1 -1
- package/.agents/scripts/lib/orchestration/planning/memory-pool-advisory.js +3 -3
- package/.agents/scripts/lib/orchestration/pr-watch.js +1 -30
- package/.agents/scripts/lib/orchestration/reassert-status-column.js +2 -2
- package/.agents/scripts/lib/orchestration/remote-verifier.js +2 -2
- package/.agents/scripts/lib/orchestration/resolve-stories.js +4 -4
- package/.agents/scripts/lib/orchestration/review-providers/codex.js +3 -3
- package/.agents/scripts/lib/orchestration/review-providers/findings-renderer.js +1 -1
- package/.agents/scripts/lib/orchestration/review-providers/native.js +9 -2
- package/.agents/scripts/lib/orchestration/review-providers/review-depth.js +2 -2
- package/.agents/scripts/lib/orchestration/review-providers/security-review.js +3 -3
- package/.agents/scripts/lib/orchestration/run-epilogue.js +2 -2
- package/.agents/scripts/lib/orchestration/single-story-close/phases/base-sync.js +2 -2
- package/.agents/scripts/lib/orchestration/single-story-close/phases/conventional-subject.js +1 -1
- package/.agents/scripts/lib/orchestration/single-story-close/phases/normalize-pr-title.js +5 -1
- package/.agents/scripts/lib/orchestration/single-story-close/phases/options.js +52 -1
- package/.agents/scripts/lib/orchestration/single-story-close/phases/review-block.js +1 -1
- package/.agents/scripts/lib/orchestration/single-story-close/phases/wrong-tree-guard.js +3 -3
- package/.agents/scripts/lib/orchestration/single-story-close/runner.js +2 -2
- package/.agents/scripts/lib/orchestration/single-story-lease-guard.js +1 -1
- package/.agents/scripts/lib/orchestration/story-close/format-autofix.js +2 -5
- package/.agents/scripts/lib/orchestration/story-deliver-terminal.js +14 -12
- package/.agents/scripts/lib/orchestration/story-follow-ups.js +1 -1
- package/.agents/scripts/lib/orchestration/ticket-lease.js +34 -9
- package/.agents/scripts/lib/orchestration/ticket-validator.js +1 -1
- package/.agents/scripts/lib/orchestration/ticketing/reads.js +6 -4
- package/.agents/scripts/lib/plan-phase-cleanup.js +1 -1
- package/.agents/scripts/lib/preflight-runner.js +3 -3
- package/.agents/scripts/lib/qa/qa-session.js +1 -1
- package/.agents/scripts/lib/runtime-deps/manifest.js +1 -7
- package/.agents/scripts/lib/runtime-deps/scan-imports.js +3 -58
- package/.agents/scripts/lib/signals/schema.js +1 -1
- package/.agents/scripts/lib/single-story-sweep/sweep-lock.js +284 -25
- package/.agents/scripts/lib/skills/walk-skill-files.js +1 -1
- package/.agents/scripts/lib/source-text/strip-js-comments.js +115 -0
- package/.agents/scripts/lib/story-adjacency.js +2 -2
- package/.agents/scripts/lib/templates/decomposer-prompts.js +1 -1
- package/.agents/scripts/lib/test-isolate/runner.js +3 -3
- package/.agents/scripts/lib/test-runner-contract.js +14 -6
- package/.agents/scripts/lib/test-tiers.js +135 -18
- package/.agents/scripts/lib/ticket-body-sections.js +1 -1
- package/.agents/scripts/lib/transpile.js +16 -3
- package/.agents/scripts/lib/util/concurrent-map.js +1 -1
- package/.agents/scripts/lib/util/parse-id-list.js +1 -1
- package/.agents/scripts/lib/wave-runner/live-probe.js +4 -4
- package/.agents/scripts/lib/wave-runner/ready-set.js +1 -1
- package/.agents/scripts/lib/workflow-closure.js +1 -1
- package/.agents/scripts/lib/worktree/lifecycle/pending-cleanup.js +170 -32
- package/.agents/scripts/lib/worktree/node-modules-strategy.js +2 -5
- package/.agents/scripts/lint-issue-body.js +3 -3
- package/.agents/scripts/plan-context.js +4 -4
- package/.agents/scripts/plan-critics.js +2 -2
- package/.agents/scripts/plan-persist.js +2 -2
- package/.agents/scripts/plan-run-epilogue.js +2 -2
- package/.agents/scripts/pr-watch-with-update.js +305 -137
- package/.agents/scripts/providers/github/board-add.js +1 -1
- package/.agents/scripts/providers/github/errors.js +1 -1
- package/.agents/scripts/providers/github/tickets.js +114 -21
- package/.agents/scripts/quality-preview.js +162 -70
- package/.agents/scripts/resolve-stories.js +3 -3
- package/.agents/scripts/resync-status-column.js +1 -1
- package/.agents/scripts/run-lint.js +1 -1
- package/.agents/scripts/run-test-profile.js +8 -5
- package/.agents/scripts/run-tests.js +79 -14
- package/.agents/scripts/single-story-close.js +2 -4
- package/.agents/scripts/single-story-init.js +10 -6
- package/.agents/scripts/stories-wave-tick.js +8 -8
- package/.agents/skills/core/idea-refinement/SKILL.md +5 -5
- package/.agents/skills/core/scope-triage/SKILL.md +3 -3
- package/.agents/skills/skills.index.json +1 -1
- package/.agents/skills/stack/qa/qa-harness/SKILL.md +1 -1
- package/.agents/workflows/audit-data-model.md +1 -1
- package/.agents/workflows/audit-documentation.md +2 -2
- package/.agents/workflows/audit-to-stories.md +11 -11
- package/.agents/workflows/git-deliver.md +4 -4
- package/.agents/workflows/helpers/_merge-conflict-template.md +1 -1
- package/.agents/workflows/helpers/audit-lens-core.md +1 -1
- package/.agents/workflows/helpers/code-review.md +4 -4
- package/.agents/workflows/helpers/deliver-light.md +26 -26
- package/.agents/workflows/helpers/deliver-reference.md +15 -7
- package/.agents/workflows/helpers/deliver-story-reference.md +9 -4
- package/.agents/workflows/helpers/deliver-story.md +6 -7
- package/.agents/workflows/helpers/diagnose.md +2 -2
- package/.agents/workflows/helpers/parallel-tooling.md +1 -1
- package/.agents/workflows/helpers/plan-reference.md +9 -9
- package/.agents/workflows/helpers/qa-core.md +8 -8
- package/.agents/workflows/helpers/worktree-lifecycle.md +6 -6
- package/.agents/workflows/{deliver.md → mandrel-deliver.md} +15 -19
- package/.agents/workflows/{plan.md → mandrel-plan.md} +9 -9
- package/.agents/workflows/memory-consolidate.md +4 -4
- package/.agents/workflows/prototype.md +3 -3
- package/.agents/workflows/qa-assist.md +12 -12
- package/.agents/workflows/qa-explore.md +6 -6
- package/.agents/workflows/qa-run.md +1 -1
- package/README.md +7 -7
- package/docs/CHANGELOG.md +43 -0
- package/lib/cli/doctor.js +1 -1
- package/lib/cli/init.js +1 -1
- package/lib/cli/migrate.js +100 -94
- package/lib/migrations/helpers/retire-agentrc-key.js +200 -0
- package/lib/migrations/index.js +32 -33
- package/lib/migrations/steps/2.1.0-retire-mi-drop-knobs.js +21 -80
- package/lib/migrations/steps/2.1.0-retire-verify-concurrency-cap.js +15 -87
- package/lib/migrations/steps/2.11.0-retire-max-seed-words.js +13 -71
- package/lib/migrations/steps/2.2.0-retire-epic-ac-tags.js +1 -1
- package/lib/migrations/steps/2.20.0-retire-codebase-snapshot.js +13 -101
- package/lib/migrations/steps/2.32.0-retire-lint-baseline-command.js +13 -100
- package/package.json +7 -3
- package/.agents/scripts/lib/audit-suite/frontmatter-lint.js +0 -32
- package/.agents/scripts/lib/baselines/maintainability-baseline-save.js +0 -37
- package/.agents/scripts/lib/cli/parse-numeric.js +0 -60
- package/.agents/scripts/lib/close-validation/telemetry.js +0 -79
- package/.agents/scripts/lib/orchestration/label-transitions.js +0 -44
- package/.agents/scripts/lib/orchestration/parked-follow-ons.js +0 -147
- package/.agents/scripts/lib/orchestration/phase-runner.js +0 -88
- package/.agents/scripts/lib/orchestration/recut.js +0 -56
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
---
|
|
2
2
|
description:
|
|
3
|
-
On-demand reference appendix for /deliver — the sequencing edge cases,
|
|
3
|
+
On-demand reference appendix for /mandrel-deliver — the sequencing edge cases,
|
|
4
4
|
role-scoped dispatch mechanics, lite-route inline execution, checklist
|
|
5
5
|
threading, and the per-run epilogue. Read it when the matching lever is in
|
|
6
6
|
play; the lean spine in deliver.md links here.
|
|
7
7
|
---
|
|
8
8
|
|
|
9
|
-
# /deliver — reference appendix (on-demand)
|
|
9
|
+
# /mandrel-deliver — reference appendix (on-demand)
|
|
10
10
|
|
|
11
|
-
Reference-only detail split out of [`deliver.md`](../deliver.md) so the
|
|
11
|
+
Reference-only detail split out of [`mandrel-deliver.md`](../mandrel-deliver.md) so the
|
|
12
12
|
always-resident spine stays lean. Nothing here is a new MUST —
|
|
13
13
|
it is the mechanics an operator consults when the matching lever is engaged.
|
|
14
14
|
|
|
15
15
|
## Ranges (`4922 - 4926`) {#ranges}
|
|
16
16
|
|
|
17
17
|
A contiguous span is how an operator reads a plan run, so the dash range is a
|
|
18
|
-
first-class id shape rather than prose to interpret — `/deliver 4922 - 4926`
|
|
18
|
+
first-class id shape rather than prose to interpret — `/mandrel-deliver 4922 - 4926`
|
|
19
19
|
means exactly the five ids in it.
|
|
20
20
|
|
|
21
21
|
**Pass the span through; never expand it by hand.** Every id-list flag on the
|
|
@@ -49,6 +49,14 @@ issue state rather than against anything you hand it. That is why there is no
|
|
|
49
49
|
batch label to pass and why a blocker that landed in an unrelated run is simply
|
|
50
50
|
seen as done.
|
|
51
51
|
|
|
52
|
+
**The non-zero exit codes.** **2** — `cycleError`: the graph is
|
|
53
|
+
self-referential; fix `depends_on`, do not retry. **3** — `wedged`: nothing
|
|
54
|
+
dispatchable and nothing in flight, with the undone Stories and their unmet
|
|
55
|
+
blockers named; land a blocker or add it to `--ids`. **4** — `blocked`: a Story
|
|
56
|
+
carries `agent::blocked` with `blockedReason`, the protocol's HITL pause
|
|
57
|
+
([`instructions.md` § 1.J](../../instructions.md)). Blocked outranks a wedge,
|
|
58
|
+
but not a cycle.
|
|
59
|
+
|
|
52
60
|
**Resuming an exit-4 `blocked`.** Read the friction comment with
|
|
53
61
|
`gh issue view <id> --comments`, and resume only once the operator has
|
|
54
62
|
unblocked it:
|
|
@@ -184,7 +192,7 @@ exposes agent dispatch, spawn each ready Story as its own
|
|
|
184
192
|
`CLAUDE.md` @-closure) carrying the load-bearing delivery MUSTs standalone. The
|
|
185
193
|
sub-agent executes [`deliver-story.md`](deliver-story.md) Steps 0–2.5
|
|
186
194
|
(init → implement → acceptance self-eval → **push**) and stops there; **you**
|
|
187
|
-
own Step 3, serialized — see `/deliver` § Closing what the workers hand back.
|
|
195
|
+
own Step 3, serialized — see `/mandrel-deliver` § Closing what the workers hand back.
|
|
188
196
|
Thread into its prompt: `storyId`; `docsDigestPath` (the per-run docs digest, null when
|
|
189
197
|
`project.docsContextFiles` is unset); `checklistPath` (the footprint-matched
|
|
190
198
|
write-time audit checklist, produced at dispatch, below); and the
|
|
@@ -225,7 +233,7 @@ terminal envelope are identical either way — only the isolation differs.
|
|
|
225
233
|
|
|
226
234
|
## Intent phrases (what replaced the flag table)
|
|
227
235
|
|
|
228
|
-
`/deliver` has no operator-facing flags. The scripts still take every flag they
|
|
236
|
+
`/mandrel-deliver` has no operator-facing flags. The scripts still take every flag they
|
|
229
237
|
always did — the workflow fills them in from what the operator said, the same
|
|
230
238
|
derive-then-announce contract `/git-deliver` uses for its terminal level.
|
|
231
239
|
|
|
@@ -252,7 +260,7 @@ Two rules keep this honest:
|
|
|
252
260
|
operator expresses; it is a runner asserting *nobody is at the keyboard*, and
|
|
253
261
|
it changes fail-closed behavior (it is what turns the unplanned path's
|
|
254
262
|
over-scope stop into an `escalated` terminal envelope, and what auto-proceeds
|
|
255
|
-
`/plan`'s gates). Cron, `/loop`, and headless dispatch set it. An attended run
|
|
263
|
+
`/mandrel-plan`'s gates). Cron, `/loop`, and headless dispatch set it. An attended run
|
|
256
264
|
never does, however the operator phrases their impatience.
|
|
257
265
|
|
|
258
266
|
## Operator-merge implies no-wait
|
|
@@ -33,7 +33,7 @@ Epic-scoped dispatch manifest to serialise two operators driving the same
|
|
|
33
33
|
Story, so this lease is the only guard against a concurrent
|
|
34
34
|
`single-story-init` clobbering an in-flight run.
|
|
35
35
|
|
|
36
|
-
**Fail-closed.** Unlike `/deliver`, the standalone path
|
|
36
|
+
**Fail-closed.** Unlike `/mandrel-deliver`, the standalone path
|
|
37
37
|
has **no Epic-scoped lifecycle ledger** to read a per-owner
|
|
38
38
|
`story.heartbeat` from, so there is no live-heartbeat source to decide
|
|
39
39
|
whether a foreign claim is stale. Rather than silently reclaim every
|
|
@@ -131,7 +131,7 @@ The v2 engine's trait table:
|
|
|
131
131
|
| Ceremony | Per-Story, routed off the derived change level via `ceremony-routing.js` |
|
|
132
132
|
|
|
133
133
|
**Ceremony-lite Stories still land through this engine unchanged.** A
|
|
134
|
-
lite-routed Story collapses only the _advisory_ plan/deliver
|
|
134
|
+
lite-routed Story collapses only the _advisory_ plan/mandrel-deliver
|
|
135
135
|
ceremony — the fresh-critic / Tech-Spec authoring a one-artifact scope does
|
|
136
136
|
not earn. It does **not** get a cheaper landing: the close-validation gates
|
|
137
137
|
(lint / test / format / coverage / CRAP / maintainability), the PR to `main`,
|
|
@@ -231,7 +231,7 @@ demand. See [`.agents/instructions.md` § 3](../../instructions.md).
|
|
|
231
231
|
write and self-check as you author. When absent, lens-aware coverage still
|
|
232
232
|
runs maker-blind at Story-scope review inside the close subprocess. The
|
|
233
233
|
dispatch step produces `checklistPath` from the Story's predicted footprint
|
|
234
|
-
before it spawns the worker — see [`/deliver`](../deliver.md).
|
|
234
|
+
before it spawns the worker — see [`/mandrel-deliver`](../mandrel-deliver.md).
|
|
235
235
|
|
|
236
236
|
**Pre-eval full-suite discipline (spine step 1.3).** Repo-invariant guards —
|
|
237
237
|
drift-guard and schema tests living outside the Story's scoped greps — are
|
|
@@ -542,7 +542,7 @@ The `single-story-close.js` script, in order:
|
|
|
542
542
|
`gh pr merge <prNumber> --auto --squash --delete-branch`. Once CI's
|
|
543
543
|
required checks turn green, GitHub squash-merges the PR and deletes
|
|
544
544
|
the source branch — the operator does not need to babysit the merge
|
|
545
|
-
button. Mirrors the `/deliver` finalize path. Failure is
|
|
545
|
+
button. Mirrors the `/mandrel-deliver` finalize path. Failure is
|
|
546
546
|
non-fatal: the operator retains the manual merge surface in the
|
|
547
547
|
GitHub UI. Pass `--no-auto-merge` to opt out when the PR needs a
|
|
548
548
|
pre-merge eyeball.
|
|
@@ -909,6 +909,11 @@ up").
|
|
|
909
909
|
|
|
910
910
|
## Idempotence and the standing constraints
|
|
911
911
|
|
|
912
|
+
**Why a no-envelope hand-off must never be re-dispatched.** Only Step 3 mints a
|
|
913
|
+
terminal envelope, so a sub-agent returning without one is the normal shape. The
|
|
914
|
+
branch already exists, and re-running Step 0 underneath live work is how one
|
|
915
|
+
Story ends up with two closes — resume per the spine's § Recovery instead.
|
|
916
|
+
|
|
912
917
|
Every script in the chain no-ops safely on re-run: `single-story-init.js`
|
|
913
918
|
re-prints `workCwd` for an already-initialized Story; `single-story-close.js`
|
|
914
919
|
and `single-story-confirm-merge.js` short-circuit on a closed or `agent::done`
|
|
@@ -9,7 +9,7 @@ mandatoryReads: [deliver-digest.md]
|
|
|
9
9
|
|
|
10
10
|
> **Lean spine.** Happy path + gate list; edge-case, recovery and reference
|
|
11
11
|
> detail lives in [`deliver-story-reference.md`](deliver-story-reference.md)
|
|
12
|
-
> ("reference" below). Invoked by [`/deliver`](../deliver.md).
|
|
12
|
+
> ("reference" below). Invoked by [`/mandrel-deliver`](../mandrel-deliver.md).
|
|
13
13
|
> **Read [`deliver-digest.md`](deliver-digest.md) once, first** — the one
|
|
14
14
|
> bundled read every delivery needs. Steps cite it as "digest § N".
|
|
15
15
|
|
|
@@ -34,14 +34,13 @@ that dispatched the work**, never to a spawned worker.
|
|
|
34
34
|
- **Inline dispatch** (a one-Story run — digest § 1): one session is both
|
|
35
35
|
roles and walks Steps 0→7, no hand-off.
|
|
36
36
|
- **Sub-agent dispatch**: the `story-worker` stops at Step 2.5 with the branch
|
|
37
|
-
pushed and returns a hand-off; the dispatching `/deliver` session runs Step 3
|
|
37
|
+
pushed and returns a hand-off; the dispatching `/mandrel-deliver` session runs Step 3
|
|
38
38
|
**in its own turn** and **serializes the tail — one close at a time across
|
|
39
39
|
the run**, even though implementation ran in parallel (reference § Step 3).
|
|
40
40
|
|
|
41
|
-
**A worker returning no terminal envelope is expected, not a failure
|
|
42
|
-
Step 3 mints one
|
|
43
|
-
|
|
44
|
-
live work is how one Story gets two closes. Resume per § Recovery instead.
|
|
41
|
+
**A worker returning no terminal envelope is expected, not a failure** — only
|
|
42
|
+
Step 3 mints one. Never re-dispatch the Story on it; resume per § Recovery
|
|
43
|
+
(reference § Idempotence and the standing constraints).
|
|
45
44
|
|
|
46
45
|
## Step 0 — Initialize (`single-story-init.js`)
|
|
47
46
|
|
|
@@ -162,5 +161,5 @@ not process. Drive `agent::*` through
|
|
|
162
161
|
|
|
163
162
|
## See also
|
|
164
163
|
|
|
165
|
-
[`deliver-digest.md`](deliver-digest.md), [`/deliver`](../deliver.md),
|
|
164
|
+
[`deliver-digest.md`](deliver-digest.md), [`/mandrel-deliver`](../mandrel-deliver.md),
|
|
166
165
|
[`deliver-story-reference.md`](deliver-story-reference.md).
|
|
@@ -9,7 +9,7 @@ description: >-
|
|
|
9
9
|
|
|
10
10
|
> **Helper, not a slash command.** Files under `workflows/helpers/` are not
|
|
11
11
|
> projected into the mandrel plugin command tree. The same `lib/checks/` registry runs
|
|
12
|
-
> automatically as preflight inside `/deliver`, `single-story-close`, and
|
|
12
|
+
> automatically as preflight inside `/mandrel-deliver`, `single-story-close`, and
|
|
13
13
|
> `npm test` — this viewer exists only for ad-hoc inspection. Invoke the
|
|
14
14
|
> backing script directly: `node .agents/scripts/diagnose.js [args]`.
|
|
15
15
|
|
|
@@ -18,7 +18,7 @@ description: >-
|
|
|
18
18
|
`diagnose.js` runs the checks registry assembled under
|
|
19
19
|
`.agents/scripts/lib/checks/` in read-only mode and surfaces every
|
|
20
20
|
finding declared on the requested scope. It is the operator-facing read
|
|
21
|
-
of the same registry that preflight guards (`/deliver`,
|
|
21
|
+
of the same registry that preflight guards (`/mandrel-deliver`,
|
|
22
22
|
`single-story-close`), the retro hook, and `npm test` consult — but with
|
|
23
23
|
`autoFix: false` always, no remote GitHub writes, and no commits.
|
|
24
24
|
|
|
@@ -58,7 +58,7 @@ the same shape as Rule 1 but at the sub-agent layer.
|
|
|
58
58
|
|
|
59
59
|
- **Tool primitives:** `Agent` (one call per independent unit, all in one
|
|
60
60
|
turn).
|
|
61
|
-
- **When:** wave-level Story fan-out from `/deliver`, per-dimension
|
|
61
|
+
- **When:** wave-level Story fan-out from `/mandrel-deliver`, per-dimension
|
|
62
62
|
audit dispatch, any "for each X in Xs run /Y X" loop where the Xs do not
|
|
63
63
|
share write paths.
|
|
64
64
|
- **Anti-pattern:** serial `Agent` calls (`Agent` → wait → `Agent` → wait)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
# /plan — on-demand reference appendix
|
|
1
|
+
# /mandrel-plan — on-demand reference appendix
|
|
2
2
|
|
|
3
|
-
> **Applies when:** you are executing [`/plan`](../plan.md) and hit one of the
|
|
3
|
+
> **Applies when:** you are executing [`/mandrel-plan`](../mandrel-plan.md) and hit one of the
|
|
4
4
|
> situations below — input-mode derivation, the Gate #1 light handoff,
|
|
5
5
|
> shape-derived complexity routing, tickets-mode supersede authoring, critic
|
|
6
6
|
> dispatch detail, a failed persist, or source-id resolution. The spine stays
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
|
|
9
9
|
## Deriving the input mode
|
|
10
10
|
|
|
11
|
-
`/plan` has no operator-facing flags; the CLIs below still take every flag they
|
|
11
|
+
`/mandrel-plan` has no operator-facing flags; the CLIs below still take every flag they
|
|
12
12
|
always did. Read the invocation, **announce what you derived**, then fill in
|
|
13
13
|
the flag — the same derive-then-announce contract `/git-deliver` uses for its
|
|
14
14
|
terminal level.
|
|
@@ -94,7 +94,7 @@ not re-deriving which assumptions were really the agent's to make.
|
|
|
94
94
|
|
|
95
95
|
## Gate #1 → the light path (in-session handoff)
|
|
96
96
|
|
|
97
|
-
On a confirmed `deliverLightSuggestion`, `/plan` routes into
|
|
97
|
+
On a confirmed `deliverLightSuggestion`, `/mandrel-plan` routes into
|
|
98
98
|
[`deliver-light.md`](deliver-light.md) **without ending the session**. Two
|
|
99
99
|
things make that safe, and both are worth understanding before changing it:
|
|
100
100
|
|
|
@@ -110,7 +110,7 @@ things make that safe, and both are worth understanding before changing it:
|
|
|
110
110
|
span). Two different checks on purpose, so a confirm is not a bypass.
|
|
111
111
|
|
|
112
112
|
**When the light gate answers `ask-operator`**, the two ceiling sets disagreed.
|
|
113
|
-
Resume `/plan` at step 2 (Author) **in this same session** — the interrogation
|
|
113
|
+
Resume `/mandrel-plan` at step 2 (Author) **in this same session** — the interrogation
|
|
114
114
|
is still valid and re-paying for it buys nothing. This bounce-back is not an
|
|
115
115
|
escalation.
|
|
116
116
|
|
|
@@ -138,7 +138,7 @@ in `audit-rules.json`. There is no configuration key to set: a project with no
|
|
|
138
138
|
rendered frontend resolves falsey and the offer never fires.
|
|
139
139
|
|
|
140
140
|
When it does fire, **name [`/prototype`](../prototype.md) and stop there.**
|
|
141
|
-
`/plan` must never invoke it — operator invocation is the entire design, because
|
|
141
|
+
`/mandrel-plan` must never invoke it — operator invocation is the entire design, because
|
|
142
142
|
the value is a human looking at a layout before its UI acceptance criteria are
|
|
143
143
|
frozen.
|
|
144
144
|
|
|
@@ -182,7 +182,7 @@ decision:
|
|
|
182
182
|
|
|
183
183
|
**The label is a hint; deliver re-derives.** Persist labels a
|
|
184
184
|
lite cohort's Stories with **`route::lite`** as a *human-visible hint only* —
|
|
185
|
-
`/deliver` computes the route from each fetched Story body via the same shape
|
|
185
|
+
`/mandrel-deliver` computes the route from each fetched Story body via the same shape
|
|
186
186
|
function at dispatch, so neither a lost label nor an unread marker can
|
|
187
187
|
misroute delivery: a lite-shaped Story derives `lite` even with the label
|
|
188
188
|
absent, and a sensitive-footprint Story routes `full` and keeps its fresh
|
|
@@ -421,7 +421,7 @@ The order is: create unlabelled → upsert `story-plan-state` on
|
|
|
421
421
|
every Story → upsert `plan-summary` on the primary → flip every Story to
|
|
422
422
|
`agent::ready`.
|
|
423
423
|
|
|
424
|
-
This is what lets `/deliver` trust the label: a Story carrying
|
|
424
|
+
This is what lets `/mandrel-deliver` trust the label: a Story carrying
|
|
425
425
|
`agent::ready` always has its persist receipt on the ticket, so nothing can
|
|
426
426
|
pick it up mid-write and read a half-persisted plan.
|
|
427
427
|
|
|
@@ -436,7 +436,7 @@ So if a transient GitHub failure strands the run at Story `k` of `N`:
|
|
|
436
436
|
|
|
437
437
|
| | Behaviour |
|
|
438
438
|
| --- | --- |
|
|
439
|
-
| The `1..k-1` Stories | Live, but **not** `agent::ready` — invisible to `/deliver`, not half-delivered. |
|
|
439
|
+
| The `1..k-1` Stories | Live, but **not** `agent::ready` — invisible to `/mandrel-deliver`, not half-delivered. |
|
|
440
440
|
| Re-running persist | Adopts them by fingerprint, creates only the missing ones, then flips the whole cohort ready. |
|
|
441
441
|
| Editing `stories.json` first | Changing a slug or title changes the fingerprint — the old issue is orphaned rather than adopted. Close it by hand. |
|
|
442
442
|
|
|
@@ -115,7 +115,7 @@ is no per-workflow finding schema.
|
|
|
115
115
|
Route the ledger through the shared classify/route/dedup/promote core. The
|
|
116
116
|
outcome is that **every ledger item carries a class, a route decision, and an
|
|
117
117
|
operator-confirmed disposition**, with each `file` item promoted via
|
|
118
|
-
`promote-finding.js` into `/plan` — verified by the cluster's fingerprint
|
|
118
|
+
`promote-finding.js` into `/mandrel-plan` — verified by the cluster's fingerprint
|
|
119
119
|
footer landing in each seed body. For each untriaged item:
|
|
120
120
|
|
|
121
121
|
1. **Classify** via
|
|
@@ -140,7 +140,7 @@ footer landing in each seed body. For each untriaged item:
|
|
|
140
140
|
against it.
|
|
141
141
|
3. **Decide the disposition** with the operator (`file` / `defer` / `dismiss`)
|
|
142
142
|
and record it back onto the ledger item.
|
|
143
|
-
4. **Promote the `file`-dispositioned findings through `/plan`** via
|
|
143
|
+
4. **Promote the `file`-dispositioned findings through `/mandrel-plan`** via
|
|
144
144
|
[`promote-finding.js`](../../scripts/lib/findings/promote-finding.js) — the
|
|
145
145
|
same cluster/size/route/file path `audit-to-stories` consumes. Never
|
|
146
146
|
hand-roll the clustering, sizing, or promotion in prose:
|
|
@@ -149,8 +149,8 @@ footer landing in each seed body. For each untriaged item:
|
|
|
149
149
|
import { promoteFindings } from '../scripts/lib/findings/promote-finding.js';
|
|
150
150
|
const { promotions } = await promoteFindings(ledgerItems, {
|
|
151
151
|
searchIssues, // GitHub provider, open + closed
|
|
152
|
-
createStory, // tight cluster (≤2 surfaces): seed → /plan --seed-file
|
|
153
|
-
createPlanSeed, // broad cluster (>2 surfaces): same /plan --seed-file path (may N>1)
|
|
152
|
+
createStory, // tight cluster (≤2 surfaces): seed → /mandrel-plan --seed-file
|
|
153
|
+
createPlanSeed, // broad cluster (>2 surfaces): same /mandrel-plan --seed-file path (may N>1)
|
|
154
154
|
});
|
|
155
155
|
```
|
|
156
156
|
|
|
@@ -159,16 +159,16 @@ footer landing in each seed body. For each untriaged item:
|
|
|
159
159
|
`createPlanSeed` — neither opens an Epic; both render a **redacted** plan
|
|
160
160
|
seed (redaction already ran at capture), **stamp the cluster's
|
|
161
161
|
`fingerprintFooter(sha)` verbatim into the seed body**, and chain
|
|
162
|
-
`/plan --seed-file <seed>`. Prefer one Story; split only under the
|
|
162
|
+
`/mandrel-plan --seed-file <seed>`. Prefer one Story; split only under the
|
|
163
163
|
default-single policy. A `file` disposition **never** opens a raw GitHub
|
|
164
|
-
Issue; only `defer` and `dismiss` skip the `/plan` handoff.
|
|
164
|
+
Issue; only `defer` and `dismiss` skip the `/mandrel-plan` handoff.
|
|
165
165
|
|
|
166
166
|
## The HITL write gate
|
|
167
167
|
|
|
168
168
|
Capture stays read-only precisely so every state change lands in Triage,
|
|
169
|
-
deliberately and confirmed. Any ticket-filing, seed write, `/plan` invocation,
|
|
169
|
+
deliberately and confirmed. Any ticket-filing, seed write, `/mandrel-plan` invocation,
|
|
170
170
|
or label mutation is a **write** — present the artifact, confirm each one with
|
|
171
171
|
the operator, and wait before it happens. The agent never files tickets,
|
|
172
172
|
promotes findings, or mutates a label autonomously. The plan→deliver hard stop
|
|
173
|
-
is preserved: each `/plan` chain pauses at its own HITL gates and never
|
|
173
|
+
is preserved: each `/mandrel-plan` chain pauses at its own HITL gates and never
|
|
174
174
|
auto-delivers.
|
|
@@ -14,7 +14,7 @@ into the wrong commit. Each Story runs in its own `git worktree` at
|
|
|
14
14
|
isolated per-Story. The main checkout stays quiet.
|
|
15
15
|
|
|
16
16
|
This document is the operator and reviewer reference. See
|
|
17
|
-
[`/deliver`](../deliver.md) and [`helpers/deliver-story`](deliver-story.md)
|
|
17
|
+
[`/mandrel-deliver`](../mandrel-deliver.md) and [`helpers/deliver-story`](deliver-story.md)
|
|
18
18
|
for the broader execution flow.
|
|
19
19
|
|
|
20
20
|
## Configuration
|
|
@@ -50,7 +50,7 @@ root, and shell-metacharacter injection in `root`.
|
|
|
50
50
|
| **Sweep** | Operator-driven (`WorktreeManager.sweepStaleLocks`) | Stale `*.lock` files under `.git/` (older than 5 min) are removed before GC. |
|
|
51
51
|
| **GC** | Operator-driven (`WorktreeManager.gc`) | Orphan `.worktrees/story-*` whose Stories are closed are reaped if clean. |
|
|
52
52
|
| **Force-drain** | Operator-driven (`drain-pending-cleanup.js`) | Retries `.worktrees/.pending-cleanup.json` (`git worktree remove` then `fs.rm`); Windows-only escalation enumerates user-mode handle holders and `taskkill`s them before re-trying. |
|
|
53
|
-
| **Ensure** | `single-story-init.js` (entry for `/deliver`) | `git worktree add .worktrees/story-<id>/` on the `story-<id>` branch. |
|
|
53
|
+
| **Ensure** | `single-story-init.js` (entry for `/mandrel-deliver`) | `git worktree add .worktrees/story-<id>/` on the `story-<id>` branch. |
|
|
54
54
|
| **Run** | During Story execution | Agent runs inside the worktree; HEAD/reflog activity is isolated. |
|
|
55
55
|
| **Reap** | After successful Story merge (in `single-story-close`) | `git worktree remove` — refuses to delete dirty trees or unmerged branches. |
|
|
56
56
|
|
|
@@ -85,13 +85,13 @@ epic-runner. The lifecycle surfaces that do run automatically are:
|
|
|
85
85
|
|
|
86
86
|
| Entry point | Script / caller | What it cleans |
|
|
87
87
|
| --------------------------------- | -------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |
|
|
88
|
-
| Story init (`/deliver <storyId>`) | `single-story-init.js` boot sweep (`sweepMergedStoryBranches`) | Merged/closed `story-*` branches (local + origin) from prior runs; it then creates only its own worktree. |
|
|
89
|
-
| Story close (`/deliver` close) | `single-story-close.js` worktree-reap phase (`WorktreeManager.reap`) | The per-Story worktree; on a Windows EBUSY-class lock the entry is deferred into `.worktrees/.pending-cleanup.json`. |
|
|
88
|
+
| Story init (`/mandrel-deliver <storyId>`) | `single-story-init.js` boot sweep (`sweepMergedStoryBranches`) | Merged/closed `story-*` branches (local + origin) from prior runs; it then creates only its own worktree. |
|
|
89
|
+
| Story close (`/mandrel-deliver` close) | `single-story-close.js` worktree-reap phase (`WorktreeManager.reap`) | The per-Story worktree; on a Windows EBUSY-class lock the entry is deferred into `.worktrees/.pending-cleanup.json`. |
|
|
90
90
|
| Drain pending-cleanup (operator) | `drain-pending-cleanup.js` (run directly — see below) | The pending-cleanup ledger, with optional Windows handle-holder escalation. This is the only path that drains the ledger. |
|
|
91
91
|
|
|
92
92
|
Operator takeaway: if worktrees or stale locks accumulate, run
|
|
93
93
|
`node .agents/scripts/drain-pending-cleanup.js` — nothing in the
|
|
94
|
-
`/plan` → `/deliver` loop force-sweeps or GCs on your behalf.
|
|
94
|
+
`/mandrel-plan` → `/mandrel-deliver` loop force-sweeps or GCs on your behalf.
|
|
95
95
|
|
|
96
96
|
## Draining the pending-cleanup ledger
|
|
97
97
|
|
|
@@ -297,6 +297,6 @@ Human reviewers should **keep using the main checkout** — not a worktree:
|
|
|
297
297
|
`git worktree remove --force <path>`. Confirm there is no uncommitted work
|
|
298
298
|
first.
|
|
299
299
|
- **Disable temporarily**: flip `enabled: false` in `.agentrc.json`. The next
|
|
300
|
-
`/deliver` skips worktree creation entirely.
|
|
300
|
+
`/mandrel-deliver` skips worktree creation entirely.
|
|
301
301
|
- **Inspect live worktrees**: `git worktree list --porcelain` on the main
|
|
302
302
|
checkout. Each block shows `worktree <path>` / `branch refs/heads/story-<id>`.
|
|
@@ -5,7 +5,7 @@ description:
|
|
|
5
5
|
deliver-story engine — story-<id> → PR → main.
|
|
6
6
|
---
|
|
7
7
|
|
|
8
|
-
# /deliver
|
|
8
|
+
# /mandrel-deliver
|
|
9
9
|
|
|
10
10
|
> **Lean spine.** Happy path + gate list. Sequencing, dispatch mechanics,
|
|
11
11
|
> intent phrases, ceremony and the epilogue live in on-demand
|
|
@@ -16,7 +16,7 @@ description:
|
|
|
16
16
|
|
|
17
17
|
## Role
|
|
18
18
|
|
|
19
|
-
One delivery door. `/deliver` owns input resolution, sequencing and the
|
|
19
|
+
One delivery door. `/mandrel-deliver` owns input resolution, sequencing and the
|
|
20
20
|
close-and-land tail; Stories are implemented via
|
|
21
21
|
[`helpers/deliver-story.md`](helpers/deliver-story.md).
|
|
22
22
|
|
|
@@ -32,11 +32,11 @@ you read:
|
|
|
32
32
|
|
|
33
33
|
| Invocation | Shape | Behavior |
|
|
34
34
|
| --- | --- | --- |
|
|
35
|
-
| `/deliver` | bare | List the open `agent::ready` Stories and ask which to deliver. Deliver nothing until answered. |
|
|
36
|
-
| `/deliver 4712` | ids | One Story via `helpers/deliver-story.md`, **inline in this session** — no `story-worker` spawn. |
|
|
37
|
-
| `/deliver 4712 4713 …` | ids | Resolve the set, sequence by the discovered graph via `stories-wave-tick.js`, dispatch sub-agents. |
|
|
38
|
-
| `/deliver 4712 - 4716` | ids | A **range** — every id in the inclusive span. |
|
|
39
|
-
| `/deliver add a --json flag to doctor` | prompt | Unplanned work: gate, author a receipt Story, land it — [`helpers/deliver-light.md`](helpers/deliver-light.md). |
|
|
35
|
+
| `/mandrel-deliver` | bare | List the open `agent::ready` Stories and ask which to deliver. Deliver nothing until answered. |
|
|
36
|
+
| `/mandrel-deliver 4712` | ids | One Story via `helpers/deliver-story.md`, **inline in this session** — no `story-worker` spawn. |
|
|
37
|
+
| `/mandrel-deliver 4712 4713 …` | ids | Resolve the set, sequence by the discovered graph via `stories-wave-tick.js`, dispatch sub-agents. |
|
|
38
|
+
| `/mandrel-deliver 4712 - 4716` | ids | A **range** — every id in the inclusive span. |
|
|
39
|
+
| `/mandrel-deliver add a --json flag to doctor` | prompt | Unplanned work: gate, author a receipt Story, land it — [`helpers/deliver-light.md`](helpers/deliver-light.md). |
|
|
40
40
|
|
|
41
41
|
**The discriminator is lexical and total.** An argument matching `^#?\d+$` is an
|
|
42
42
|
id, and `^#?\d+\s*[-–—]\s*#?\d+$` an inclusive **range** — pass one on as a
|
|
@@ -92,14 +92,10 @@ it to an operator or add it to an attended run.
|
|
|
92
92
|
- **0** — dispatch each `ready` id (already capped and overlap-free); an
|
|
93
93
|
empty `ready` with work in flight means "waiting", so keep looping;
|
|
94
94
|
`epilogueDue: true` means every Story is done — step 4.
|
|
95
|
-
- **2** — `cycleError
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
`blockedReason`, the protocol's HITL pause
|
|
100
|
-
([`instructions.md` § 1.J](../instructions.md)) — **stop the loop and
|
|
101
|
-
surface it; do not poll**, resuming once the operator unblocks it. Blocked
|
|
102
|
-
outranks a wedge, not a cycle.
|
|
95
|
+
- **2 / 3 / 4** — `cycleError` / `wedged` / `blocked`: stop the loop and
|
|
96
|
+
route per reference § Sequencing edge cases. **4** is the protocol's HITL
|
|
97
|
+
pause ([`instructions.md` § 1.J](../instructions.md)) — surface it and
|
|
98
|
+
wait for the operator; never poll.
|
|
103
99
|
|
|
104
100
|
4. **Close each hand-off** (§ Closing what the workers hand back), then, with
|
|
105
101
|
every Story landed, run the **per-run epilogue (N>1)**:
|
|
@@ -143,13 +139,13 @@ it): reference § Ceremony.
|
|
|
143
139
|
- **Land or block — never a silent local build** (digest § 2). Attended delivers
|
|
144
140
|
default to close-and-land (`delivery.routing.closeAndLand: true`); rest at
|
|
145
141
|
`agent::closing` only when a human owns it.
|
|
146
|
-
- **`/deliver` never plans.** Planned tickets come from [`/plan`](plan.md), and
|
|
147
|
-
an over-scope prompt **escalates and ends** — never invoke `/plan` in this
|
|
142
|
+
- **`/mandrel-deliver` never plans.** Planned tickets come from [`/mandrel-plan`](mandrel-plan.md), and
|
|
143
|
+
an over-scope prompt **escalates and ends** — never invoke `/mandrel-plan` in this
|
|
148
144
|
session to rescue it ([`helpers/deliver-light.md`](helpers/deliver-light.md)
|
|
149
145
|
§ Escalation is terminal).
|
|
150
146
|
|
|
151
147
|
## See also
|
|
152
148
|
|
|
153
|
-
[`/plan`](plan.md), [`helpers/deliver-story.md`](helpers/deliver-story.md) (the
|
|
149
|
+
[`/mandrel-plan`](mandrel-plan.md), [`helpers/deliver-story.md`](helpers/deliver-story.md) (the
|
|
154
150
|
engine), [`helpers/deliver-light.md`](helpers/deliver-light.md) (the unplanned
|
|
155
|
-
prompt path, shared with `/plan` Gate #1).
|
|
151
|
+
prompt path, shared with `/mandrel-plan` Gate #1).
|
|
@@ -5,7 +5,7 @@ description:
|
|
|
5
5
|
policy.
|
|
6
6
|
---
|
|
7
7
|
|
|
8
|
-
# /plan
|
|
8
|
+
# /mandrel-plan
|
|
9
9
|
|
|
10
10
|
> **Lean spine.** Happy path + gate list; edge-case detail lives on demand in
|
|
11
11
|
> [`helpers/plan-reference.md`](helpers/plan-reference.md).
|
|
@@ -18,11 +18,11 @@ it, act**:
|
|
|
18
18
|
|
|
19
19
|
| Invocation | Mode | Behavior |
|
|
20
20
|
| --- | --- | --- |
|
|
21
|
-
| `/plan` | ask | Ask what to plan; nothing runs first. |
|
|
22
|
-
| `/plan add a --json flag to doctor` | seed | Ideation from prose: interrogate → author **one Story by default** → persist. |
|
|
23
|
-
| `/plan temp/notes/idea.md` | seed-file | Same, from notes. An existing file is a path, not prose. |
|
|
24
|
-
| `/plan 4712[,4713…]` | tickets | Fetch issue(s), analyze into proper Stories (prefer N=1 rewrite). |
|
|
25
|
-
| `/plan 4712`, already delivered | amends | Amend a shipped Story from a **delta envelope**, not a re-interrogation. |
|
|
21
|
+
| `/mandrel-plan` | ask | Ask what to plan; nothing runs first. |
|
|
22
|
+
| `/mandrel-plan add a --json flag to doctor` | seed | Ideation from prose: interrogate → author **one Story by default** → persist. |
|
|
23
|
+
| `/mandrel-plan temp/notes/idea.md` | seed-file | Same, from notes. An existing file is a path, not prose. |
|
|
24
|
+
| `/mandrel-plan 4712[,4713…]` | tickets | Fetch issue(s), analyze into proper Stories (prefer N=1 rewrite). |
|
|
25
|
+
| `/mandrel-plan 4712`, already delivered | amends | Amend a shipped Story from a **delta envelope**, not a re-interrogation. |
|
|
26
26
|
|
|
27
27
|
**Resolving a bare id.** Read live state rather than asking: `agent::done` can
|
|
28
28
|
only be amended, an open unplanned issue can only be planned. **Announce the
|
|
@@ -156,14 +156,14 @@ JSON. Tickets mode also comments on and closes each source id
|
|
|
156
156
|
|
|
157
157
|
## Constraints
|
|
158
158
|
|
|
159
|
-
- `/plan` starts delivery **only** through a confirmed Gate #1 light route —
|
|
160
|
-
never off its own authored Stories, which land via [`/deliver`](deliver.md).
|
|
159
|
+
- `/mandrel-plan` starts delivery **only** through a confirmed Gate #1 light route —
|
|
160
|
+
never off its own authored Stories, which land via [`/mandrel-deliver`](mandrel-deliver.md).
|
|
161
161
|
- Duplicate search targets open Stories (`type::story`), not Epics; and
|
|
162
162
|
deterministic gates still fail closed under `--yes`.
|
|
163
163
|
|
|
164
164
|
## See also
|
|
165
165
|
|
|
166
|
-
[`/deliver`](deliver.md), [`/audit-to-stories`](audit-to-stories.md),
|
|
166
|
+
[`/mandrel-deliver`](mandrel-deliver.md), [`/audit-to-stories`](audit-to-stories.md),
|
|
167
167
|
[`helpers/plan-reference.md`](helpers/plan-reference.md) (on-demand detail),
|
|
168
168
|
[`core/scope-triage`](../skills/core/scope-triage/SKILL.md) — optional
|
|
169
169
|
split-advisory notes only (no routing verdict).
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
description: >-
|
|
3
3
|
Attended consolidation pass over this project's agent memory pool — merge
|
|
4
4
|
duplicates, verify claims against the current tree, prune with operator
|
|
5
|
-
confirmation, rewrite the index, and stamp the pool so the /plan advisory
|
|
5
|
+
confirmation, rewrite the index, and stamp the pool so the /mandrel-plan advisory
|
|
6
6
|
goes quiet.
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -96,7 +96,7 @@ Then write the receipt to `.consolidation-stamp.json` in the pool root:
|
|
|
96
96
|
{ "lastConsolidatedAt": "<ISO-8601 timestamp>" }
|
|
97
97
|
```
|
|
98
98
|
|
|
99
|
-
The `/plan` Phase 0 advisory reads this file; until it is written, the nudge
|
|
99
|
+
The `/mandrel-plan` Phase 0 advisory reads this file; until it is written, the nudge
|
|
100
100
|
keeps firing. Write it **only** after Gate #2 — the stamp asserts an operator
|
|
101
101
|
reviewed the pass, so writing it early makes it a lie.
|
|
102
102
|
|
|
@@ -112,5 +112,5 @@ Close with counts: entries read, corrected, merged, pruned, and the new total.
|
|
|
112
112
|
|
|
113
113
|
## See also
|
|
114
114
|
|
|
115
|
-
[`/plan`](plan.md) (surfaces the advisory at its Gate #1),
|
|
116
|
-
[`/deliver`](deliver.md) (point-of-write corrections as work lands).
|
|
115
|
+
[`/mandrel-plan`](mandrel-plan.md) (surfaces the advisory at its Gate #1),
|
|
116
|
+
[`/mandrel-deliver`](mandrel-deliver.md) (point-of-write corrections as work lands).
|
|
@@ -13,7 +13,7 @@ active runs" says nothing about layout, density, or interaction, so delivery
|
|
|
13
13
|
resolves those by taste. `/prototype` puts a reviewable artifact in front of the
|
|
14
14
|
operator before the criteria are written.
|
|
15
15
|
|
|
16
|
-
**Operator-invoked only.** `/plan` may report that a plan touches UI and that
|
|
16
|
+
**Operator-invoked only.** `/mandrel-plan` may report that a plan touches UI and that
|
|
17
17
|
this command exists; it must never run it. No workflow, gate, or script invokes
|
|
18
18
|
`/prototype` — the whole design rests on the operator asking for it.
|
|
19
19
|
|
|
@@ -89,7 +89,7 @@ documentation-freshness gate already carries that failure mode.
|
|
|
89
89
|
- **One file, under the temp tree.** Never a second artifact, never outside the
|
|
90
90
|
gitignored workspace-root temp tree, and never a committed prototype
|
|
91
91
|
directory by default.
|
|
92
|
-
- **Never invoked automatically.** `/plan` records the offer and proceeds with
|
|
92
|
+
- **Never invoked automatically.** `/mandrel-plan` records the offer and proceeds with
|
|
93
93
|
planning; no workflow, gate, or script may call this command.
|
|
94
94
|
- **Read-only over the codebase.** The prototype file is the only write. Do not
|
|
95
95
|
edit application source, tokens, or components to make a prototype render.
|
|
@@ -100,5 +100,5 @@ documentation-freshness gate already carries that failure mode.
|
|
|
100
100
|
|
|
101
101
|
- [`/audit-ux-ui`](audit-ux-ui.md) — the same design-system SSOT discovery,
|
|
102
102
|
applied as a review lens after the UI ships.
|
|
103
|
-
- [`/plan`](plan.md) — where the advisory `complexitySignals.uiSurface` offer
|
|
103
|
+
- [`/mandrel-plan`](mandrel-plan.md) — where the advisory `complexitySignals.uiSurface` offer
|
|
104
104
|
surfaces. It names this command; it never runs it.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
description: Human-led QA assist loop — set up, then ride a rolling multi-observation intake session. The operator reports observations in any order; the agent enriches each (repro + root-cause file:line + coverage verdict for bugs; analysis + options + recommendation for enhancements), asks clarifying questions only when ambiguous, and appends a redacted ledger item — recording, never planning — to a persistent, resumable session under temp/qa/. Only when the operator says they are done does it review the full ledger and hand off to /plan.
|
|
2
|
+
description: Human-led QA assist loop — set up, then ride a rolling multi-observation intake session. The operator reports observations in any order; the agent enriches each (repro + root-cause file:line + coverage verdict for bugs; analysis + options + recommendation for enhancements), asks clarifying questions only when ambiguous, and appends a redacted ledger item — recording, never planning — to a persistent, resumable session under temp/qa/. Only when the operator says they are done does it review the full ledger and hand off to /mandrel-plan.
|
|
3
3
|
---
|
|
4
4
|
|
|
5
5
|
# /qa-assist
|
|
@@ -21,7 +21,7 @@ high-quality, triage-ready ledger. The session has four movements:
|
|
|
21
21
|
a final review of the **entire** ledger and asks any last clarifying
|
|
22
22
|
questions.
|
|
23
23
|
4. **Triage & Plan** (Phase 4) — only then does it route the full ledger through
|
|
24
|
-
[`/plan`](plan.md) to generate Stories.
|
|
24
|
+
[`/mandrel-plan`](mandrel-plan.md) to generate Stories.
|
|
25
25
|
|
|
26
26
|
Unlike [`/qa-explore`](qa-explore.md) (where the *agent* drives open-ended
|
|
27
27
|
exploration of a named surface), `/qa-assist` is **human-led**: the human owns
|
|
@@ -89,12 +89,12 @@ rolling loop stays fluid:
|
|
|
89
89
|
to **ask clarifying questions when the observation is ambiguous**. After each
|
|
90
90
|
append it **echoes the recorded item** for correction, then **loops back** for
|
|
91
91
|
the next observation. It does **not** triage, route, file tickets, or invoke
|
|
92
|
-
`/plan` during intake.
|
|
92
|
+
`/mandrel-plan` during intake.
|
|
93
93
|
- **Two things always require explicit operator confirmation** (the HITL write
|
|
94
94
|
gate in [`helpers/qa-core.md`](helpers/qa-core.md)). First, the session-level
|
|
95
95
|
transition into **Phase 4 — Triage & Plan** — the operator must say they are
|
|
96
96
|
done. Second, **every write that leaves the local ledger** — filing a ticket,
|
|
97
|
-
invoking `/plan`, or mutating a label. Present the artifact, ask, and wait.
|
|
97
|
+
invoking `/mandrel-plan`, or mutating a label. Present the artifact, ask, and wait.
|
|
98
98
|
|
|
99
99
|
In short: appending to the rolling ledger is the natural product of intake and
|
|
100
100
|
needs no gate beyond the echo-back; **planning and anything that leaves the
|
|
@@ -198,7 +198,7 @@ every decision to the shared helpers; never re-derive them in prose.
|
|
|
198
198
|
## Phase 3 — Record (per observation), then loop
|
|
199
199
|
|
|
200
200
|
Goal: persist the enriched finding to the rolling ledger and **return to
|
|
201
|
-
intake**. **No triage, routing, ticket-filing, or `/plan` happens here** — that
|
|
201
|
+
intake**. **No triage, routing, ticket-filing, or `/mandrel-plan` happens here** — that
|
|
202
202
|
is Phase 4, and only after the operator says they are done.
|
|
203
203
|
|
|
204
204
|
1. **Append a `QaLedgerItem`** to the ledger (shape per
|
|
@@ -232,17 +232,17 @@ its transition is **explicitly operator-gated**.
|
|
|
232
232
|
2. **Triage the ledger** through the shared classify → route → disposition →
|
|
233
233
|
promote procedure in [`helpers/qa-core.md`](helpers/qa-core.md): dedup/route
|
|
234
234
|
each `file` finding against open + closed Issues, then promote the
|
|
235
|
-
`file`-dispositioned findings through `promoteFindings` → `/plan` (never a raw
|
|
235
|
+
`file`-dispositioned findings through `promoteFindings` → `/mandrel-plan` (never a raw
|
|
236
236
|
Issue), stamping each cluster's `fingerprintFooter(sha)` into the seed.
|
|
237
237
|
`defer` carries an item forward as backlog; `dismiss` marks it non-actionable.
|
|
238
238
|
3. **Gate:** the move into this phase, and every write inside it (seed write,
|
|
239
|
-
`/plan` invocation, ticket-filing, label mutation), is **operator-gated** —
|
|
239
|
+
`/mandrel-plan` invocation, ticket-filing, label mutation), is **operator-gated** —
|
|
240
240
|
confirm each one. The plan→deliver hard stop is preserved; redaction has
|
|
241
241
|
already run, so nothing unredacted reaches disk or GitHub.
|
|
242
242
|
|
|
243
243
|
After planning, summarize: the findings recorded, the route/promotion decisions
|
|
244
244
|
(`new`/`update-existing`/`duplicate`/`regression-of-closed`), whether each
|
|
245
|
-
cluster became a Story via `/plan --seed-file`, and any `defer` backlog a
|
|
245
|
+
cluster became a Story via `/mandrel-plan --seed-file`, and any `defer` backlog a
|
|
246
246
|
resumed session will pick up.
|
|
247
247
|
|
|
248
248
|
---
|
|
@@ -259,7 +259,7 @@ the `/qa-assist`-specific deltas are:
|
|
|
259
259
|
records each. **Never invent an observation**; ask clarifying questions only
|
|
260
260
|
when one is ambiguous, batched across the dump.
|
|
261
261
|
- **Record during intake; plan only on "done".** Phases 1–3 enrich, append, and
|
|
262
|
-
loop — never triage, route, file, or invoke `/plan`. All of that is Phase 4,
|
|
262
|
+
loop — never triage, route, file, or invoke `/mandrel-plan`. All of that is Phase 4,
|
|
263
263
|
entered only on explicit operator confirmation that testing is done.
|
|
264
264
|
- **Light intake gate, firm boundary gate.** Intake → Enrich → Record is fluid
|
|
265
265
|
(echo-back, no ceremony); the move into Phase 4 and every write that leaves the
|
|
@@ -275,11 +275,11 @@ the `/qa-assist`-specific deltas are:
|
|
|
275
275
|
|
|
276
276
|
## See also
|
|
277
277
|
|
|
278
|
-
- [`/plan`](plan.md) — the planning pipeline `/qa-assist` chains into in Phase 4.
|
|
278
|
+
- [`/mandrel-plan`](mandrel-plan.md) — the planning pipeline `/qa-assist` chains into in Phase 4.
|
|
279
279
|
The plan→deliver hard stop is preserved across the handoff.
|
|
280
280
|
- [`/qa-explore`](qa-explore.md) — the agent-led sibling that drives a named
|
|
281
|
-
surface and triages through the same `/plan` handoff.
|
|
281
|
+
surface and triages through the same `/mandrel-plan` handoff.
|
|
282
282
|
- [`/audit-to-stories`](audit-to-stories.md) — the precedent for the
|
|
283
|
-
findings → `/plan` handoff and the shared fingerprint-footer dedup contract.
|
|
283
|
+
findings → `/mandrel-plan` handoff and the shared fingerprint-footer dedup contract.
|
|
284
284
|
- [`helpers/qa-core.md`](helpers/qa-core.md) — the shared contract/session/
|
|
285
285
|
redaction/QaLedgerItem/triage/HITL core.
|