mandrel 1.59.0 → 1.60.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (240) hide show
  1. package/.agents/README.md +14 -14
  2. package/.agents/docs/SDLC.md +129 -134
  3. package/.agents/docs/configuration.md +16 -16
  4. package/.agents/docs/workflows.md +6 -8
  5. package/.agents/instructions.md +12 -11
  6. package/.agents/personas/architect.md +1 -1
  7. package/.agents/personas/product.md +1 -1
  8. package/.agents/personas/project-manager.md +14 -14
  9. package/.agents/personas/technical-writer.md +1 -1
  10. package/.agents/rules/changelog-style.md +5 -5
  11. package/.agents/rules/git-conventions.md +3 -3
  12. package/.agents/schemas/agentrc.schema.json +3 -3
  13. package/.agents/schemas/dispatch-manifest.json +4 -4
  14. package/.agents/schemas/epic-spec.schema.json +15 -45
  15. package/.agents/schemas/lifecycle/README.md +1 -1
  16. package/.agents/schemas/lifecycle/story.dispatch.end.schema.json +1 -1
  17. package/.agents/schemas/lifecycle/story.dispatch.start.schema.json +1 -1
  18. package/.agents/schemas/lifecycle/story.heartbeat.schema.json +1 -1
  19. package/.agents/schemas/validation-evidence.schema.json +1 -1
  20. package/.agents/scripts/README.md +1 -1
  21. package/.agents/scripts/acceptance-eval.js +1 -1
  22. package/.agents/scripts/acceptance-spec-reconciler.js +2 -2
  23. package/.agents/scripts/analyze-execution.js +2 -2
  24. package/.agents/scripts/audit-to-stories.js +1 -1
  25. package/.agents/scripts/check-doc-links.js +2 -3
  26. package/.agents/scripts/diagnose-friction.js +1 -1
  27. package/.agents/scripts/dispatcher.js +2 -2
  28. package/.agents/scripts/drain-pending-cleanup.js +1 -1
  29. package/.agents/scripts/epic-audit-prepare.js +3 -3
  30. package/.agents/scripts/epic-deliver-note-intervention.js +2 -2
  31. package/.agents/scripts/epic-deliver-preflight.js +6 -6
  32. package/.agents/scripts/epic-deliver-prepare.js +1 -1
  33. package/.agents/scripts/epic-execute-record-wave.js +4 -4
  34. package/.agents/scripts/epic-plan-healthcheck.js +6 -10
  35. package/.agents/scripts/epic-plan-spec-validate.js +1 -1
  36. package/.agents/scripts/epic-reconcile.js +11 -29
  37. package/.agents/scripts/evidence-gate.js +1 -1
  38. package/.agents/scripts/generate-workflows-doc.js +1 -1
  39. package/.agents/scripts/hierarchy-gate.js +7 -11
  40. package/.agents/scripts/lib/ITicketingProvider.js +1 -1
  41. package/.agents/scripts/lib/audit-suite/selector.js +1 -1
  42. package/.agents/scripts/lib/audit-to-stories/seed-epic-from-findings.js +2 -2
  43. package/.agents/scripts/lib/baseline-snapshot.js +7 -7
  44. package/.agents/scripts/lib/bdd-runner-detect.js +1 -1
  45. package/.agents/scripts/lib/bdd-scenario-scanner.js +3 -3
  46. package/.agents/scripts/lib/bootstrap/baselines-layout-migration.js +1 -1
  47. package/.agents/scripts/lib/bootstrap/branch-protection.js +1 -1
  48. package/.agents/scripts/lib/bootstrap/ci-workflow-template.js +1 -1
  49. package/.agents/scripts/lib/bootstrap/commit-push.js +2 -2
  50. package/.agents/scripts/lib/codebase-snapshot.js +1 -1
  51. package/.agents/scripts/lib/config/explain.js +1 -1
  52. package/.agents/scripts/lib/config/runners.js +2 -2
  53. package/.agents/scripts/lib/config/runtime.js +1 -1
  54. package/.agents/scripts/lib/config/temp-paths.js +2 -2
  55. package/.agents/scripts/lib/config-settings-schema-delivery.js +2 -2
  56. package/.agents/scripts/lib/config-settings-schema-quality.js +1 -1
  57. package/.agents/scripts/lib/config-settings-schema.js +3 -3
  58. package/.agents/scripts/lib/duplicate-search.js +1 -1
  59. package/.agents/scripts/lib/dynamic-workflow/capability.js +1 -1
  60. package/.agents/scripts/lib/epic-plan-clarity.js +1 -1
  61. package/.agents/scripts/lib/epic-plan-ideation.js +1 -1
  62. package/.agents/scripts/lib/feedback-loop/memory-freshness.js +1 -1
  63. package/.agents/scripts/lib/feedback-loop/prior-feedback-fetcher.js +1 -1
  64. package/.agents/scripts/lib/findings/classify-finding.js +1 -1
  65. package/.agents/scripts/lib/findings/promote-finding.js +10 -10
  66. package/.agents/scripts/lib/label-constants.js +3 -4
  67. package/.agents/scripts/lib/label-taxonomy.js +3 -8
  68. package/.agents/scripts/lib/orchestration/acceptance-eval-decision.js +1 -1
  69. package/.agents/scripts/lib/orchestration/code-review.js +5 -5
  70. package/.agents/scripts/lib/orchestration/context-hydration-engine.js +8 -9
  71. package/.agents/scripts/lib/orchestration/dependency-analyzer.js +3 -3
  72. package/.agents/scripts/lib/orchestration/detectors-phase.js +2 -2
  73. package/.agents/scripts/lib/orchestration/dispatch-engine.js +30 -38
  74. package/.agents/scripts/lib/orchestration/dispatch-pipeline.js +9 -25
  75. package/.agents/scripts/lib/orchestration/epic-cleanup.js +1 -1
  76. package/.agents/scripts/lib/orchestration/epic-deliver-lease-guard.js +8 -8
  77. package/.agents/scripts/lib/orchestration/epic-plan-decompose/phases/creation.js +1 -1
  78. package/.agents/scripts/lib/orchestration/epic-plan-decompose/phases/dag.js +7 -21
  79. package/.agents/scripts/lib/orchestration/epic-plan-decompose/phases/diagnostics.js +3 -3
  80. package/.agents/scripts/lib/orchestration/epic-plan-lease-guard.js +26 -13
  81. package/.agents/scripts/lib/orchestration/epic-plan-spec/phases/plan-epic.js +1 -1
  82. package/.agents/scripts/lib/orchestration/epic-plan-spec/phases/prompts.js +1 -1
  83. package/.agents/scripts/lib/orchestration/epic-plan-spec/phases/run-spec-phase.js +2 -2
  84. package/.agents/scripts/lib/orchestration/epic-plan-state-store.js +1 -1
  85. package/.agents/scripts/lib/orchestration/epic-run-state-store.js +3 -3
  86. package/.agents/scripts/lib/orchestration/epic-runner/concurrency-gate.js +4 -4
  87. package/.agents/scripts/lib/orchestration/epic-runner/deliver-phases.js +3 -3
  88. package/.agents/scripts/lib/orchestration/epic-runner/phases/build-wave-dag.js +6 -21
  89. package/.agents/scripts/lib/orchestration/epic-runner/phases/snapshot.js +7 -7
  90. package/.agents/scripts/lib/orchestration/epic-runner/progress-reporter/composition.js +1 -1
  91. package/.agents/scripts/lib/orchestration/epic-runner/progress-reporter/signals.js +2 -2
  92. package/.agents/scripts/lib/orchestration/epic-runner/progress-reporter/transport.js +4 -4
  93. package/.agents/scripts/lib/orchestration/epic-runner/story-launcher.js +4 -4
  94. package/.agents/scripts/lib/orchestration/epic-runner/story-run-progress-writer.js +8 -8
  95. package/.agents/scripts/lib/orchestration/epic-runner/sub-agent-return.js +4 -4
  96. package/.agents/scripts/lib/orchestration/epic-spec-reconciler-apply.js +7 -15
  97. package/.agents/scripts/lib/orchestration/epic-spec-reconciler-diff.js +72 -41
  98. package/.agents/scripts/lib/orchestration/epic-spec-reconciler-ops.js +2 -4
  99. package/.agents/scripts/lib/orchestration/file-assumptions.js +2 -2
  100. package/.agents/scripts/lib/orchestration/finalize/close-planning-tickets.js +1 -1
  101. package/.agents/scripts/lib/orchestration/finalize/open-or-locate-pr.js +2 -2
  102. package/.agents/scripts/lib/orchestration/finalize/sanitize-skip-ci.js +1 -1
  103. package/.agents/scripts/lib/orchestration/lease-guard-shared.js +3 -3
  104. package/.agents/scripts/lib/orchestration/lifecycle/emit-story-dispatch-end.js +1 -1
  105. package/.agents/scripts/lib/orchestration/lifecycle/emit-story-heartbeat.js +1 -1
  106. package/.agents/scripts/lib/orchestration/lifecycle/listeners/README.md +1 -1
  107. package/.agents/scripts/lib/orchestration/lifecycle/listeners/automerge-armer.js +1 -1
  108. package/.agents/scripts/lib/orchestration/lifecycle/listeners/automerge-predicate.js +1 -1
  109. package/.agents/scripts/lib/orchestration/lifecycle/listeners/branch-cleaner.js +1 -1
  110. package/.agents/scripts/lib/orchestration/lifecycle/listeners/finalizer.js +1 -1
  111. package/.agents/scripts/lib/orchestration/lifecycle/listeners/index.js +1 -1
  112. package/.agents/scripts/lib/orchestration/lifecycle/listeners/merge-watcher.js +1 -1
  113. package/.agents/scripts/lib/orchestration/lifecycle/listeners/notify-dispatcher.js +1 -1
  114. package/.agents/scripts/lib/orchestration/lifecycle/listeners/watcher.js +1 -1
  115. package/.agents/scripts/lib/orchestration/manifest-builder.js +5 -5
  116. package/.agents/scripts/lib/orchestration/parked-follow-ons.js +2 -2
  117. package/.agents/scripts/lib/orchestration/plan-runner/plan-router.js +5 -5
  118. package/.agents/scripts/lib/orchestration/post-merge/phases/ticket-closure.js +3 -3
  119. package/.agents/scripts/lib/orchestration/preflight-cache.js +1 -1
  120. package/.agents/scripts/lib/orchestration/recurring-failure-detector.js +1 -1
  121. package/.agents/scripts/lib/orchestration/retro/phases/compose-body.js +1 -1
  122. package/.agents/scripts/lib/orchestration/retro/phases/gather-signals.js +2 -2
  123. package/.agents/scripts/lib/orchestration/retro-runner.js +3 -3
  124. package/.agents/scripts/lib/orchestration/review-depth.js +1 -1
  125. package/.agents/scripts/lib/orchestration/single-story-close/phases/wrong-tree-guard.js +1 -1
  126. package/.agents/scripts/lib/orchestration/spec-freshness.js +1 -1
  127. package/.agents/scripts/lib/orchestration/spec-renderer.js +36 -73
  128. package/.agents/scripts/lib/orchestration/spec-section-validator.js +1 -1
  129. package/.agents/scripts/lib/orchestration/story-close/baseline-friction-body.js +1 -1
  130. package/.agents/scripts/lib/orchestration/story-close/phases/locked-pipeline.js +2 -2
  131. package/.agents/scripts/lib/orchestration/task-body-validator.js +6 -6
  132. package/.agents/scripts/lib/orchestration/ticket-lease.js +1 -1
  133. package/.agents/scripts/lib/orchestration/ticket-validator-conflicts.js +2 -2
  134. package/.agents/scripts/lib/orchestration/ticket-validator-sizing.js +1 -10
  135. package/.agents/scripts/lib/orchestration/ticket-validator.js +25 -70
  136. package/.agents/scripts/lib/orchestration/ticketing/bulk.js +5 -12
  137. package/.agents/scripts/lib/orchestration/ticketing/reads.js +8 -8
  138. package/.agents/scripts/lib/orchestration/ticketing/state.js +3 -3
  139. package/.agents/scripts/lib/orchestration/wave-record-notifications.js +2 -2
  140. package/.agents/scripts/lib/orchestration/wave-record-projection.js +1 -1
  141. package/.agents/scripts/lib/plan-phase-cleanup.js +1 -1
  142. package/.agents/scripts/lib/preflight-runner.js +1 -1
  143. package/.agents/scripts/lib/presentation/dispatch-manifest-render.js +4 -5
  144. package/.agents/scripts/lib/presentation/manifest-builder.js +28 -34
  145. package/.agents/scripts/lib/presentation/manifest-formatter.js +3 -4
  146. package/.agents/scripts/lib/presentation/manifest-helpers.js +1 -1
  147. package/.agents/scripts/lib/presentation/manifest-procedures.js +4 -4
  148. package/.agents/scripts/lib/presentation/manifest-render-waves.js +4 -23
  149. package/.agents/scripts/lib/presentation/manifest-renderer.js +1 -1
  150. package/.agents/scripts/lib/presentation/manifest-story-views.js +2 -11
  151. package/.agents/scripts/lib/signals/schema.js +1 -1
  152. package/.agents/scripts/lib/spec/index.js +1 -1
  153. package/.agents/scripts/lib/spec/loader.js +2 -2
  154. package/.agents/scripts/lib/spec/state.js +7 -16
  155. package/.agents/scripts/lib/story-init/context-resolver.js +3 -3
  156. package/.agents/scripts/lib/story-init/state-transitioner.js +2 -2
  157. package/.agents/scripts/lib/story-init/task-graph-builder.js +7 -7
  158. package/.agents/scripts/lib/story-lifecycle.js +8 -8
  159. package/.agents/scripts/lib/story-plan.js +1 -1
  160. package/.agents/scripts/lib/templates/decomposer-prompts.js +59 -52
  161. package/.agents/scripts/lib/wave-runner/tick.js +1 -1
  162. package/.agents/scripts/lifecycle-emit-story-dispatch.js +1 -1
  163. package/.agents/scripts/lifecycle-emit.js +1 -1
  164. package/.agents/scripts/providers/github/board-add.js +1 -1
  165. package/.agents/scripts/providers/github/errors.js +1 -1
  166. package/.agents/scripts/providers/github/mappers.js +2 -2
  167. package/.agents/scripts/providers/github/tickets.js +4 -4
  168. package/.agents/scripts/resync-status-column.js +1 -1
  169. package/.agents/scripts/retro-run.js +2 -2
  170. package/.agents/scripts/run-lint.js +1 -1
  171. package/.agents/scripts/single-story-init.js +1 -1
  172. package/.agents/scripts/stories-wave-tick.js +5 -5
  173. package/.agents/scripts/story-close.js +1 -1
  174. package/.agents/scripts/story-init.js +13 -16
  175. package/.agents/scripts/story-phase.js +5 -5
  176. package/.agents/scripts/story-plan.js +3 -3
  177. package/.agents/scripts/sync-branch-from-base.js +1 -1
  178. package/.agents/scripts/validate-docs-freshness.js +1 -1
  179. package/.agents/scripts/wave-tick.js +1 -1
  180. package/.agents/skills/core/analyze-execution/SKILL.md +2 -2
  181. package/.agents/skills/core/epic-plan-consolidate/SKILL.md +21 -26
  182. package/.agents/skills/core/epic-plan-decompose-author/SKILL.md +23 -56
  183. package/.agents/skills/core/epic-plan-spec-author/SKILL.md +4 -4
  184. package/.agents/skills/core/hydrate-context/SKILL.md +2 -2
  185. package/.agents/skills/core/idea-refinement/SKILL.md +4 -4
  186. package/.agents/skills/core/knowledge-transfer/SKILL.md +2 -2
  187. package/.agents/skills/core/planning-and-task-breakdown/SKILL.md +1 -1
  188. package/.agents/skills/core/scope-triage/SKILL.md +9 -10
  189. package/.agents/skills/core/using-agent-skills/SKILL.md +1 -1
  190. package/.agents/skills/skills.index.json +7 -7
  191. package/.agents/templates/agent-protocol.md +2 -2
  192. package/.agents/workflows/agents-update.md +2 -2
  193. package/.agents/workflows/audit-architecture.md +2 -2
  194. package/.agents/workflows/audit-clean-code.md +2 -2
  195. package/.agents/workflows/audit-dependencies.md +1 -1
  196. package/.agents/workflows/audit-devops.md +1 -1
  197. package/.agents/workflows/audit-documentation.md +2 -2
  198. package/.agents/workflows/audit-lighthouse.md +1 -1
  199. package/.agents/workflows/audit-performance.md +2 -2
  200. package/.agents/workflows/audit-privacy.md +1 -1
  201. package/.agents/workflows/audit-quality.md +2 -2
  202. package/.agents/workflows/audit-security.md +2 -2
  203. package/.agents/workflows/audit-seo.md +1 -1
  204. package/.agents/workflows/audit-sre.md +1 -1
  205. package/.agents/workflows/audit-to-stories.md +10 -10
  206. package/.agents/workflows/audit-ux-ui.md +1 -1
  207. package/.agents/workflows/deliver.md +85 -0
  208. package/.agents/workflows/explain.md +3 -3
  209. package/.agents/workflows/git-merge-pr.md +1 -1
  210. package/.agents/workflows/git-pr-all.md +13 -10
  211. package/.agents/workflows/git-push.md +6 -3
  212. package/.agents/workflows/helpers/_merge-conflict-template.md +1 -1
  213. package/.agents/workflows/helpers/acceptance-self-eval.md +1 -1
  214. package/.agents/workflows/helpers/code-review.md +5 -5
  215. package/.agents/workflows/{epic-deliver.md → helpers/deliver-epic.md} +43 -43
  216. package/.agents/workflows/{story-deliver.md → helpers/deliver-stories.md} +25 -25
  217. package/.agents/workflows/helpers/diagnose.md +1 -1
  218. package/.agents/workflows/helpers/epic-audit.md +6 -6
  219. package/.agents/workflows/helpers/epic-deliver-story.md +13 -13
  220. package/.agents/workflows/helpers/epic-plan-decompose.md +23 -23
  221. package/.agents/workflows/helpers/epic-plan-spec.md +6 -6
  222. package/.agents/workflows/helpers/epic-testing.md +3 -3
  223. package/.agents/workflows/helpers/parallel-tooling.md +1 -1
  224. package/.agents/workflows/{epic-plan.md → helpers/plan-epic.md} +84 -84
  225. package/.agents/workflows/{story-plan.md → helpers/plan-story.md} +43 -43
  226. package/.agents/workflows/helpers/signals.md +1 -1
  227. package/.agents/workflows/helpers/single-story-deliver.md +11 -11
  228. package/.agents/workflows/helpers/worktree-lifecycle.md +18 -18
  229. package/.agents/workflows/onboard.md +17 -17
  230. package/.agents/workflows/plan.md +89 -0
  231. package/.agents/workflows/qa-explore.md +1 -1
  232. package/.agents/workflows/qa-run-harness.md +1 -1
  233. package/README.md +4 -12
  234. package/docs/CHANGELOG.md +1149 -0
  235. package/lib/cli/__tests__/update-changelog-surface.test.js +357 -0
  236. package/lib/cli/__tests__/update-reexec.test.js +513 -0
  237. package/lib/cli/init.js +31 -29
  238. package/lib/cli/update.js +413 -52
  239. package/package.json +2 -1
  240. package/.agents/scripts/lib/orchestration/reconciler.js +0 -137
