mandrel 2.0.0 → 2.1.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 (311) hide show
  1. package/.agents/README.md +59 -28
  2. package/.agents/agents/acceptance-critic.md +9 -7
  3. package/.agents/agents/story-worker.md +41 -46
  4. package/.agents/audit-checklists/performance.md +1 -1
  5. package/.agents/docs/SDLC.md +51 -44
  6. package/.agents/docs/agentrc-reference.json +8 -13
  7. package/.agents/docs/configuration.md +32 -56
  8. package/.agents/docs/execution-reference.md +39 -10
  9. package/.agents/docs/quality-gates.md +14 -16
  10. package/.agents/docs/workflows.md +6 -6
  11. package/.agents/instructions.md +64 -79
  12. package/.agents/rules/ci-remediation.md +3 -3
  13. package/.agents/rules/git-conventions-reference.md +42 -51
  14. package/.agents/schemas/agentrc.schema.json +34 -45
  15. package/.agents/schemas/audit-rules.json +59 -1
  16. package/.agents/schemas/audit-rules.schema.json +33 -1
  17. package/.agents/schemas/lifecycle/README.md +1 -2
  18. package/.agents/schemas/lifecycle/ledger-record.schema.json +1 -1
  19. package/.agents/schemas/lifecycle/merge.flip-failed.schema.json +33 -0
  20. package/.agents/schemas/lifecycle/merge.unlanded.schema.json +1 -0
  21. package/.agents/schemas/lifecycle/story.merged.schema.json +1 -1
  22. package/.agents/schemas/signal-event.schema.json +3 -3
  23. package/.agents/schemas/story-deliver-terminal.schema.json +152 -0
  24. package/.agents/schemas/validation-evidence.schema.json +1 -1
  25. package/.agents/scripts/acceptance-eval.js +22 -66
  26. package/.agents/scripts/agents-bootstrap-github.js +1 -1
  27. package/.agents/scripts/bootstrap.js +3 -3
  28. package/.agents/scripts/check-dead-exports.js +43 -104
  29. package/.agents/scripts/check-doc-links.js +2 -2
  30. package/.agents/scripts/check-lifecycle-lint.js +1 -1
  31. package/.agents/scripts/check-workflow-cli-lint.js +91 -0
  32. package/.agents/scripts/deliver-recover.js +122 -0
  33. package/.agents/scripts/drain-pending-cleanup.js +1 -1
  34. package/.agents/scripts/evidence-gate.js +20 -50
  35. package/.agents/scripts/generate-skills-index.js +17 -1
  36. package/.agents/scripts/generate-workflows-doc.js +4 -4
  37. package/.agents/scripts/lib/ITicketingProvider.js +1 -19
  38. package/.agents/scripts/lib/audit-suite/selector.js +323 -23
  39. package/.agents/scripts/lib/baselines/kinds/maintainability.js +0 -11
  40. package/.agents/scripts/lib/bootstrap/ci-workflow-template.js +28 -33
  41. package/.agents/scripts/lib/bootstrap/manifest.js +8 -11
  42. package/.agents/scripts/lib/bootstrap/project-bootstrap.js +30 -53
  43. package/.agents/scripts/lib/bootstrap/quality-bootstrap.js +0 -2
  44. package/.agents/scripts/lib/checks/core-bare-clean.js +4 -1
  45. package/.agents/scripts/lib/checks/index.js +1 -1
  46. package/.agents/scripts/lib/checks/loop-health.js +12 -11
  47. package/.agents/scripts/lib/checks/state.js +17 -248
  48. package/.agents/scripts/lib/checks/story-init-not-backgrounded.js +3 -3
  49. package/.agents/scripts/lib/checks/subagent-agent-tool-required.js +3 -4
  50. package/.agents/scripts/lib/checks/worktree-bootstrap-env.js +2 -2
  51. package/.agents/scripts/lib/checks/worktree-residue-biome.js +3 -3
  52. package/.agents/scripts/lib/cli-args.js +23 -2
  53. package/.agents/scripts/lib/close-validation/gates.js +13 -13
  54. package/.agents/scripts/lib/close-validation/projections/inputs.js +7 -7
  55. package/.agents/scripts/lib/close-validation/projections/maintainability.js +12 -12
  56. package/.agents/scripts/lib/close-validation/runner.js +13 -21
  57. package/.agents/scripts/lib/close-validation/telemetry.js +17 -8
  58. package/.agents/scripts/lib/config/delivery-routing.js +7 -6
  59. package/.agents/scripts/lib/config/explain.js +10 -16
  60. package/.agents/scripts/lib/config/github.js +7 -5
  61. package/.agents/scripts/lib/config/limits.js +15 -25
  62. package/.agents/scripts/lib/config/quality.js +11 -14
  63. package/.agents/scripts/lib/config/runners.js +8 -21
  64. package/.agents/scripts/lib/config/temp-paths.js +18 -56
  65. package/.agents/scripts/lib/config-settings-schema-delivery.js +31 -13
  66. package/.agents/scripts/lib/config-settings-schema-quality.js +9 -2
  67. package/.agents/scripts/lib/config-settings-schema.js +48 -22
  68. package/.agents/scripts/lib/dead-exports-knip.js +105 -0
  69. package/.agents/scripts/lib/dead-exports-mode.js +51 -0
  70. package/.agents/scripts/lib/duplicate-search.js +38 -7
  71. package/.agents/scripts/lib/findings/promote-finding.js +23 -14
  72. package/.agents/scripts/lib/format-generated-json.js +97 -0
  73. package/.agents/scripts/lib/framework-version.js +19 -189
  74. package/.agents/scripts/lib/gh-exec.js +8 -0
  75. package/.agents/scripts/lib/git-branch-lifecycle.js +0 -158
  76. package/.agents/scripts/lib/git-utils.js +0 -14
  77. package/.agents/scripts/lib/json-utils.js +1 -2
  78. package/.agents/scripts/lib/label-constants.js +0 -15
  79. package/.agents/scripts/lib/label-taxonomy.js +1 -12
  80. package/.agents/scripts/lib/observability/active-story-env.js +42 -163
  81. package/.agents/scripts/lib/observability/runtime-friction.js +243 -0
  82. package/.agents/scripts/lib/observability/signal-validator.js +4 -4
  83. package/.agents/scripts/lib/observability/signals-writer.js +6 -82
  84. package/.agents/scripts/lib/observability/source-classifier.js +2 -2
  85. package/.agents/scripts/lib/observability/tool-trace-hook.js +2 -12
  86. package/.agents/scripts/lib/orchestration/acceptance-clusters.js +1 -1
  87. package/.agents/scripts/lib/orchestration/acceptance-eval-decision.js +2 -2
  88. package/.agents/scripts/lib/orchestration/ceremony-routing.js +43 -45
  89. package/.agents/scripts/lib/orchestration/code-review.js +58 -168
  90. package/.agents/scripts/lib/orchestration/consolidation-precondition.js +3 -3
  91. package/.agents/scripts/lib/orchestration/deliver-recover.js +328 -0
  92. package/.agents/scripts/lib/orchestration/detectors-phase.js +12 -6
  93. package/.agents/scripts/lib/orchestration/git-cleanup/phases/fast-forward.js +34 -0
  94. package/.agents/scripts/lib/orchestration/lease-guard-shared.js +3 -2
  95. package/.agents/scripts/lib/orchestration/lifecycle/emit-ledger-event.js +142 -0
  96. package/.agents/scripts/lib/orchestration/lifecycle/emit-loop-tick.js +9 -11
  97. package/.agents/scripts/lib/orchestration/lifecycle/emit-merge-flip-failed.js +86 -0
  98. package/.agents/scripts/lib/orchestration/lifecycle/emit-merge-unlanded.js +37 -103
  99. package/.agents/scripts/lib/orchestration/lifecycle/listeners/README.md +7 -3
  100. package/.agents/scripts/lib/orchestration/lifecycle/listeners/watcher.js +50 -85
  101. package/.agents/scripts/lib/orchestration/lifecycle/trace-logger.js +3 -14
  102. package/.agents/scripts/lib/orchestration/merge-block-class.js +76 -20
  103. package/.agents/scripts/lib/orchestration/merge-poll.js +104 -0
  104. package/.agents/scripts/lib/orchestration/plan-context.js +114 -24
  105. package/.agents/scripts/lib/orchestration/plan-critic-conditions.js +11 -22
  106. package/.agents/scripts/lib/orchestration/plan-critics-evaluate.js +3 -7
  107. package/.agents/scripts/lib/orchestration/plan-metrics.js +38 -6
  108. package/.agents/scripts/lib/orchestration/plan-persist/fan-out-gate.js +16 -6
  109. package/.agents/scripts/lib/orchestration/plan-persist/persist-helpers.js +173 -25
  110. package/.agents/scripts/lib/orchestration/plan-persist/plan-context-source.js +116 -0
  111. package/.agents/scripts/lib/orchestration/plan-persist/run-plan-persist.js +280 -75
  112. package/.agents/scripts/lib/orchestration/plan-persist/story-ops.js +472 -55
  113. package/.agents/scripts/lib/orchestration/plan-persist/summary.js +21 -16
  114. package/.agents/scripts/lib/orchestration/plan-persist/supersede-ops.js +509 -0
  115. package/.agents/scripts/lib/orchestration/planning/authoring-context.js +41 -40
  116. package/.agents/scripts/lib/orchestration/planning/spec-authoring-grounding.js +1 -1
  117. package/.agents/scripts/lib/orchestration/resolve-stories.js +344 -0
  118. package/.agents/scripts/lib/orchestration/retro-proposals.js +7 -7
  119. package/.agents/scripts/lib/orchestration/review-depth.js +105 -40
  120. package/.agents/scripts/lib/orchestration/review-providers/findings-renderer.js +3 -13
  121. package/.agents/scripts/lib/orchestration/review-providers/native.js +1 -154
  122. package/.agents/scripts/lib/orchestration/review-providers/review-depth.js +3 -2
  123. package/.agents/scripts/lib/orchestration/review-providers/security-review.js +1 -1
  124. package/.agents/scripts/lib/orchestration/review-providers/types.js +5 -4
  125. package/.agents/scripts/lib/orchestration/review-providers/ultrareview.js +1 -1
  126. package/.agents/scripts/lib/orchestration/run-epilogue.js +374 -16
  127. package/.agents/scripts/lib/orchestration/single-story-close/phases/auto-merge.js +24 -0
  128. package/.agents/scripts/lib/orchestration/single-story-close/phases/base-sync.js +11 -9
  129. package/.agents/scripts/lib/orchestration/single-story-close/phases/close-validation.js +4 -4
  130. package/.agents/scripts/lib/orchestration/single-story-close/phases/code-review.js +3 -12
  131. package/.agents/scripts/lib/orchestration/single-story-close/phases/confirm-merge.js +608 -152
  132. package/.agents/scripts/lib/orchestration/single-story-close/phases/options.js +72 -30
  133. package/.agents/scripts/lib/orchestration/single-story-close/phases/post-land.js +305 -0
  134. package/.agents/scripts/lib/orchestration/single-story-close/phases/pull-request.js +1 -1
  135. package/.agents/scripts/lib/orchestration/single-story-close/phases/review-block.js +12 -8
  136. package/.agents/scripts/lib/orchestration/single-story-close/phases/worktree-reap.js +37 -4
  137. package/.agents/scripts/lib/orchestration/single-story-close/phases/wrong-tree-guard.js +2 -2
  138. package/.agents/scripts/lib/orchestration/single-story-close/runner.js +264 -43
  139. package/.agents/scripts/lib/orchestration/single-story-lease-guard.js +1 -1
  140. package/.agents/scripts/lib/orchestration/story-close/format-autofix.js +10 -10
  141. package/.agents/scripts/lib/orchestration/story-close/phases/code-review.js +15 -32
  142. package/.agents/scripts/lib/orchestration/story-deliver-terminal.js +360 -0
  143. package/.agents/scripts/lib/orchestration/story-follow-ups.js +75 -14
  144. package/.agents/scripts/lib/orchestration/story-init-remote.js +12 -8
  145. package/.agents/scripts/lib/orchestration/story-plan-state.js +14 -29
  146. package/.agents/scripts/lib/orchestration/task-body-validator.js +52 -7
  147. package/.agents/scripts/lib/orchestration/ticket-lease.js +27 -74
  148. package/.agents/scripts/lib/orchestration/ticket-validator-conflicts.js +119 -14
  149. package/.agents/scripts/lib/orchestration/ticket-validator-sizing.js +3 -4
  150. package/.agents/scripts/lib/orchestration/ticket-validator.js +121 -18
  151. package/.agents/scripts/lib/orchestration/ticketing/bulk.js +14 -47
  152. package/.agents/scripts/lib/orchestration/ticketing/reads.js +19 -32
  153. package/.agents/scripts/lib/orchestration/ticketing/transition.js +61 -1
  154. package/.agents/scripts/lib/orchestration/ticketing.js +0 -1
  155. package/.agents/scripts/lib/plan-phase-cleanup.js +12 -14
  156. package/.agents/scripts/lib/planning-corpus.js +12 -286
  157. package/.agents/scripts/lib/preflight-runner.js +2 -2
  158. package/.agents/scripts/lib/qa/qa-context-hydrator.js +5 -5
  159. package/.agents/scripts/lib/signals/index.js +4 -17
  160. package/.agents/scripts/lib/signals/read.js +35 -35
  161. package/.agents/scripts/lib/signals/schema.js +8 -11
  162. package/.agents/scripts/lib/signals/span-tree.js +7 -7
  163. package/.agents/scripts/lib/signals/write.js +0 -1
  164. package/.agents/scripts/lib/single-story/story-merged-notify.js +13 -2
  165. package/.agents/scripts/lib/skills/parse-skill.js +16 -3
  166. package/.agents/scripts/lib/story-adjacency.js +8 -7
  167. package/.agents/scripts/lib/story-body/story-body.js +6 -5
  168. package/.agents/scripts/lib/templates/decomposer-prompts.js +7 -3
  169. package/.agents/scripts/lib/test-env.js +14 -1
  170. package/.agents/scripts/lib/test-tiers.js +0 -3
  171. package/.agents/scripts/lib/ticket-body-sections.js +0 -14
  172. package/.agents/scripts/lib/validation-evidence.js +31 -59
  173. package/.agents/scripts/lib/wave-runner/ready-set.js +32 -6
  174. package/.agents/scripts/lib/worktree/lifecycle/pending-cleanup.js +1 -1
  175. package/.agents/scripts/lib/worktree/lifecycle/reap.js +68 -19
  176. package/.agents/scripts/lib/worktree/lifecycle-manager.js +1 -2
  177. package/.agents/scripts/plan-context.js +38 -6
  178. package/.agents/scripts/plan-persist.js +145 -35
  179. package/.agents/scripts/plan-run-epilogue.js +83 -38
  180. package/.agents/scripts/post-structured-comment.js +0 -38
  181. package/.agents/scripts/pr-watch-with-update.js +43 -22
  182. package/.agents/scripts/providers/github/compose.js +0 -1
  183. package/.agents/scripts/providers/github/errors.js +0 -19
  184. package/.agents/scripts/providers/github/issues.js +1 -11
  185. package/.agents/scripts/providers/github/mappers.js +5 -0
  186. package/.agents/scripts/providers/github/sub-issues.js +0 -47
  187. package/.agents/scripts/providers/github/tickets.js +33 -153
  188. package/.agents/scripts/providers/github.js +17 -6
  189. package/.agents/scripts/resolve-stories.js +236 -0
  190. package/.agents/scripts/run-coverage.js +4 -1
  191. package/.agents/scripts/run-lint.js +2 -2
  192. package/.agents/scripts/run-verify.js +31 -2
  193. package/.agents/scripts/signals-view.js +9 -10
  194. package/.agents/scripts/single-story-close.js +173 -18
  195. package/.agents/scripts/single-story-confirm-merge.js +288 -15
  196. package/.agents/scripts/single-story-init.js +6 -10
  197. package/.agents/scripts/stories-wave-tick.js +79 -4
  198. package/.agents/scripts/story-plan.js +3 -3
  199. package/.agents/scripts/update-ticket-state.js +8 -50
  200. package/.agents/skills/core/code-review-and-quality/SKILL.md +28 -450
  201. package/.agents/skills/core/code-review-and-quality/reference.md +458 -0
  202. package/.agents/skills/core/debugging-and-error-recovery/SKILL.md +22 -315
  203. package/.agents/skills/core/debugging-and-error-recovery/reference.md +323 -0
  204. package/.agents/skills/core/diagnose-friction/SKILL.md +14 -18
  205. package/.agents/skills/core/documentation-and-adrs/SKILL.md +25 -397
  206. package/.agents/skills/core/documentation-and-adrs/reference.md +403 -0
  207. package/.agents/skills/core/gates-and-baselines/SKILL.md +12 -12
  208. package/.agents/skills/core/idea-refinement/SKILL.md +3 -3
  209. package/.agents/skills/core/scope-triage/SKILL.md +3 -0
  210. package/.agents/skills/core/security-and-hardening/SKILL.md +22 -367
  211. package/.agents/skills/core/security-and-hardening/reference.md +375 -0
  212. package/.agents/skills/skills.index.json +2 -12
  213. package/.agents/skills/stack/qa/playwright-bdd/SKILL.md +2 -4
  214. package/.agents/skills/stack/qa/qa-explore-driving/SKILL.md +1 -1
  215. package/.agents/skills/stack/qa/qa-harness/SKILL.md +1 -3
  216. package/.agents/workflows/audit-architecture.md +3 -4
  217. package/.agents/workflows/audit-clean-code.md +4 -4
  218. package/.agents/workflows/audit-documentation.md +4 -5
  219. package/.agents/workflows/audit-lighthouse.md +8 -0
  220. package/.agents/workflows/audit-navigability.md +10 -0
  221. package/.agents/workflows/audit-performance.md +2 -3
  222. package/.agents/workflows/audit-quality.md +8 -9
  223. package/.agents/workflows/audit-security.md +1 -2
  224. package/.agents/workflows/audit-seo.md +10 -0
  225. package/.agents/workflows/audit-ux-ui.md +7 -0
  226. package/.agents/workflows/deliver.md +98 -45
  227. package/.agents/workflows/git-cleanup.md +2 -2
  228. package/.agents/workflows/git-deliver.md +1 -1
  229. package/.agents/workflows/helpers/acceptance-self-eval.md +21 -13
  230. package/.agents/workflows/helpers/code-quality-guardrails.md +7 -7
  231. package/.agents/workflows/helpers/code-review.md +12 -10
  232. package/.agents/workflows/helpers/deliver-story-reference.md +73 -32
  233. package/.agents/workflows/helpers/deliver-story.md +193 -118
  234. package/.agents/workflows/helpers/parallel-tooling.md +2 -2
  235. package/.agents/workflows/helpers/worktree-lifecycle.md +28 -32
  236. package/.agents/workflows/plan.md +184 -19
  237. package/.agents/workflows/qa-assist.md +6 -6
  238. package/.agents/workflows/qa-explore.md +3 -3
  239. package/.agents/workflows/qa-run.md +1 -5
  240. package/bin/mandrel.js +12 -1
  241. package/docs/CHANGELOG.md +40 -0
  242. package/lib/cli/registry.js +262 -19
  243. package/lib/cli/sync-agents.js +157 -0
  244. package/lib/cli/sync-commands.js +115 -6
  245. package/lib/cli/sync.js +168 -6
  246. package/lib/cli/update.js +105 -8
  247. package/lib/cli/version-helpers.js +131 -0
  248. package/lib/migrations/README.md +7 -5
  249. package/lib/migrations/index.js +12 -9
  250. package/lib/migrations/steps/2.1.0-retire-mi-drop-knobs.js +100 -0
  251. package/lib/migrations/steps/2.1.0-retire-verify-concurrency-cap.js +101 -0
  252. package/package.json +1 -1
  253. package/.agents/schemas/epic-perf-report.schema.json +0 -89
  254. package/.agents/schemas/lifecycle/acceptance.reconcile.failed.schema.json +0 -13
  255. package/.agents/schemas/lifecycle/acceptance.reconcile.ok.schema.json +0 -13
  256. package/.agents/schemas/lifecycle/acceptance.reconcile.skipped.schema.json +0 -13
  257. package/.agents/schemas/lifecycle/acceptance.reconcile.start.schema.json +0 -12
  258. package/.agents/schemas/lifecycle/acceptance.reconcile.waived.schema.json +0 -13
  259. package/.agents/schemas/lifecycle/epic.automerge.end.schema.json +0 -15
  260. package/.agents/schemas/lifecycle/epic.automerge.start.schema.json +0 -13
  261. package/.agents/schemas/lifecycle/epic.blocked.schema.json +0 -13
  262. package/.agents/schemas/lifecycle/epic.cleanup.end.schema.json +0 -12
  263. package/.agents/schemas/lifecycle/epic.cleanup.start.schema.json +0 -12
  264. package/.agents/schemas/lifecycle/epic.close.end.schema.json +0 -12
  265. package/.agents/schemas/lifecycle/epic.complete.schema.json +0 -13
  266. package/.agents/schemas/lifecycle/epic.finalize.end.schema.json +0 -13
  267. package/.agents/schemas/lifecycle/epic.finalize.start.schema.json +0 -12
  268. package/.agents/schemas/lifecycle/epic.merge.armed.schema.json +0 -13
  269. package/.agents/schemas/lifecycle/epic.merge.blocked.schema.json +0 -14
  270. package/.agents/schemas/lifecycle/epic.merge.confirmed.schema.json +0 -17
  271. package/.agents/schemas/lifecycle/epic.merge.ready.schema.json +0 -15
  272. package/.agents/schemas/lifecycle/epic.plan.end.schema.json +0 -18
  273. package/.agents/schemas/lifecycle/epic.plan.start.schema.json +0 -12
  274. package/.agents/schemas/lifecycle/epic.snapshot.end.schema.json +0 -16
  275. package/.agents/schemas/lifecycle/epic.snapshot.start.schema.json +0 -12
  276. package/.agents/schemas/lifecycle/epic.watch.end.schema.json +0 -29
  277. package/.agents/schemas/lifecycle/epic.watch.start.schema.json +0 -16
  278. package/.agents/schemas/lifecycle/story.heartbeat.schema.json +0 -20
  279. package/.agents/schemas/risk-verdict.schema.json +0 -53
  280. package/.agents/schemas/story-perf-summary.schema.json +0 -73
  281. package/.agents/scripts/analyze-execution.js +0 -444
  282. package/.agents/scripts/check-prepush-recovery.js +0 -90
  283. package/.agents/scripts/lib/git-merge-orchestrator.js +0 -261
  284. package/.agents/scripts/lib/observability/baseline-refresh-rate.js +0 -221
  285. package/.agents/scripts/lib/observability/hook-heartbeat.js +0 -187
  286. package/.agents/scripts/lib/observability/perf-aggregator.js +0 -813
  287. package/.agents/scripts/lib/observability/perf-report-readers.js +0 -328
  288. package/.agents/scripts/lib/observability/perf-report-render.js +0 -182
  289. package/.agents/scripts/lib/orchestration/audit-lens-routing.js +0 -128
  290. package/.agents/scripts/lib/orchestration/bookkeeping-outbox.js +0 -273
  291. package/.agents/scripts/lib/orchestration/error-journal.js +0 -139
  292. package/.agents/scripts/lib/orchestration/lifecycle/emit-story-heartbeat.js +0 -155
  293. package/.agents/scripts/lib/orchestration/lifecycle/ledger-diff.js +0 -140
  294. package/.agents/scripts/lib/orchestration/lifecycle/listeners/merge-watcher.js +0 -665
  295. package/.agents/scripts/lib/orchestration/plan-review-routing.js +0 -63
  296. package/.agents/scripts/lib/orchestration/planning/risk-verdict.js +0 -104
  297. package/.agents/scripts/lib/orchestration/planning-context-budget.js +0 -213
  298. package/.agents/scripts/lib/orchestration/planning-risk.js +0 -194
  299. package/.agents/scripts/lib/orchestration/post-merge/phases/branch-cleanup.js +0 -56
  300. package/.agents/scripts/lib/orchestration/post-merge/phases/dashboard-refresh.js +0 -21
  301. package/.agents/scripts/lib/orchestration/post-merge/phases/notification.js +0 -78
  302. package/.agents/scripts/lib/orchestration/post-merge/phases/temp-cleanup.js +0 -68
  303. package/.agents/scripts/lib/orchestration/post-merge/phases/ticket-closure.js +0 -118
  304. package/.agents/scripts/lib/orchestration/post-merge/phases/worktree-reap.js +0 -397
  305. package/.agents/scripts/lib/orchestration/preflight-cache.js +0 -187
  306. package/.agents/scripts/lib/orchestration/resolve-plan-run.js +0 -155
  307. package/.agents/scripts/lib/orchestration/retro-perf-heuristics.js +0 -275
  308. package/.agents/scripts/lib/orchestration/story-progress/story-run-progress-writer.js +0 -400
  309. package/.agents/scripts/lib/single-story/confirm-merge-follow-ups.js +0 -36
  310. package/.agents/scripts/resolve-plan-run.js +0 -117
  311. package/.agents/skills/core/analyze-execution/SKILL.md +0 -101