@@ -6,46 +6,46 @@ description:
6
6
  /single-story-deliver.
7
7
  ---
8
8
 
9
- # /story-plan
9
+ # helpers/plan-story — standalone-Story planning path (invoked by /plan)
10
10
 
11
11
  ## Overview
12
12
 
13
- `/story-plan` is the standalone counterpart to
14
- [`/epic-plan`](epic-plan.md) for Stories that are **not** attached to an
13
+ `/plan` is the standalone counterpart to
14
+ [`/plan`](plan-epic.md) for Stories that are **not** attached to an
15
15
  Epic. It closes the gap between "one-line idea" and "well-formed
16
- standalone Story body ready for [`/single-story-deliver`](helpers/single-story-deliver.md)"
16
+ standalone Story body ready for [`/single-story-deliver`](single-story-deliver.md)"
17
17
  using the same `host LLM authors + Node wrapper persists` split as
18
- `/epic-plan`.
18
+ `/plan`.
19
19
 
20
20
  ```text
21
- /story-plan --idea "<seed>"
21
+ /plan --idea "<seed>"
22
22
  → story-plan.js --emit-context (envelope: seed, template, dup candidates)
23
23
  → host LLM authors a draft Story body (in chat, using the envelope)
24
24
  → operator confirms (HITL)
25
25
  → story-plan.js --body <file> (validate, gh issue create)
26
- → "Next: /single-story-deliver <id>"
26
+ → "Next: /deliver <id>"
27
27
  ```