@@ -37,11 +37,12 @@ Audit findings become Stories via [`/audit-to-stories`](audit-to-stories.md)
37
37
  | --- | --- |
38
38
  | `--seed "<text>"` | Seed text for ideation. |
39
39
  | `--seed-file <path>` | Pre-authored notes / plan-seed path. |
40
- | `--tickets <ids>` | Comma-separated issue ids to analyze. |
41
- | `--force-review` | Force gate #2 operator review even when risk routing would skip it. |
40
+ | `--tickets <ids>` | Comma-separated issue ids to analyze. Closed as superseded at persist (see below). |
41
+ | `--no-close-superseded` | Keep the `--tickets` source issues open no supersede comment, no close. |
42
+ | `--force-review` | STOP at gate #2 for operator review of the assembled plan. The only thing that gates review — there is no risk-derived routing (Story #4542). |
42
43
  | `--allow-over-budget` | Permit a plan that exceeds `maxTickets` (rare N>1). |
43
44
  | `--yes` | Non-interactive: auto-proceed gate #1 and gate #2 HITL waits. |
44
- | `--dry-run` | Author + validate without GitHub writes. |
45
+ | `--dry-run` | Author + validate without GitHub writes. Run it as a pre-pass before every real persist (see below). |
45
46
 
46
47
  ## Default-single split policy