28
28
 
29
- **When to use `/story-plan` vs. `/epic-plan` Phase 8:**
29
+ **The two paths of `/plan` when each applies:**
30
30
 
31
- | Trait | `/story-plan` | `/epic-plan` Phase 8 |
31
+ | Trait | Standalone-Story path (this helper) | Epic decomposition path (`helpers/plan-epic.md`) |
32
32
  | -------------------- | ------------------------------------------ | -------------------------------------------- |
33
- | Output | One standalone Story Issue | Decomposed Feature/Story/Task hierarchy |
33
+ | Output | One standalone Story Issue | Epic with child Stories |
34
34
  | Parent Epic | None (no `Epic: #N` in body) | Required |
35
- | Downstream workflow | `/single-story-deliver` | `/story-deliver` (per Story) |
36
- | Replan surface | Out of scope (recreate manually if needed) | `/epic-plan --replan` regenerates everything |
37
- | Inbound route | Direct, **or** an `/epic-plan` Phase 1.5 scope-triage handoff | Direct (`<epicId>` or `--idea`) |
38
- | Outbound route | Phase 2 may **escalate** an epic-sized draft to `/epic-plan --idea` (scope-triage handoff) | n/a — `/epic-plan` is already the Epic tier |
35
+ | Downstream workflow | `/deliver <storyId>` | `/deliver <epicId>` |
36
+ | Replan surface | Out of scope (recreate manually if needed) | `/plan <epicId> --force` regenerates the backlog |
37
+ | Inbound route | `--idea` with a `story` triage verdict, `--body`, **or** a scope-triage handoff from the Epic path | Direct (`<epicId>`, or `--idea` with an `epic` verdict) |
38
+ | Outbound route | Phase 2 may **escalate** an epic-sized draft to the Epic path (internal branch switch) | The story-sized advisory may **convert** a one-Story Epic to this path |
39
39
 
40
- If a Story-under-Epic needs replanning, use `/epic-plan --replan`. If you
40
+ If a Story-under-Epic needs replanning, use `/plan <epicId> --force`. If you
41
41
  have a refactor, framework-maintenance idea, or any standalone unit of
42
42
  work, use this workflow.
43
43
 