47
48
 
@@ -64,16 +65,24 @@ clarity, or reconciler ceremony for a single Story.
64
65
  ### 1. Interrogate
65
66
 
66
67
  ```bash
67
- node .agents/scripts/plan-context.js --seed "<seed>"
68
+ node .agents/scripts/plan-context.js --seed "<seed>" \
69
+ --out temp/plan-<slug>/plan-context.json
68
70
  # or: --seed-file <path>
69
71
  # or: --tickets 123,456
70
72
  ```
71
73
 
74
+ **Always pass `--out temp/plan-<slug>/plan-context.json`.** The CLI writes the
75
+ envelope there (creating parent dirs); persist auto-discovers that file from
76
+ `--plan-dir` and derives the `--tickets` source ids from its `sourceTickets[]`.
77
+ That is what makes superseding work without anyone re-typing ids
78
+ (Story #4554). The envelope still goes to stdout too, so piping is unaffected.
79
+
72
80
  The envelope carries docs context, codebase snapshot, BDD probe, risk
73
- heuristics, the story-author system prompt, and `duplicates[]` (open
74
- **Stories** whose title/body overlap the seed — never Epics). Under
75
- `--yes`, do not ask free-form operator questions unresolved unknowns
76
- land in Key Assumptions.
81
+ heuristics, the story-author system prompt, `sourceTickets[]` (`--tickets`
82
+ mode), and `duplicates[]` (open **Stories** whose title/body overlap the
83
+ seednever Epics).
84
+ Under `--yes`, do not ask free-form operator questions — unresolved
85
+ unknowns land in Key Assumptions.
77
86
 
78
87
  **Gate #1** — STOP to confirm the sharpened plan intent and any
79
88
  duplicate-candidate review. Under `--yes`, auto-proceed.
@@ -90,36 +99,192 @@ Write artifacts under `temp/plan-<slug>/`:
90
99
  `acceptance[]` / `verify[]` (persist syncs them into the body). Do not
91
100
  restate Goal/Acceptance inside Spec. Over-budget Specs fail closed —
92
101
  split the Story or tighten Spec; never write Specs under `docs/`.
93
- - `risk-verdict.json` — axes + summary only (**no `deliveryShape`**).
94
102
  - optional `techspec.md` — **N===1 only** convenience when Spec was authored
95
103
  outside the Story JSON; persist folds it into that Story's `## Spec`.
96
104
  Forbidden for N>1 (each Story must carry its own Spec).
97
- - optional `acceptance-manifest.json` — plan-level AC list for partition
98
- coverage when N>1.
105
+ - optional `acceptance-manifest.json` — plan-level AC list (a JSON
106
+ `string[]`) for partition coverage when N>1. Pass it to persist as
107
+ `--plan-acceptance` or it is not read.
99
108
 
100
109
  For N=1, use the envelope `systemPrompts.story` and emit one cohesive
101
110
  Story. Split only under the policy above.
102
111
 
112
+ **Tickets mode — author `supersedes[]` on every Story.** In `--tickets`
113
+ mode each Story carries a top-level `supersedes` array claiming the source
114
+ issues it replaces. It is bookkeeping, not part of the Story body, so it is
115
+ never serialized into the markdown:
116
+
117
+ ```jsonc
118
+ {
119
+ "slug": "close-superseded",
120
+ "supersedes": [
121
+ 4525,
122
+ { "id": 4529, "note": "The filed `--changed-only` fix is provably inert; the correction is recorded here." }
123
+ ]
124
+ }
125
+ ```
126
+
127
+ Entries are bare issue numbers, or `{ id, note }` when the plan has
128
+ something to say about *that* source issue — a correction to its analysis,
129
+ or why it was folded in with others. The optional `note` is rendered into
130
+ that issue's supersede comment, so planning that materially corrects a
131
+ source issue records the correction on the ticket rather than emitting
132
+ template-only prose.
133
+
134
+ ### Supersede-map partition
135
+
136
+ `plan-persist` refuses a partial supersede map **before** it creates any
137
+ Story (mirroring `assertAcceptancePartition`): every id passed to
138
+ `--tickets` must be claimed by **exactly one** Story, and no Story may
139
+ claim an id that was not a source ticket. With N>1 the mapping is not
140
+ total by default — an authored map is the only thing that can say
141
+ `#4525-#4528 → #4530` while `#4529 → #4531`, which a blanket "superseded by
142
+ this plan-run" reference could not.
143
+
103
144
  ### 3. Persist
104
145
 
105
- **Gate #2** — when risk routing requires review (or `--force-review`), STOP
106
- for operator approval of the assembled plan before persist. Under `--yes`, auto-proceed.
107
- N=1 low-risk plans typically skip this gate.
146
+ **Gate #2** — when the operator passed `--force-review`, STOP for approval of
147
+ the assembled plan before persist. Under `--yes`, auto-proceed.
148
+
149
+ `--force-review` is the **only** thing that raises this gate. Story #4542
150
+ retired the risk-derived alternative: the planner authored its own risk verdict,
151
+ persist computed a `requiresStop` from it *after* `createStoryIssues` had already
152
+ run, and nothing read the result — the STOP was prose executed by the same
153
+ session that wrote the verdict. A gate a plan can lower for itself is not a gate.
154
+
155
+ #### Dry-run pre-pass (always)
156
+
157
+ Run persist with `--dry-run` **before** the real one. It is the same command
158
+ with the same flags — only the GitHub writes are suppressed:
159
+
160
+ ```bash
161
+ node .agents/scripts/plan-persist.js \
162
+ --stories temp/plan-<slug>/stories.json \
163
+ [--plan-acceptance temp/plan-<slug>/acceptance-manifest.json] \
164
+ [--tech-spec temp/plan-<slug>/techspec.md] \
165
+ --plan-dir temp/plan-<slug> \
166
+ --dry-run
167
+ ```
168
+
169
+ Every gate — ticket validator, body parse, subject-prefix, DAG, capacity,
170
+ budget, reachability, split-policy and supersede partitions, Spec fold —
171
+ runs **before** the first `createIssue`, so a dry-run exercises all of them
172
+ write-free. An authoring mistake surfaces here, where the fix costs one
173
+ re-author, instead of after `k` of `N` Stories are already live.
174
+
175
+ #### The real persist
108
176
 
109
177
  ```bash
110
178
  node .agents/scripts/plan-persist.js \
111
179
  --stories temp/plan-<slug>/stories.json \
112
- --risk-verdict temp/plan-<slug>/risk-verdict.json \
180
+ [--plan-acceptance temp/plan-<slug>/acceptance-manifest.json] \
113
181
  [--tech-spec temp/plan-<slug>/techspec.md] \
114
182
  [--plan-dir temp/plan-<slug>] \
115
- [--dry-run] \
183
+ [--plan-context temp/plan-<slug>/plan-context.json] \
184
+ [--source-tickets 123,456] \
185
+ [--no-close-superseded] \
116
186
  [--force-review] \
117
187
  [--allow-over-budget]
118
188
  ```
119
189
 
120
- Persist creates Story issue(s) with `type::story` + `agent::ready`. When
121
- N>1 it also applies a shared `plan-run::<id>` label. Ends by naming
122
- `/deliver <storyId>` (or `/deliver --run <planRunId>` for N>1).
190
+ Pass `--plan-acceptance` whenever step 2 wrote an `acceptance-manifest.json`
191
+ it is what `assertAcceptancePartition` checks the N>1 split against.
192
+
193
+ Persist creates Story issue(s) with `type::story` (plus any sanitized
194
+ authored `labels[]`) and, when N>1, writes each authored `depends_on` edge
195
+ into the sibling's body as a `blocked by #<id>` footer — the ordering
196
+ `/deliver` resolves from. No batch label is applied (Story #4540 retired
197
+ `plan-run::<id>`). Ends by naming the exact command:
198
+ `/deliver <storyId> [<storyId> ...]`.
199
+
200
+ stdout is a pure JSON result; all log lines go to stderr, so a headless
201
+ driver can `JSON.parse` the stdout stream directly.
202
+
203
+ #### Ready means fully persisted
204
+
205
+ `agent::ready` is the **terminal** step, not part of the creating POST
206
+ (Story #4541). The order is: create unlabelled → upsert `story-plan-state` on
207
+ every Story → upsert `plan-summary` on the primary → flip every Story to
208
+ `agent::ready`.
209
+
210
+ This is what lets `/deliver` trust the label: a Story carrying
211
+ `agent::ready` always has its persist receipt on the ticket, so nothing can
212
+ pick it up mid-write and read a half-persisted plan.
213
+
214
+ #### Resuming a failed persist
215
+
216
+ Persist is **idempotent over the same authored artifacts**. Each created body
217
+ carries an invisible plan fingerprint (derived from the Story's slug +
218
+ title), and persist indexes the open `type::story` backlog by it before
219
+ creating anything.
220
+
221
+ So if a transient GitHub failure strands the run at Story `k` of `N`:
222
+
223
+ | | Behaviour |
224
+ | --- | --- |
225
+ | The `1..k-1` Stories | Live, but **not** `agent::ready` — invisible to `/deliver`, not half-delivered. |
226
+ | Re-running persist | Adopts them by fingerprint, creates only the missing ones, then flips the whole cohort ready. |
227
+ | Editing `stories.json` first | Changing a slug or title changes the fingerprint — the old issue is orphaned rather than adopted. Close it by hand. |
228
+
229
+ Just re-run the same command. Do not hand-delete the stranded issues first.
230
+
231
+ #### Temp hygiene
232
+
233
+ A terminal-success run deletes its own `--plan-dir`. Every persist also reaps
234
+ abandoned `temp/plan-*` directories older than 7 days, so dry-runs, failed
235
+ gates, and abandoned authoring sessions do not accumulate under `temp/`.
236
+
237
+ ### How the source ids reach persist
238
+
239
+ In `--tickets` mode persist needs to know which ids were fetched. It resolves
240
+ them **envelope-first** (Story #4554):
241
+
242
+ | Channel | When it wins |
243
+ | --- | --- |
244
+ | Envelope `sourceTickets[]` | **The normal path.** Written by step 1's `--out`, then read from `--plan-context <file>` or auto-discovered at `<plan-dir>/plan-context.json`. No ids to re-type. |
245
+ | `--source-tickets <ids>` | Explicit **override** for hand-driven runs (no captured envelope, or deliberately narrowing the set). Wins over the envelope; a disagreement is warned about, not silently reconciled. |
246
+
247
+ The result envelope's `supersede.sourceTicketOrigin` reports which channel was
248
+ used (`envelope` \| `flag` \| `none`).
249
+
250
+ Every path with no envelope is **audible** — persist cannot tell a legitimate
251
+ `--seed` run from a `--tickets` run whose envelope was never captured, so it
252
+ says so rather than deciding silently:
253
+
254
+ | Situation | Behaviour |
255
+ | --- | --- |
256
+ | Neither `--plan-dir` nor `--plan-context` | **Warn** — nothing was read; only `--source-tickets` can supply ids. |
257
+ | Auto-discovered `<plan-dir>/plan-context.json` absent | **Warn** — degrade to `--source-tickets`; a `--seed` run legitimately has none. |
258
+ | Explicit `--plan-context` missing | **Fatal** — the operator named a file and meant it. |
259
+ | Envelope present but unparseable | **Fatal** — a corrupt envelope is not "no source tickets"; treating it as such is how a `--tickets` run used to report success having superseded nothing. |
260
+
261
+ Whichever channel supplies them, the supersede-map partition above still
262
+ fail-closes: a `--tickets` run whose Stories forgot `supersedes[]` is now
263
+ **caught** (`source ticket #N is not claimed by any Story`) instead of
264
+ partitioning an empty set and passing vacuously.
265
+
266
+ ### Closing superseded source tickets
267
+
268
+ **Default on.** After the Stories exist, persist comments on each source
269
+ issue naming the specific Story that claims it — plus that Story's optional
270
+ per-supersede `note` — and closes it with reason **`not_planned`**
271
+ (`state_reason`). Nothing has shipped at persist time and the issue will not
272
+ be actioned in its own right, so `not_planned` is the honest reason;
273
+ `completed` would be a lie. This is what keeps the tracker from asserting
274
+ that already-planned work is still unowned, and it writes down the supersede
275
+ link that makes the history readable.
276
+
277
+ | Behaviour | Contract |
278
+ | --- | --- |
279
+ | Default | Comment + close every source ticket as `not_planned`. |
280
+ | `--no-close-superseded` | Skips all commenting and closing. Story creation is unchanged. Use it for a genuinely partial supersede — when the plan folded in only *part* of an issue and the remainder must stay open. |
281
+ | `--dry-run` | Posts no comment and closes nothing; reports what it would have done. |
282
+ | Re-run | Idempotent — the comment is keyed off a `superseded-by` structured-comment marker, and an already-closed source is skipped. |
283
+ | Already closed / deleted / inaccessible | Skipped and reported. Never throws. |
284
+ | Close-phase failure | **Never fails the run.** Stories stay created; the result envelope's `supersede` report names which tickets were and were not closed so the operator can finish by hand. |
285
+
286
+ `--seed` / `--seed-file` modes have no source tickets, so no close phase
287
+ runs at all.
123
288
 
124
289
  ## Constraints
125
290
 
@@ -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 the agent route the full ledger
24
- into [`/plan`](plan.md) to generate Epics and/or Stories.
24
+ into [`/plan`](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
@@ -224,13 +224,13 @@ every decision to the shared core helpers; never re-derive them in prose.
224
224
 
225
225
  3. **Hydrate the QA context** to locate code precisely, via
226
226
  [`qa-context-hydrator.js`](../scripts/lib/qa/qa-context-hydrator.js) — it
227
- resolves the Epic (whose body carries the planning sections), the
227
+ resolves the source ticket body, the
228
228
  feature-file set, the surface
229
229
  map, and recent git log:
230
230
 
231
231
  ```js
232
232
  import { hydrateQaContext } from '../scripts/lib/qa/qa-context-hydrator.js';
233
- const context = await hydrateQaContext({ epicNumber, githubPort, gitPort, surfaceMap });
233
+ const context = await hydrateQaContext({ ticketNumber, githubPort, gitPort, surfaceMap });
234
234
  ```
235
235
 
236
236
  4. **Compute the coverage verdict** for the surface the observation points at,
@@ -320,20 +320,20 @@ its transition is **explicitly operator-gated**.
320
320
  const { promotions } = await promoteFindings(ledgerItems, {
321
321
  searchIssues, // GitHub provider, open + closed
322
322
  createStory, // tight cluster (≤2 surfaces): seed → /plan --seed-file
323
- createEpic, // broad cluster (>2 surfaces): same /plan --seed-file path (may N>1)
323
+ createPlanSeed, // broad cluster (>2 surfaces): same /plan --seed-file path (may N>1)
324
324
  });
325
325
  ```
326
326
 
327
327
  - **Sizing is delegated, not decided in prose.** `promoteFindings` runs
328
328
  `clusterLedgerItems` + `targetForCluster`: a cluster spanning **≤2**
329
329
  distinct coverage surfaces routes to `createStory`; **>2** routes to
330
- `createEpic`. Neither port opens an Epic ticket — both chain
330
+ `createPlanSeed`. Neither port opens an Epic ticket — both chain
331
331
  `/plan --seed-file`. Do not re-cluster, re-size, or re-dedup in the
332
332
  workflow —
333
333
  [`route-finding.js`](../scripts/lib/findings/route-finding.js) /
334
334
  [`promote-finding.js`](../scripts/lib/findings/promote-finding.js) are the
335
335
  single implementation.
336
- - **`createStory` / `createEpic` (`/plan --seed-file`)** — render a
336
+ - **`createStory` / `createPlanSeed` (`/plan --seed-file`)** — render a
337
337
  **redacted** plan seed from the cluster (reuse the `/audit-to-stories`
338
338
  Phase 5a seed shape; redaction already ran in Phase 2), **stamp the
339
339
  cluster's `fingerprintFooter(sha)` verbatim into the seed body**, then
@@ -338,18 +338,18 @@ For each untriaged ledger item:
338
338
  const { promotions } = await promoteFindings(ledgerItems, {
339
339
  searchIssues, // GitHub provider, open + closed
340
340
  createStory, // tight cluster (≤2 surfaces): seed → /plan --seed-file
341
- createEpic, // broad cluster (>2 surfaces): same /plan --seed-file path (may N>1)
341
+ createPlanSeed, // broad cluster (>2 surfaces): same /plan --seed-file path (may N>1)
342
342
  });
343
343
  ```
344
344
 
345
345
  - **Sizing is delegated, not decided in prose.** `promoteFindings` runs
346
346
  `clusterLedgerItems` + `targetForCluster`: a cluster spanning **≤2**
347
347
  distinct coverage surfaces routes to `createStory`; **>2** routes to
348
- `createEpic`. Neither port opens an Epic ticket — both chain
348
+ `createPlanSeed`. Neither port opens an Epic ticket — both chain
349
349
  `/plan --seed-file`. The workflow introduces no new sizing, clustering,
350
350
  or dedup logic — `route-finding.js` / `promote-finding.js` remain the
351
351
  single implementation.
352
- - **`createStory` / `createEpic` (`/plan --seed-file`)** — render a
352
+ - **`createStory` / `createPlanSeed` (`/plan --seed-file`)** — render a
353
353
  **redacted** plan seed from the cluster (reuse the `/audit-to-stories`
354
354
  Phase 5a seed shape; redaction already ran in Capture), **stamp the
355
355
  cluster's `fingerprintFooter(sha)` verbatim into the seed body**, then
@@ -382,16 +382,12 @@ For each untriaged ledger item:
382
382
  same cluster/size/route/file path `/qa-explore` and `/audit-to-stories`
383
383
  consume (`clusterLedgerItems` + `targetForCluster`: a cluster spanning ≤2
384
384
  coverage surfaces routes to `createStory` via `/plan --seed-file`, >2 to
385
- `createEpic` via `/plan --seed`, with the cluster's `fingerprintFooter(sha)`
385
+ `createPlanSeed` via `/plan --seed`, with the cluster's `fingerprintFooter(sha)`
386
386
  stamped verbatim into the seed). A `file` disposition never opens a raw
387
387
  GitHub Issue; only `defer` and `dismiss` skip the `/plan` handoff.
388
388
  5. **Gate:** any ticket-filing, seed write, `/plan` invocation, or label
389
389
  mutation is a write — confirm each with the operator before it happens.
390
390
 
391
- If the run was triggered from an Epic-testing context, hand the approved,
392
- promoted findings to the Epic-testing helper for attachment to the Epic's QA
393
- evidence ticket.
394
-
395
391
  ## Step 6 — Report
396
392
 
397
393
  Summarize the sweep in chat with:
package/bin/mandrel.js CHANGED
@@ -57,7 +57,18 @@ const SUBCOMMANDS = new Map([
57
57
  'sync-commands',
58
58
  {
59
59
  description: 'regenerate .claude/commands/ from .agents/workflows/',
60
- knownFlags: new Set(['--dry-run']),
60
+ // No --dry-run: the projection scripts have no preview mode, and
61
+ // accepting the flag while syncing for real overwrote .claude/ on an
62
+ // operator who asked for a preview. Reject it at the dispatcher.
63
+ knownFlags: new Set([]),
64
+ },
65
+ ],
66
+ [
67
+ 'sync-agents',
68
+ {
69
+ description: 'regenerate .claude/agents/ from .agents/agents/',
70
+ // Same contract as sync-commands: no preview mode, so no --dry-run.
71
+ knownFlags: new Set([]),
61
72
  },
62
73
  ],
63
74
  [
package/docs/CHANGELOG.md CHANGED
@@ -2,6 +2,46 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
+ ## [2.1.0](https://github.com/dsj1984/mandrel/compare/mandrel-v2.0.0...mandrel-v2.1.0) (2026-07-17)
6
+
7
+
8
+ ### ⚠ BREAKING CHANGES
9
+
10
+ * **plan:** plan-persist.js no longer accepts --risk-verdict and no plan-time step authors a risk verdict; review depth and the acceptance critic mode are derived from the diff at close time.
11
+ * /deliver no longer accepts --run <planRunId> or --dep, and /plan no longer applies a plan-run::<id> label. Deliver Story ids; the graph resolves itself from live state.
12
+
13
+ ### Added
14
+
15
+ * /deliver takes only Story ids and resolves dependencies dynamically (retire plan-run) ([#4540](https://github.com/dsj1984/mandrel/issues/4540)) ([#4560](https://github.com/dsj1984/mandrel/issues/4560)) ([e9935cc](https://github.com/dsj1984/mandrel/commit/e9935cc332b43862d79dca9979691077327e1882))
16
+ * **dead-exports:** add a production-mode pass that discounts test-only importers (refs [#4575](https://github.com/dsj1984/mandrel/issues/4575)) ([#4582](https://github.com/dsj1984/mandrel/issues/4582)) ([0a77ca9](https://github.com/dsj1984/mandrel/commit/0a77ca91bdd67a294b66cc076e45c43bc4d691c8))
17
+ * **deliver:** script-owned land tail, resumable pending status, terminal envelope, and deliver-recover ([#4543](https://github.com/dsj1984/mandrel/issues/4543)) ([#4566](https://github.com/dsj1984/mandrel/issues/4566)) ([f234306](https://github.com/dsj1984/mandrel/commit/f234306d1465fe96d19d361f1501ad8edf055cc3))
18
+ * **plan:** close --tickets source issues as superseded by default ([#4535](https://github.com/dsj1984/mandrel/issues/4535)) ([#4553](https://github.com/dsj1984/mandrel/issues/4553)) ([c35e298](https://github.com/dsj1984/mandrel/commit/c35e29880edba4fec0c45687071fbea242236370))
19
+ * **plan:** mirror sibling depends_on into native blocked_by edges (refs [#4544](https://github.com/dsj1984/mandrel/issues/4544)) ([#4570](https://github.com/dsj1984/mandrel/issues/4570)) ([6b94968](https://github.com/dsj1984/mandrel/commit/6b949688e4fd487c979044f2473e3837a4637e1a))
20
+
21
+
22
+ ### Fixed
23
+
24
+ * **bootstrap:** honor command:false in the workflow/command parity check ([#4588](https://github.com/dsj1984/mandrel/issues/4588)) ([493b3eb](https://github.com/dsj1984/mandrel/commit/493b3eb039eefabbd2e33af6a08933d43876c052))
25
+ * **cli:** resolve versions from the consumer, not the running CLI — and make the sync surface fail loudly on skew ([#4530](https://github.com/dsj1984/mandrel/issues/4530)) ([#4536](https://github.com/dsj1984/mandrel/issues/4536)) ([5f20563](https://github.com/dsj1984/mandrel/commit/5f20563eca79203096b49e8fa3dfaa64e2487e12))
26
+ * **cli:** stop sync pruning generated .agents/ files — declare a never-pruned registry so the install ledger survives ([#4534](https://github.com/dsj1984/mandrel/issues/4534)) ([#4552](https://github.com/dsj1984/mandrel/issues/4552)) ([ceccd57](https://github.com/dsj1984/mandrel/commit/ceccd572614a7d8c5226bdd9f1a3b793381be4dd))
27
+ * **column-sync:** stop two more test suites leaking into the shared meta cache ([#4561](https://github.com/dsj1984/mandrel/issues/4561)) ([757e509](https://github.com/dsj1984/mandrel/commit/757e509ff4aa95a091fe9a5de053396a78a26793)), closes [#4555](https://github.com/dsj1984/mandrel/issues/4555)
28
+ * **deliver:** diff the plan-run epilogue against the pre-run base, not origin/main...HEAD (refs [#4550](https://github.com/dsj1984/mandrel/issues/4550)) ([#4558](https://github.com/dsj1984/mandrel/issues/4558)) ([79ddbf6](https://github.com/dsj1984/mandrel/commit/79ddbf61d19bdf256a06aabb860651be6bdce94b))
29
+ * **deliver:** ground the audit roster's lens selection in the landed diff (refs [#4571](https://github.com/dsj1984/mandrel/issues/4571)) ([#4573](https://github.com/dsj1984/mandrel/issues/4573)) ([fa06aca](https://github.com/dsj1984/mandrel/commit/fa06acaedc0c3070516ec32d447f0755a06ea0eb))
30
+ * **deliver:** repair the close-and-land default path (config, operator-merge, follow-ups, reap, reporting) ([#4539](https://github.com/dsj1984/mandrel/issues/4539)) ([#4551](https://github.com/dsj1984/mandrel/issues/4551)) ([9b5c3ee](https://github.com/dsj1984/mandrel/commit/9b5c3ee61b2030e96ff88091761b258eb43fdf43))
31
+ * make `npm run verify` a true CI mirror: include dead-exports + arch-cycles (or catalogue them as CI-only) ([#4549](https://github.com/dsj1984/mandrel/issues/4549)) ([#4557](https://github.com/dsj1984/mandrel/issues/4557)) ([70d088a](https://github.com/dsj1984/mandrel/commit/70d088a646fd1867f3d536c541f89c1c49b0b866))
32
+ * **plan:** make persist resumable and align its gates with the authoring contract ([#4541](https://github.com/dsj1984/mandrel/issues/4541)) ([#4565](https://github.com/dsj1984/mandrel/issues/4565)) ([1cbe974](https://github.com/dsj1984/mandrel/commit/1cbe974154403edab14e006e83f42a5c414150d1))
33
+ * **plan:** make the fan-out deletion gate count importers, not basename word matches ([#4547](https://github.com/dsj1984/mandrel/issues/4547)) ([#4567](https://github.com/dsj1984/mandrel/issues/4567)) ([4c5c724](https://github.com/dsj1984/mandrel/commit/4c5c7248e88136bac83cd91db38658390139c588))
34
+ * **plan:** thread sourceTickets through the envelope so --tickets superseding cannot silently no-op ([#4554](https://github.com/dsj1984/mandrel/issues/4554)) ([#4559](https://github.com/dsj1984/mandrel/issues/4559)) ([4546c40](https://github.com/dsj1984/mandrel/commit/4546c405b2131f6c5afd3ccf40bccb357f4223a0))
35
+ * **quality:** retire the unconsumed miDropMustRefactor/miDropCap knobs and make maintainability.tolerance the single MI-drop control ([#4531](https://github.com/dsj1984/mandrel/issues/4531)) ([#4548](https://github.com/dsj1984/mandrel/issues/4548)) ([fe0c7ce](https://github.com/dsj1984/mandrel/commit/fe0c7ce3ad40e21b957cd6d0a916efbc5e75f634))
36
+ * **skills-index:** emit biome-formatted JSON so regeneration leaves no drift (refs [#4546](https://github.com/dsj1984/mandrel/issues/4546)) ([#4568](https://github.com/dsj1984/mandrel/issues/4568)) ([bdb223e](https://github.com/dsj1984/mandrel/commit/bdb223e2979c0d386ca260b6743cdf2062dbff09))
37
+
38
+
39
+ ### Changed
40
+
41
+ * **checks:** drop the dead epic merge-lock and epic-branch probes ([#4581](https://github.com/dsj1984/mandrel/issues/4581)) ([28cb4ab](https://github.com/dsj1984/mandrel/commit/28cb4abf4aa9c0c0120598c26dd5b7220b195678))
42
+ * **docs:** move weight out of always-loaded prompts and skill essays into on-demand references ([#4546](https://github.com/dsj1984/mandrel/issues/4546)) ([#4564](https://github.com/dsj1984/mandrel/issues/4564)) ([14381b3](https://github.com/dsj1984/mandrel/commit/14381b3efd7ce774e39dd47f535bb55991387617))
43
+ * **plan:** derive review depth from the diff and retire the authored risk verdict (refs [#4542](https://github.com/dsj1984/mandrel/issues/4542)) ([#4569](https://github.com/dsj1984/mandrel/issues/4569)) ([7a7fb50](https://github.com/dsj1984/mandrel/commit/7a7fb50f7ec0e33d616fa54618fc0b93c2e310a6))
44
+
5
45
  ## [2.0.0](https://github.com/dsj1984/mandrel/compare/mandrel-v1.94.0...mandrel-v2.0.0) (2026-07-14)
6
46
 
7
47