44
- **Inbound from `/epic-plan` scope triage.** `/epic-plan` Phase 1.5 runs the
45
- [`core/scope-triage`](../skills/core/scope-triage/SKILL.md) rubric over the
44
+ **Inbound from `/plan` scope triage.** `/plan` Phase 1.5 runs the
45
+ [`core/scope-triage`](../../skills/core/scope-triage/SKILL.md) rubric over the
46
46
  sharpened one-pager. On a `story` / `borderline` verdict the operator may route
47
- the work here via `/story-plan --from-notes <path>`. That invocation is a
48
- **scope-triage handoff** — the triage decision is already made, so `/story-plan`
47
+ the work here via `/plan --from-notes <path>`. That invocation is a
48
+ **scope-triage handoff** — the triage decision is already made, so `/plan`
49
49
  MUST NOT re-triage it (the no-re-triage rule in the skill); it proceeds straight
50
50
  to authoring the standalone Story body from the handed-off one-pager.
51
51
 
@@ -54,20 +54,20 @@ to authoring the standalone Story body from the handed-off one-pager.
54
54
  1. `GITHUB_TOKEN` or `gh auth status` clean — `gh issue create` runs at
55
55
  persist time.
56
56
  2. The `type::story` label and the chosen `persona::*` label exist in the
57
- repo. Run [`agents-bootstrap-github.js`](../scripts/agents-bootstrap-github.js)
57
+ repo. Run [`agents-bootstrap-github.js`](../../scripts/agents-bootstrap-github.js)
58
58
  once to provision them.
59
59
 
60
60
  ## Invocation shapes
61
61
 
62
62
  ```bash
63
63
  # Seed from an inline string:
64
- /story-plan --idea "rip out the unused TaskBodyMigrator export"
64
+ /plan --idea "rip out the unused TaskBodyMigrator export"
65
65
 
66
66
  # Seed from a notes file:
67
- /story-plan --from-notes temp/single-story-2293-notes.md
67
+ /plan --from-notes temp/single-story-2293-notes.md
68
68
 
69
69
  # Inspect the draft body without creating an Issue:
70
- /story-plan --dry-run --body temp/single-story-draft.md
70
+ /plan --dry-run --body temp/single-story-draft.md
71
71
  ```
72
72
 
73
73
  ## Phase 1 — Emit Context
@@ -102,8 +102,8 @@ Envelope fields (`kind: "story-plan-context"`, `version: 1`):
102
102
  `refine.refine` is `true` when the seed is shorter than 200 characters
103
103
  (or empty). Pass `--refine` / `--no-refine` to override. When the
104
104
  envelope advises refinement, activate the
105
- [`core/idea-refinement`](../skills/core/idea-refinement/SKILL.md) skill
106
- before drafting the body — same skill `/epic-plan` Phase 1 drives.
105
+ [`core/idea-refinement`](../../skills/core/idea-refinement/SKILL.md) skill
106
+ before drafting the body — same skill `/plan` Phase 1 drives.
107
107
 
108
108
  ## Phase 2 — Host LLM Authors a Draft Body
109
109
 
@@ -120,19 +120,19 @@ Using the envelope above, draft a Story body that:
120
120
 
121
121
  Write the draft to `temp/single-story-draft.md`.
122
122
 
123
- ### Scope-triage escalation gate (symmetric counterpart to `/epic-plan` Phase 1.5)
123
+ ### Scope-triage escalation gate (symmetric counterpart to `/plan` Phase 1.5)
124
124
 
125
125
  Once the draft body exists — and **only** then, because the seed alone is not
126
126
  an honest basis for a sizing judgment — run the
127
- [`core/scope-triage`](../skills/core/scope-triage/SKILL.md) rubric over the
127
+ [`core/scope-triage`](../../skills/core/scope-triage/SKILL.md) rubric over the
128
128
  **drafted Story body** to catch an Epic-sized scope before it is persisted as a
129
- standalone Story. This is the outbound mirror of `/epic-plan` Phase 1.5's
129
+ standalone Story. This is the outbound mirror of `/plan` Phase 1.5's
130
130
  inbound downgrade gate: the two planning entry points route toward each other
131
131
  instead of each silently accepting wrong-sized work.
132
132
 
133
- **Skip the gate entirely when `/story-plan` was entered via a scope-triage
134
- handoff** — i.e. from `/epic-plan` Phase 1.5 (the inbound route above) or the
135
- `/epic-plan` Phase 5.5 existing-Epic conversion path. A handoff is a triage
133
+ **Skip the gate entirely when `/plan` was entered via a scope-triage
134
+ handoff** — i.e. from `/plan` Phase 1.5 (the inbound route above) or the
135
+ `/plan` Phase 5.5 existing-Epic conversion path. A handoff is a triage
136
136
  decision already made; re-running the rubric here would re-litigate a settled
137
137
  call and risk a ping-pong between the two workflows (the skill's no-re-triage
138
138
  rule).
@@ -141,7 +141,7 @@ Otherwise, activate the skill **by reference** — read its `SKILL.md` via the
141
141
  `Read` tool and apply its rubric; do **not** restate its sizing thresholds or
142
142
  copy its verdict prose here. The skill anchors its sizing judgment to
143
143
  `DELIVERABLE_GRANULARITY_GUIDANCE` / `DEFAULT_TASK_SIZING` in
144
- [`ticket-validator-sizing.js`](../scripts/lib/orchestration/ticket-validator-sizing.js)
144
+ [`ticket-validator-sizing.js`](../../scripts/lib/orchestration/ticket-validator-sizing.js)
145
145
  and emits one verdict — `epic` | `story` | `borderline`. The verdict is
146
146
  host-LLM judgment: there is **no `--flag`**, no scorer, no schema, and no label
147
147
  transition behind it. (The `refine` heuristic in `story-plan.js` is unchanged —
@@ -153,7 +153,7 @@ add a second stop.
153
153
 
154
154
  Display the draft to the operator and **STOP**. Do not call the persist phase
155
155
  until the operator explicitly confirms the draft. This mirrors the HITL gate
156
- `/epic-plan` Phase 3 enforces before opening the Epic Issue. The scope-triage
156
+ `/plan` Phase 3 enforces before opening the Epic Issue. The scope-triage
157
157
  verdict folds into this same stop:
158
158
 
159
159
  - **`story` verdict (or gate skipped via handoff)** → no extra prompt. The
@@ -162,12 +162,12 @@ verdict folds into this same stop:
162
162
  - **`epic` verdict** (multiple independent capabilities, a plausible
163
163
  sizing-ceiling breach, or a real dependency structure) → the confirmation
164
164
  prompt presents a **three-way operator choice**:
165
- - **Recommended: escalate to `/epic-plan --idea`** (with the triage
165
+ - **Recommended: escalate to `/plan --idea`** (with the triage
166
166
  rationale) — persist the notes/draft to a notes file and hand off to
167
- `/epic-plan --idea` (or `--from-notes <path>`), identifying the invocation
168
- as a **scope-triage handoff** so `/epic-plan` skips its own Phase 1.5 gate
167
+ `/plan --idea` (or `--from-notes <path>`), identifying the invocation
168
+ as a **scope-triage handoff** so `/plan` skips its own Phase 1.5 gate
169
169
  (the skill's no-re-triage rule). Then **abandon the draft and exit
170
- `/story-plan`** — no standalone Story is created.
170
+ `/plan`** — no standalone Story is created.
171
171
  - **Persist as a standalone Story anyway** — ignore the recommendation and
172
172
  proceed to Phase 3 with the draft unchanged. Being wrong in the `epic`
173
173
  direction is cheap to tolerate: if the operator persists an oversized Story,
@@ -212,22 +212,22 @@ exact `gh issue create` shape that would run.
212
212
 
213
213
  - **No `Epic: #N` references.** This is the standalone contract; persist
214
214
  fails fast if one is present. To attach a Story to an Epic, use
215
- `/epic-plan` Phase 8 instead.
215
+ `/plan` Phase 8 instead.
216
216
  - **No external LLM APIs.** Mirrors the v5.6 contract: the host LLM does
217
217
  the authoring; the Node wrapper does the I/O.
218
218
  - **Idempotent.** Re-running `--emit-context` is safe. Re-running
219
219
  `--body` opens a new Issue (it is not aware of prior runs); use
220
220
  `--dry-run` first when iterating on the draft.
221
- - **Atomic by contract.** A Story is the leaf of the 3-tier hierarchy — it
221
+ - **Atomic by contract.** A Story is the leaf of the 2-tier hierarchy — it
222
222
  has no child tickets. Its acceptance criteria and verification steps live
223
223
  inline on the Story body
224
- ([`single-story-deliver.md`](helpers/single-story-deliver.md)).
224
+ ([`single-story-deliver.md`](single-story-deliver.md)).
225
225
 
226
226
  ## See also
227
227
 
228
- - [`/single-story-deliver`](helpers/single-story-deliver.md) — the consumer
228
+ - [`/single-story-deliver`](single-story-deliver.md) — the consumer
229
229
  workflow that picks the Story up after this one creates it.
230
- - [`/epic-plan`](epic-plan.md) — the Epic-tier equivalent. Phases 1–4
230
+ - [`/plan`](plan-epic.md) — the Epic-tier equivalent. Phases 1–4
231
231
  inspired the seed-capture + envelope-emit pattern used here.
232
- - [`core/idea-refinement`](../skills/core/idea-refinement/SKILL.md) —
232
+ - [`core/idea-refinement`](../../skills/core/idea-refinement/SKILL.md) —
233
233
  optional pre-authoring skill activated when the seed is short.
@@ -12,7 +12,7 @@ description: >-
12
12
  > **Helper, not a slash command.** Files under `workflows/helpers/` are not
13
13
  > projected into the mandrel plugin command tree. The signals subsystem itself
14
14
  > (`lib/signals/`, writer, schema, detectors, NDJSON listeners) runs as
15
- > part of the normal `/epic-deliver` machinery — this viewer is for
15
+ > part of the normal `/deliver` machinery — this viewer is for
16
16
  > ad-hoc debugging when you need to inspect the span-tree directly.
17
17
  > Invoke the backing script: `node .agents/scripts/signals-view.js <epic-id> [--story <id>]`.
18
18
 
@@ -10,7 +10,7 @@ description:
10
10
  ## Overview
11
11
 
12
12
  `/single-story-deliver` is the standalone counterpart to
13
- [`/story-deliver`](../story-deliver.md). Use it for a Story that is **not**
13
+ [`/deliver`](deliver-stories.md). Use it for a Story that is **not**
14
14
  attached to an Epic — refactors carved out of closed Epics, framework
15
15
  maintenance, or any work small enough that the Epic-Centric ceremony
16
16
  (PRD + Tech Spec + decomposition + dispatch manifest + cascade) would be
@@ -25,19 +25,19 @@ overhead rather than help.
25
25
  → single-story-confirm-merge.js (PR merged → agent::done, issue closes)
26
26
  ```
27
27
 
28
- **When to use `/single-story-deliver` vs. `/epic-deliver`:**
28
+ **When to use `/single-story-deliver` vs. `/deliver`:**
29
29
 
30
- | Trait | `/single-story-deliver` | `/epic-deliver` |
30
+ | Trait | `/single-story-deliver` | `/deliver` |
31
31
  | ----------------------------- | ---------------------------------------------------- | ------------------------------------------------------- |
32
32
  | Parent Epic | None (no `Epic: #N` in body) | Required (`Epic: #N` in body) |
33
33
  | Branch base | `project.baseBranch` (default `main`) | `epic/<epicId>` |
34
34
  | Merge target | `main` via PR | `epic/<epicId>` via `--no-ff` merge |
35
- | Cascade up to Feature/Epic | No | Yes |
35
+ | Epic-branch integration | No | Yes — merged into `epic/<epicId>` at close |
36
36
  | Dispatch manifest interaction | None | Read at init, regenerated at close |
37
37
  | Story scope | Inline `acceptance[]` / `verify[]` on the Story body | Inline `acceptance[]` / `verify[]` on the Story body |
38
38
 
39
- If the Story has an `Epic: #N` reference, use `/epic-deliver`. If it
40
- doesn't, use this workflow (or `/story-deliver` for several standalone
39
+ If the Story has an `Epic: #N` reference, use `/deliver`. If it
40
+ doesn't, use this workflow (or `/deliver` for several standalone
41
41
  Stories at once).
42
42
 
43
43
  ## Prerequisites
@@ -82,7 +82,7 @@ the Story to `agent::executing`.
82
82
  > is the only guard against a concurrent `single-story-init` clobbering an
83
83
  > in-flight run.
84
84
  >
85
- > **Fail-closed (audit #3513).** Unlike `/epic-deliver`, the standalone path
85
+ > **Fail-closed (audit #3513).** Unlike `/deliver`, the standalone path
86
86
  > has **no Epic-scoped lifecycle ledger** to read a per-owner
87
87
  > `story.heartbeat` from, so there is no live-heartbeat source to decide
88
88
  > whether a foreign claim is stale. Rather than silently reclaim every
@@ -290,7 +290,7 @@ The script:
290
290
  `gh pr merge <prNumber> --auto --squash --delete-branch`. Once CI's
291
291
  required checks turn green, GitHub squash-merges the PR and deletes
292
292
  the source branch — the operator does not need to babysit the merge
293
- button. Mirrors the `/epic-deliver` finalize path. Failure is
293
+ button. Mirrors the `/deliver` finalize path. Failure is
294
294
  non-fatal: the operator retains the manual merge surface in the
295
295
  GitHub UI. Pass `--no-auto-merge` to opt out when the PR needs a
296
296
  pre-merge eyeball.
@@ -614,7 +614,7 @@ safe.
614
614
  invoking from inside a worktree (worktree-local branch deletion fails
615
615
  when run from inside the worktree).
616
616
  - **Handoff discipline — report state, not process.** When you hand back to
617
- your caller (the `/story-deliver` aggregator or the interactive operator),
617
+ your caller (the `/deliver` aggregator or the interactive operator),
618
618
  report essential terminal state only: the Story branch, the closing commit
619
619
  SHA, what changed, and what was verified. Mirror the fields the close
620
620
  pipeline already emits (`single-story-close.js` / `story-phase.js`
@@ -632,6 +632,6 @@ safe.
632
632
 
633
633
  ## See also
634
634
 
635
- - [`/story-deliver`](../story-deliver.md) — several standalone Stories at
635
+ - [`/deliver`](deliver-stories.md) — several standalone Stories at
636
636
  once (dependency-aware waves).
637
- - [`/epic-deliver`](../epic-deliver.md) — full Epic wave loop.
637
+ - [`/deliver`](deliver-epic.md) — full Epic wave loop.
@@ -14,7 +14,7 @@ into the wrong commit. Epic #229 moves each dispatched story into its own
14
14
  activity are isolated per-story. The main checkout stays quiet.
15
15
 
16
16
  This document is the operator and reviewer reference. See
17
- [`epic-deliver`](../epic-deliver.md) and [`story-deliver`](../story-deliver.md)
17
+ [`epic-deliver`](deliver-epic.md) and [`story-deliver`](deliver-stories.md)
18
18
  for the broader execution flow and the Epic-229 Tech Spec for
19
19
  architectural rationale.
20
20
 
@@ -47,10 +47,10 @@ are all rejected at config-load time.
47
47
 
48
48
  | Phase | When | What happens |
49
49
  | --------------- | ----------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
50
- | **Sweep** | Dispatch-manifest build (`/epic-plan`) and `/epic-deliver` | Stale `*.lock` files under `.git/` (older than 5 min) are removed before GC. |
51
- | **GC** | Dispatch-manifest build (`/epic-plan`) and `/epic-deliver` | Orphan `.worktrees/story-*` whose stories are closed are reaped if clean. |
52
- | **Force-drain** | `/epic-plan` boot (`worktree-sweep.js` via `drainPendingCleanupAtBoot`), `story-close` post-merge (`forceDrainPendingCleanup`), `/epic-deliver` Phase 7 | 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** | `story-init` (entry for `/story-deliver`) | `git worktree add .worktrees/story-<id>/` on the `story-<id>` branch. |
50
+ | **Sweep** | Dispatch-manifest build (`/plan`) and `/deliver` | Stale `*.lock` files under `.git/` (older than 5 min) are removed before GC. |
51
+ | **GC** | Dispatch-manifest build (`/plan`) and `/deliver` | Orphan `.worktrees/story-*` whose stories are closed are reaped if clean. |
52
+ | **Force-drain** | `/plan` boot (`worktree-sweep.js` via `drainPendingCleanupAtBoot`), `story-close` post-merge (`forceDrainPendingCleanup`), `/deliver` Phase 7 | 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** | `story-init` (entry for `/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 `story-close`) | `git worktree remove` — refuses to delete dirty trees or unmerged branches. |
56
56
 
@@ -79,23 +79,23 @@ entry points (see table below).
79
79
  ### Sweep & GC entry points
80
80
 
81
81
  Sweep and GC do **not** run at every Epic entry point — in particular,
82
- `story-init` (the entry for `/story-deliver`) does not invoke them. The full
82
+ `story-init` (the entry for `/deliver`) does not invoke them. The full
83
83
  set of callers is:
84
84
 
85
85
  | Entry point | Script / caller | Runs sweep? | Runs GC? | Force-drain? | Notes |
86
86
  | --------------------------------------------------------------------- | --------------------------------------------------------- | ----------- | -------- | ------------ | --------------------------------------------------------------------------------------------------- |
87
- | Dispatch manifest build (`/epic-plan` Phase 9) | `lib/orchestration/dispatch-pipeline.js::runWorktreeGc` | ✅ Yes | ✅ Yes | ✅ Yes | Called from `dispatch-engine.js::dispatch()`. Scoped to the epic being dispatched. |
88
- | Spec / decompose CLI boot (`/epic-plan` helpers) | `drainPendingCleanupAtBoot` → `worktree-sweep.js` | ✅ Yes* | ❌ No | ✅ Yes | \*Drains the pending ledger then reaps `git worktree list` entries for done/closed Stories (`--force`). |
89
- | Story merge (`/story-deliver` close) | `story-close.js` (`drainPendingCleanupAfterClose`) | ❌ No | ❌ No | ✅ Yes | Runs after the post-merge pipeline when worktree isolation is enabled. |
87
+ | Dispatch manifest build (`/plan` Phase 9) | `lib/orchestration/dispatch-pipeline.js::runWorktreeGc` | ✅ Yes | ✅ Yes | ✅ Yes | Called from `dispatch-engine.js::dispatch()`. Scoped to the epic being dispatched. |
88
+ | Spec / decompose CLI boot (`/plan` helpers) | `drainPendingCleanupAtBoot` → `worktree-sweep.js` | ✅ Yes* | ❌ No | ✅ Yes | \*Drains the pending ledger then reaps `git worktree list` entries for done/closed Stories (`--force`). |
89
+ | Story merge (`/deliver` close) | `story-close.js` (`drainPendingCleanupAfterClose`) | ❌ No | ❌ No | ✅ Yes | Runs after the post-merge pipeline when worktree isolation is enabled. |
90
90
  | Story close | `epic-deliver runner` (invoked by `story-close.js`) | ✅ Yes | ✅ Yes | ✅ Yes | Runs before branch deletion so reaping cannot collide with `git branch -D`. |
91
- | Story init (`/story-deliver <storyId>`) | `story-init.js` | ❌ No | ❌ No | ❌ No | Story execution relies on the dispatch/close pair to clean up; it only creates its own worktree. |
92
- | Epic deliver wave loop (`/epic-deliver`) | `/epic-deliver` slash command + `lib/orchestration/epic-runner/*` | ❌ No | ❌ No | ❌ No | Does not call `sweepStaleLocks` or `gc` directly; cleanup still flows through dispatch + close. |
93
- | Drain pending-cleanup (operator-driven) | `drain-pending-cleanup.js` (run directly — see below) | n/a | n/a | ✅ Yes | Manual escape hatch; same drain + Windows escalation as the `/epic-plan` and `/epic-deliver` paths. |
91
+ | Story init (`/deliver <storyId>`) | `story-init.js` | ❌ No | ❌ No | ❌ No | Story execution relies on the dispatch/close pair to clean up; it only creates its own worktree. |
92
+ | Epic deliver wave loop (`/deliver`) | `/deliver` slash command + `lib/orchestration/epic-runner/*` | ❌ No | ❌ No | ❌ No | Does not call `sweepStaleLocks` or `gc` directly; cleanup still flows through dispatch + close. |
93
+ | Drain pending-cleanup (operator-driven) | `drain-pending-cleanup.js` (run directly — see below) | n/a | n/a | ✅ Yes | Manual escape hatch; same drain + Windows escalation as the `/plan` and `/deliver` paths. |
94
94
 
95
95
  Operator takeaway: if you need to force a sweep/GC without closing a story,
96
- the most direct path is re-running `/epic-plan` (or rebuilding the dispatch
96
+ the most direct path is re-running `/plan` (or rebuilding the dispatch
97
97
  manifest via `dispatcher.js`) against the active epic. Running
98
- `/story-deliver <storyId>` on its own does **not** clean up orphan worktrees
98
+ `/deliver <storyId>` on its own does **not** clean up orphan worktrees
99
99
  or stale locks.
100
100
 
101
101
  ## Draining the pending-cleanup ledger
@@ -116,7 +116,7 @@ PowerShell `Get-CimInstance Win32_Process`, terminating them with
116
116
  > `/drain-pending-cleanup` slash command — it was demoted to a
117
117
  > directly-runnable script (Story #3706, overturning the
118
118
  > `docs/decisions.md` matrix row that originally kept it as a command).
119
- > The three automatic callers — `/epic-deliver` runner Phase 7,
119
+ > The three automatic callers — `/deliver` runner Phase 7,
120
120
  > `story-close.js`, and `worktree-sweep.js` — invoke
121
121
  > `drain-pending-cleanup.js` **directly**, so the demotion does not touch
122
122
  > them. The manual path survives unchanged as
@@ -126,8 +126,8 @@ PowerShell `Get-CimInstance Win32_Process`, terminating them with
126
126
 
127
127
  | Trigger | Caller |
128
128
  | ---------------- | ---------------------------------------------------------------------------- |
129
- | `/epic-deliver` | [`Cleaner` lifecycle listener](../../scripts/lib/orchestration/lifecycle/listeners/cleaner.js) at the close-tail cleanup phase (before `wm.gc()`) |
130
- | `/epic-plan` | [`drainPendingCleanupAtBoot`](../../scripts/epic-plan-spec.js) → [`worktree-sweep.js`](../../scripts/lib/orchestration/plan-runner/worktree-sweep.js) |
129
+ | `/deliver` | [`Cleaner` lifecycle listener](../../scripts/lib/orchestration/lifecycle/listeners/cleaner.js) at the close-tail cleanup phase (before `wm.gc()`) |
130
+ | `/plan` | [`drainPendingCleanupAtBoot`](../../scripts/epic-plan-spec.js) → [`worktree-sweep.js`](../../scripts/lib/orchestration/plan-runner/worktree-sweep.js) |
131
131
  | Story merge close | [`story-close.js`](../../scripts/story-close.js) (`drainPendingCleanupAfterClose`) |
132
132
 
133
133
  All automatic paths call `forceDrainPendingCleanup()` (or are folded into
@@ -312,6 +312,6 @@ Human reviewers should **keep using the main checkout** — not a worktree:
312
312
  `git worktree remove --force <path>`. Confirm there is no uncommitted work
313
313
  first.
314
314
  - **Disable temporarily**: flip `enabled: false` in `.agentrc.json`. The next
315
- `/story-deliver` skips worktree creation entirely.
315
+ `/deliver` skips worktree creation entirely.
316
316
  - **Inspect live worktrees**: `git worktree list --porcelain` on the main
317
317
  checkout. Each block shows `worktree <path>` / `branch refs/heads/story-<id>`.
@@ -2,7 +2,7 @@
2
2
  description: >-
3
3
  Guided first-run onboarding for a freshly installed Mandrel. Detects the
4
4
  consumer stack, offers to scaffold any missing docsContextFiles, runs
5
- `mandrel doctor` as a readiness gate, and hands off to a started /epic-plan.
5
+ `mandrel doctor` as a readiness gate, and hands off to a started /plan.
6
6
  The whole path is designed to take about 15 minutes from a clean checkout to
7
7
  a planned Epic.
8
8
  ---
@@ -14,7 +14,7 @@ description: >-
14
14
  Onboarding guide. You walk a first-time operator from a freshly installed
15
15
  Mandrel to their first planned Epic, composing the building blocks shipped by
16
16
  the guided-onboard Feature (#3514): stack detection, docs scaffolding, the
17
- `mandrel doctor` readiness check, and a started `/epic-plan` handoff.
17
+ `mandrel doctor` readiness check, and a started `/plan` handoff.
18
18
 
19
19
  ## Overview
20
20
 
@@ -27,7 +27,7 @@ block, then hands the operator off to planning:
27
27
  → Phase 1 — Detect stack (lib/onboard/detect-stack.js#detectStack)
28
28
  → Phase 2 — Offer docs scaffolding (lib/onboard/scaffold-docs.js#scaffoldDocs)
29
29
  → Phase 3 — Readiness gate (mandrel doctor → lib/cli/doctor.js)
30
- → Phase 4 — Handoff to /epic-plan (started, not auto-run)
30
+ → Phase 4 — Handoff to /plan (started, not auto-run)
31
31
  ```
32
32
 
33
33
  Each phase is **advisory and resumable**: re-running `/onboard` on an
@@ -40,8 +40,8 @@ genuinely missing, and `mandrel doctor` is read-only).
40
40
  | Scenario | Command |
41
41
  | --- | --- |
42
42
  | First run after installing Mandrel into a project | `/onboard` |
43
- | Plan a new Epic once onboarded | `/epic-plan <epicId>` or `/epic-plan --idea "<seed>"` |
44
- | Deliver Epic-attached Stories | `/epic-deliver <epicId>` |
43
+ | Plan a new Epic once onboarded | `/plan <epicId>` or `/plan --idea "<seed>"` |
44
+ | Deliver Epic-attached Stories | `/deliver <epicId>` |
45
45
 
46
46
  ## Prerequisites
47
47
 
@@ -68,7 +68,7 @@ planned Epic in roughly **15 minutes**. The budget breaks down as:
68
68
  | Detect the stack and confirm the report | Phase 1 | ~1 min |
69
69
  | Review the missing-docs offer and accept the scaffold | Phase 2 | ~3 min |
70
70
  | Run `mandrel doctor` and clear any ✘ checks | Phase 3 | ~5 min |
71
- | Start `/epic-plan` and describe the first Epic idea | Phase 4 | ~6 min |
71
+ | Start `/plan` and describe the first Epic idea | Phase 4 | ~6 min |
72
72
 
73
73
  If any single phase blows its budget — most often a Phase 3 remedy such as
74
74
  authenticating `gh` or installing runtime deps — clear that one check and
@@ -161,45 +161,45 @@ the command exits:
161
161
  through the `→` remedies (e.g. authenticate `gh`, set `GITHUB_TOKEN`,
162
162
  install runtime deps), then re-run `mandrel doctor` until it is green.
163
163
 
164
- Do **not** hand off to `/epic-plan` while the doctor is red — planning needs a
164
+ Do **not** hand off to `/plan` while the doctor is red — planning needs a
165
165
  working `gh` / `GITHUB_TOKEN` and a materialized `.agents/` bundle, exactly
166
166
  what the gate verifies. The `github-token` check never echoes the token value
167
167
  (security baseline § Secrets Management).
168
168
 
169
- ## Phase 4 — Handoff to a started `/epic-plan`
169
+ ## Phase 4 — Handoff to a started `/plan`
170
170
 
171
171
  With a green readiness gate, hand the operator off to planning. `/onboard`
172
172
  **starts** the handoff — it surfaces the entry point and the idea-refinement
173
- path — but does **not** auto-run `/epic-plan`, because Epic planning authors
173
+ path — but does **not** auto-run `/plan`, because Epic planning authors
174
174
  GitHub artifacts and must stay under explicit operator control.
175
175
 
176
- Present the operator with the two `/epic-plan` entry shapes:
176
+ Present the operator with the two `/plan` entry shapes:
177
177
 
178
178
  - **From an idea** (no Epic exists yet):
179
179
 
180
180
  ```text
181
- /epic-plan --idea "<one-line description of the first thing to build>"
181
+ /plan --idea "<one-line description of the first thing to build>"
182
182
  ```
183
183
 
184
- This enters [`/epic-plan`](epic-plan.md) at Phase 1 (Idea Refinement),
184
+ This enters [`/plan`](helpers/plan-epic.md) at Phase 1 (Idea Refinement),
185
185
  which refines the seed into a PRD, Tech Spec, and a decomposed
186
- Epic → Feature → Story backlog.
186
+ Epic → Story backlog.
187
187
 
188
188
  - **From an existing Epic** (a `type::epic` issue already exists):
189
189
 
190
190
  ```text
191
- /epic-plan <epicId>
191
+ /plan <epicId>
192
192
  ```
193
193
 
194
- Stop here and let the operator invoke `/epic-plan` themselves. Once they have
195
- a planned Epic, the natural next step is `/epic-deliver <epicId>` to execute
194
+ Stop here and let the operator invoke `/plan` themselves. Once they have
195
+ a planned Epic, the natural next step is `/deliver <epicId>` to execute
196
196
  it — but that is beyond the onboarding path.
197
197
 
198
198
  ## Constraints
199
199
 
200
200
  - **Read-before-write.** Phases 1 and 3 are read-only; Phase 2 writes only
201
201
  files that are genuinely missing and only on explicit operator acceptance.
202
- - **Do not auto-run `/epic-plan`.** Phase 4 starts the handoff; the operator
202
+ - **Do not auto-run `/plan`.** Phase 4 starts the handoff; the operator
203
203
  invokes planning. Planning authors GitHub artifacts and stays under human
204
204
  control.
205
205
  - **Never echo secrets.** The `github-token` check and any token-related
@@ -0,0 +1,89 @@
1
+ ---
2
+ description:
3
+ Unified planning entry point. Routes a seed idea (via scope triage) or an
4
+ existing Epic ID to the right planning path — the full Epic pipeline
5
+ (PRD, Tech Spec, Acceptance Spec, decomposition) or the standalone-Story
6
+ authoring path — and absorbs every planning flag.
7
+ ---
8
+
9
+ # /plan [Epic ID] | --idea "<seed>" | --from-notes <path>
10
+
11
+ ## Role
12
+
13
+ Router. `/plan` owns argument parsing and path selection only — all phase
14
+ content lives in the two path helpers:
15
+
16
+ - [`helpers/plan-epic.md`](helpers/plan-epic.md) — the full Epic planning
17
+ pipeline (PRD, Tech Spec, Acceptance Spec, work breakdown, healthcheck,
18
+ handoff).
19
+ - [`helpers/plan-story.md`](helpers/plan-story.md) — the standalone-Story
20
+ authoring path (context envelope → host-LLM draft → HITL → issue create).
21
+
22
+ The existing **scope-triage skill**
23
+ ([`core/scope-triage`](../skills/core/scope-triage/SKILL.md), verdicts
24
+ `epic | story | borderline`) is the router's classifier on the `--idea`
25
+ path; no new classification machinery exists.
26
+
27
+ ## Inputs
28
+
29
+ | Invocation | Behavior |
30
+ | --- | --- |
31
+ | `/plan --idea "<seed>"` | Ideation → **scope triage**. Verdict `epic` → run [`helpers/plan-epic.md`](helpers/plan-epic.md) from Phase 1 (Idea Refinement). Verdict `story` → run [`helpers/plan-story.md`](helpers/plan-story.md) Phases 1–3. Verdict `borderline` → present both options and let the operator choose. |
32
+ | `/plan <epicId>` | Existing-Epic path — run [`helpers/plan-epic.md`](helpers/plan-epic.md) from Phase 5. When the helper's story-sized advisory fires (the Epic is really one Story), convert **internally** by switching to [`helpers/plan-story.md`](helpers/plan-story.md) — do not re-triage and do not hop commands. |
33
+ | `/plan --from-notes <path>` | Internal handoff target (e.g. from `/audit-to-stories`). The notes file already encodes the path decision; do **not** re-run scope triage. Route per the notes' declared shape. |
34
+
35
+ ## Flags
36
+
37
+ `/plan` absorbs every flag the two retired planning commands accepted and
38
+ forwards them to the active path helper:
39
+
40
+ | Flag | Path | Meaning |
41
+ | --- | --- | --- |
42
+ | `--idea "<seed>"` | both | Seed text; triggers scope triage. |
43
+ | `--from-notes <path>` | both | Pre-triaged handoff notes; skips triage. |
44
+ | `--force` | Epic | Close + recreate an existing ticket tree on re-plan. |
45
+ | `--force-review` | Epic | Force the operator review gate even when risk routing would skip it. |
46
+ | `--allow-over-budget` | Epic | Permit a decomposition that exceeds `planning.maxTickets`. |
47
+ | `--steal` | Epic | Forcibly transfer a foreign Epic-lease. |
48
+ | `--dry-run` | both | Author + validate without GitHub writes. |
49
+ | `--body <path>` | Story | Pre-authored Story body file; validate (and create, unless `--dry-run`) without re-authoring. |
50
+ | `--persona <name>` | Story | Override the persona label on the drafted Story. |
51
+ | `--refine` / `--no-refine` | Story | Toggle the draft refinement loop. |
52
+
53
+ **Cross-path flags are no-ops with a warning.** An Epic-only flag passed on
54
+ the story path (or vice versa) is reported once
55
+ (`[plan] --force has no effect on the story path`) and ignored — never an
56
+ error. The historical bidirectional escalation between the two planning
57
+ commands (story-sized Epic ↘ Story; epic-sized Story draft ↗ Epic) is now
58
+ an **internal branch switch** inside this router: same skills, same
59
+ helpers, no command hop and no operator re-entry.
60
+
61
+ ## Procedure
62
+
63
+ 1. **Parse args.** Exactly one of `<epicId>`, `--idea`, `--from-notes`, or
64
+ `--body` must be present; anything else is a usage error naming the four
65
+ forms. A `--body` invocation routes to the story path (no triage).
66
+ 2. **Triage (idea path only).** Run the
67
+ [`core/scope-triage`](../skills/core/scope-triage/SKILL.md) skill on the
68
+ seed. Record the verdict in chat (one line).
69
+ 3. **Delegate.** Read the selected path helper **in full** and execute it
70
+ from its entry phase, forwarding the absorbed flags. The helper's phase
71
+ numbering, HITL gates, and scripts are unchanged — this router adds no
72
+ phase content.
73
+ 4. **Internal returns.** When a path helper would historically have handed
74
+ off to the other planning command, switch helpers in-place and continue;
75
+ surface the switch to the operator as a one-line note.
76
+
77
+ ## Constraints
78
+
79
+ - The plan→deliver boundary stays a hard stop: `/plan` never starts
80
+ delivery. It ends by naming the follow-up — `/deliver <epicId>` for a
81
+ planned Epic, `/deliver <storyId>` for a standalone Story.
82
+ - The router never calls planning scripts directly; the path helpers own
83
+ every script invocation.
84
+
85
+ ## See also
86
+
87
+ - [`/deliver`](deliver.md) — the unified delivery entry point.
88
+ - [`helpers/plan-epic.md`](helpers/plan-epic.md) /
89
+ [`helpers/plan-story.md`](helpers/plan-story.md) — the path helpers.
@@ -33,7 +33,7 @@ resolution, redaction, coverage verdict, missing-test proposal, classification,
33
33
  and dedup/route decisions. The agent never invents those decisions in prose.
34
34
 
35
35
  > **When to run**: ad-hoc agent-driven exploration of a freshly delivered Story
36
- > or Feature, a regression sweep over a risky surface before `/epic-deliver`, or
36
+ > or Feature, a regression sweep over a risky surface before `/deliver`, or
37
37
  > a structured agent-driven bug-hunt the operator wants captured into a
38
38
  > triageable ledger.
39
39
  >
@@ -22,7 +22,7 @@ console filtering.
22
22
 
23
23
  > **When to run**: During sprint testing to exercise a targeted slice of the
24
24
  > acceptance suite (a feature, a tag expression, or a domain), for regression
25
- > passes before `/epic-deliver`, or on demand while debugging a Story's
25
+ > passes before `/deliver`, or on demand while debugging a Story's
26
26
  > user-visible behavior in a live browser.
27
27
  >
28
28
  > **Persona**: `qa-engineer` · **Skills**: `stack/qa/gherkin-authoring`,
package/README.md CHANGED
@@ -40,8 +40,8 @@ npx mandrel init # install mandrel → sync → prompt → bootstrap
40
40
 
41
41
  ```text
42
42
  # then, inside Claude Code (commands load from .claude/commands/):
43
- /onboard # guided first run: stack detect → docs → doctor → /epic-plan
44
- /epic-plan # ideation -> PRD/Tech Spec -> Epic/Feature/Story hierarchy
43
+ /onboard # guided first run: stack detect → docs → doctor → /plan
44
+ /plan # ideation -> PRD/Tech Spec -> Epic with child Stories
45
45
  ```
46
46
 
47
47
  `npx mandrel init` installs `mandrel` (when `./.agents/` is absent),
@@ -53,8 +53,8 @@ straight to configure (and forwards the flag to bootstrap). When `./.agents/`
53
53
  is already present (you ran `npm install mandrel` first), `init` skips the
54
54
  install/sync and goes straight to the prompt. `/onboard` then walks you from a
55
55
  clean checkout to a planned Epic (stack detection, docs scaffolding, a
56
- `mandrel doctor` readiness gate, and a started `/epic-plan`). Once you have a
57
- planned Epic, deliver it with `/epic-deliver <id>` (wave loop → validation →
56
+ `mandrel doctor` readiness gate, and a started `/plan`). Once you have a
57
+ planned Epic, deliver it with `/deliver <id>` (wave loop → validation →
58
58
  review → retro → open PR).
59
59
 
60
60
  ### Manual equivalent
@@ -150,14 +150,6 @@ npx mandrel sync # re-materialize ./.agents/
150
150
  npx mandrel doctor # verify the install
151
151
  ```
152
152
 
153
- ### Migrating from `@mandrelai/agents`
154
-
155
- The framework package was renamed from the scoped `@mandrelai/agents` to the
156
- unscoped `mandrel`. Already on the old name? `mandrel update` does **not**
157
- auto-migrate (it resolves the package by name), so make the one-time manual
158
- hop documented in
159
- [`docs/migrate-mandrelai-to-mandrel.md`](docs/migrate-mandrelai-to-mandrel.md).
160
-
161
153
  ## Contributors
162
154
 
163
155
  Only `.agents/` is distributed to consumers — it ships inside the