mandrel 2.0.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.agents/README.md +59 -28
- package/.agents/agents/acceptance-critic.md +20 -9
- package/.agents/agents/story-worker.md +45 -48
- package/.agents/audit-checklists/performance.md +1 -1
- package/.agents/docs/SDLC.md +60 -46
- package/.agents/docs/agentrc-reference.json +8 -13
- package/.agents/docs/configuration.md +33 -57
- package/.agents/docs/execution-reference.md +39 -10
- package/.agents/docs/quality-gates.md +17 -19
- package/.agents/docs/workflows.md +6 -6
- package/.agents/instructions.md +64 -79
- package/.agents/rules/ci-remediation.md +3 -3
- package/.agents/rules/gherkin-standards.md +10 -0
- package/.agents/rules/git-conventions-reference.md +42 -51
- package/.agents/schemas/acceptance-eval-verdict.schema.json +2 -2
- package/.agents/schemas/agentrc.schema.json +35 -46
- package/.agents/schemas/audit-rules.json +59 -1
- package/.agents/schemas/audit-rules.schema.json +33 -1
- package/.agents/schemas/lifecycle/README.md +1 -2
- package/.agents/schemas/lifecycle/ledger-record.schema.json +1 -1
- package/.agents/schemas/lifecycle/merge.flip-failed.schema.json +33 -0
- package/.agents/schemas/lifecycle/merge.unlanded.schema.json +1 -0
- package/.agents/schemas/lifecycle/story.merged.schema.json +1 -1
- package/.agents/schemas/signal-event.schema.json +3 -3
- package/.agents/schemas/story-deliver-terminal.schema.json +152 -0
- package/.agents/schemas/validation-evidence.schema.json +1 -1
- package/.agents/scripts/acceptance-eval.js +24 -68
- package/.agents/scripts/agents-bootstrap-github.js +1 -1
- package/.agents/scripts/bootstrap.js +3 -3
- package/.agents/scripts/check-dead-exports.js +43 -104
- package/.agents/scripts/check-doc-links.js +2 -2
- package/.agents/scripts/check-lifecycle-lint.js +1 -1
- package/.agents/scripts/check-workflow-cli-lint.js +91 -0
- package/.agents/scripts/deliver-recover.js +122 -0
- package/.agents/scripts/drain-pending-cleanup.js +1 -1
- package/.agents/scripts/evidence-gate.js +20 -50
- package/.agents/scripts/generate-skills-index.js +17 -1
- package/.agents/scripts/generate-workflows-doc.js +4 -4
- package/.agents/scripts/lib/ITicketingProvider.js +1 -19
- package/.agents/scripts/lib/audit-suite/selector.js +323 -23
- package/.agents/scripts/lib/baselines/kinds/maintainability.js +0 -11
- package/.agents/scripts/lib/bootstrap/ci-workflow-template.js +28 -33
- package/.agents/scripts/lib/bootstrap/manifest.js +8 -11
- package/.agents/scripts/lib/bootstrap/project-bootstrap.js +30 -53
- package/.agents/scripts/lib/bootstrap/quality-bootstrap.js +0 -2
- package/.agents/scripts/lib/checks/core-bare-clean.js +4 -1
- package/.agents/scripts/lib/checks/index.js +1 -1
- package/.agents/scripts/lib/checks/loop-health.js +12 -11
- package/.agents/scripts/lib/checks/state.js +17 -248
- package/.agents/scripts/lib/checks/story-init-not-backgrounded.js +3 -3
- package/.agents/scripts/lib/checks/subagent-agent-tool-required.js +3 -4
- package/.agents/scripts/lib/checks/worktree-bootstrap-env.js +2 -2
- package/.agents/scripts/lib/checks/worktree-residue-biome.js +3 -3
- package/.agents/scripts/lib/cli-args.js +23 -2
- package/.agents/scripts/lib/close-validation/gates.js +13 -13
- package/.agents/scripts/lib/close-validation/projections/inputs.js +7 -7
- package/.agents/scripts/lib/close-validation/projections/maintainability.js +12 -12
- package/.agents/scripts/lib/close-validation/runner.js +13 -21
- package/.agents/scripts/lib/close-validation/telemetry.js +17 -8
- package/.agents/scripts/lib/config/acceptance-eval.js +2 -2
- package/.agents/scripts/lib/config/delivery-routing.js +7 -6
- package/.agents/scripts/lib/config/explain.js +10 -16
- package/.agents/scripts/lib/config/github.js +7 -5
- package/.agents/scripts/lib/config/limits.js +15 -25
- package/.agents/scripts/lib/config/quality.js +11 -14
- package/.agents/scripts/lib/config/runners.js +8 -21
- package/.agents/scripts/lib/config/temp-paths.js +18 -56
- package/.agents/scripts/lib/config-settings-schema-delivery.js +34 -16
- package/.agents/scripts/lib/config-settings-schema-quality.js +9 -2
- package/.agents/scripts/lib/config-settings-schema.js +48 -22
- package/.agents/scripts/lib/dead-exports-knip.js +105 -0
- package/.agents/scripts/lib/dead-exports-mode.js +51 -0
- package/.agents/scripts/lib/duplicate-search.js +38 -7
- package/.agents/scripts/lib/findings/promote-finding.js +23 -14
- package/.agents/scripts/lib/format-generated-json.js +97 -0
- package/.agents/scripts/lib/framework-version.js +19 -189
- package/.agents/scripts/lib/gh-exec.js +8 -0
- package/.agents/scripts/lib/git-branch-lifecycle.js +0 -158
- package/.agents/scripts/lib/git-utils.js +0 -14
- package/.agents/scripts/lib/json-utils.js +1 -2
- package/.agents/scripts/lib/label-constants.js +0 -15
- package/.agents/scripts/lib/label-taxonomy.js +1 -12
- package/.agents/scripts/lib/observability/active-story-env.js +42 -163
- package/.agents/scripts/lib/observability/runtime-friction.js +243 -0
- package/.agents/scripts/lib/observability/signal-validator.js +4 -4
- package/.agents/scripts/lib/observability/signals-writer.js +6 -82
- package/.agents/scripts/lib/observability/source-classifier.js +2 -2
- package/.agents/scripts/lib/observability/tool-trace-hook.js +2 -12
- package/.agents/scripts/lib/orchestration/acceptance-clusters.js +1 -1
- package/.agents/scripts/lib/orchestration/acceptance-eval-decision.js +2 -2
- package/.agents/scripts/lib/orchestration/ceremony-routing.js +43 -45
- package/.agents/scripts/lib/orchestration/change-set.js +103 -0
- package/.agents/scripts/lib/orchestration/code-review.js +70 -191
- package/.agents/scripts/lib/orchestration/consolidation-precondition.js +3 -3
- package/.agents/scripts/lib/orchestration/deliver-recover.js +328 -0
- package/.agents/scripts/lib/orchestration/detectors-phase.js +12 -6
- package/.agents/scripts/lib/orchestration/git-cleanup/phases/fast-forward.js +34 -0
- package/.agents/scripts/lib/orchestration/lease-guard-shared.js +3 -2
- package/.agents/scripts/lib/orchestration/lifecycle/emit-ledger-event.js +142 -0
- package/.agents/scripts/lib/orchestration/lifecycle/emit-loop-tick.js +9 -11
- package/.agents/scripts/lib/orchestration/lifecycle/emit-merge-flip-failed.js +86 -0
- package/.agents/scripts/lib/orchestration/lifecycle/emit-merge-unlanded.js +37 -103
- package/.agents/scripts/lib/orchestration/lifecycle/listeners/README.md +7 -3
- package/.agents/scripts/lib/orchestration/lifecycle/listeners/watcher.js +50 -85
- package/.agents/scripts/lib/orchestration/lifecycle/trace-logger.js +3 -14
- package/.agents/scripts/lib/orchestration/merge-block-class.js +76 -20
- package/.agents/scripts/lib/orchestration/merge-poll.js +104 -0
- package/.agents/scripts/lib/orchestration/plan-context.js +116 -33
- package/.agents/scripts/lib/orchestration/plan-critic-conditions.js +26 -36
- package/.agents/scripts/lib/orchestration/plan-critics-evaluate.js +31 -22
- package/.agents/scripts/lib/orchestration/plan-metrics.js +38 -6
- package/.agents/scripts/lib/orchestration/plan-persist/fan-out-gate.js +16 -6
- package/.agents/scripts/lib/orchestration/plan-persist/persist-helpers.js +173 -25
- package/.agents/scripts/lib/orchestration/plan-persist/plan-context-source.js +116 -0
- package/.agents/scripts/lib/orchestration/plan-persist/run-plan-persist.js +280 -100
- package/.agents/scripts/lib/orchestration/plan-persist/story-ops.js +472 -55
- package/.agents/scripts/lib/orchestration/plan-persist/summary.js +21 -16
- package/.agents/scripts/lib/orchestration/plan-persist/supersede-ops.js +509 -0
- package/.agents/scripts/lib/orchestration/plan-text-hygiene.js +230 -0
- package/.agents/scripts/lib/orchestration/planning/authoring-context.js +41 -40
- package/.agents/scripts/lib/orchestration/planning/decomposer-context.js +1 -2
- package/.agents/scripts/lib/orchestration/planning/spec-authoring-grounding.js +1 -1
- package/.agents/scripts/lib/orchestration/resolve-stories.js +344 -0
- package/.agents/scripts/lib/orchestration/retro-proposals.js +7 -7
- package/.agents/scripts/lib/orchestration/review-depth.js +105 -40
- package/.agents/scripts/lib/orchestration/review-providers/findings-renderer.js +3 -13
- package/.agents/scripts/lib/orchestration/review-providers/native.js +1 -154
- package/.agents/scripts/lib/orchestration/review-providers/review-depth.js +3 -2
- package/.agents/scripts/lib/orchestration/review-providers/security-review.js +1 -1
- package/.agents/scripts/lib/orchestration/review-providers/types.js +5 -4
- package/.agents/scripts/lib/orchestration/review-providers/ultrareview.js +1 -1
- package/.agents/scripts/lib/orchestration/run-epilogue.js +374 -16
- package/.agents/scripts/lib/orchestration/single-story-close/phases/auto-merge.js +24 -0
- package/.agents/scripts/lib/orchestration/single-story-close/phases/base-sync.js +11 -9
- package/.agents/scripts/lib/orchestration/single-story-close/phases/close-validation.js +4 -4
- package/.agents/scripts/lib/orchestration/single-story-close/phases/code-review.js +4 -13
- package/.agents/scripts/lib/orchestration/single-story-close/phases/confirm-merge.js +608 -152
- package/.agents/scripts/lib/orchestration/single-story-close/phases/options.js +72 -30
- package/.agents/scripts/lib/orchestration/single-story-close/phases/post-land.js +305 -0
- package/.agents/scripts/lib/orchestration/single-story-close/phases/pull-request.js +1 -1
- package/.agents/scripts/lib/orchestration/single-story-close/phases/review-block.js +12 -8
- package/.agents/scripts/lib/orchestration/single-story-close/phases/worktree-reap.js +37 -4
- package/.agents/scripts/lib/orchestration/single-story-close/phases/wrong-tree-guard.js +2 -2
- package/.agents/scripts/lib/orchestration/single-story-close/runner.js +264 -43
- package/.agents/scripts/lib/orchestration/single-story-lease-guard.js +1 -1
- package/.agents/scripts/lib/orchestration/story-close/format-autofix.js +10 -10
- package/.agents/scripts/lib/orchestration/story-close/phases/code-review.js +104 -279
- package/.agents/scripts/lib/orchestration/story-close/phases/local-lens-review.js +191 -0
- package/.agents/scripts/lib/orchestration/story-close/phases/review-core.js +120 -0
- package/.agents/scripts/lib/orchestration/story-deliver-terminal.js +360 -0
- package/.agents/scripts/lib/orchestration/story-follow-ups.js +75 -14
- package/.agents/scripts/lib/orchestration/story-init-remote.js +12 -8
- package/.agents/scripts/lib/orchestration/story-plan-state.js +14 -29
- package/.agents/scripts/lib/orchestration/task-body-validator.js +52 -7
- package/.agents/scripts/lib/orchestration/ticket-lease.js +27 -74
- package/.agents/scripts/lib/orchestration/ticket-validator-conflicts.js +119 -14
- package/.agents/scripts/lib/orchestration/ticket-validator-sizing.js +3 -4
- package/.agents/scripts/lib/orchestration/ticket-validator.js +121 -18
- package/.agents/scripts/lib/orchestration/ticketing/bulk.js +14 -47
- package/.agents/scripts/lib/orchestration/ticketing/reads.js +19 -32
- package/.agents/scripts/lib/orchestration/ticketing/transition.js +61 -1
- package/.agents/scripts/lib/orchestration/ticketing.js +0 -1
- package/.agents/scripts/lib/plan-phase-cleanup.js +12 -14
- package/.agents/scripts/lib/planning-corpus.js +12 -286
- package/.agents/scripts/lib/preflight-runner.js +2 -2
- package/.agents/scripts/lib/qa/qa-context-hydrator.js +5 -5
- package/.agents/scripts/lib/signals/index.js +4 -17
- package/.agents/scripts/lib/signals/read.js +35 -35
- package/.agents/scripts/lib/signals/schema.js +8 -11
- package/.agents/scripts/lib/signals/span-tree.js +7 -7
- package/.agents/scripts/lib/signals/write.js +0 -1
- package/.agents/scripts/lib/single-story/story-merged-notify.js +13 -2
- package/.agents/scripts/lib/skills/parse-skill.js +16 -3
- package/.agents/scripts/lib/story-adjacency.js +8 -7
- package/.agents/scripts/lib/story-body/story-body.js +81 -13
- package/.agents/scripts/lib/templates/decomposer-prompts.js +15 -16
- package/.agents/scripts/lib/test-env.js +14 -1
- package/.agents/scripts/lib/test-tiers.js +0 -3
- package/.agents/scripts/lib/ticket-body-sections.js +0 -14
- package/.agents/scripts/lib/validation-evidence.js +31 -59
- package/.agents/scripts/lib/wave-runner/live-probe.js +315 -0
- package/.agents/scripts/lib/wave-runner/ready-set.js +32 -6
- package/.agents/scripts/lib/worktree/lifecycle/pending-cleanup.js +1 -1
- package/.agents/scripts/lib/worktree/lifecycle/reap.js +68 -19
- package/.agents/scripts/lib/worktree/lifecycle-manager.js +1 -2
- package/.agents/scripts/plan-context.js +38 -7
- package/.agents/scripts/plan-critics.js +203 -0
- package/.agents/scripts/plan-persist.js +145 -35
- package/.agents/scripts/plan-run-epilogue.js +83 -38
- package/.agents/scripts/post-structured-comment.js +0 -38
- package/.agents/scripts/pr-watch-with-update.js +43 -22
- package/.agents/scripts/providers/github/compose.js +0 -1
- package/.agents/scripts/providers/github/errors.js +0 -19
- package/.agents/scripts/providers/github/issues.js +1 -11
- package/.agents/scripts/providers/github/mappers.js +5 -0
- package/.agents/scripts/providers/github/sub-issues.js +0 -47
- package/.agents/scripts/providers/github/tickets.js +33 -153
- package/.agents/scripts/providers/github.js +17 -6
- package/.agents/scripts/quality-preview.js +13 -6
- package/.agents/scripts/resolve-stories.js +236 -0
- package/.agents/scripts/run-coverage.js +4 -1
- package/.agents/scripts/run-lint.js +2 -2
- package/.agents/scripts/run-verify.js +31 -2
- package/.agents/scripts/signals-view.js +9 -10
- package/.agents/scripts/single-story-close.js +173 -18
- package/.agents/scripts/single-story-confirm-merge.js +288 -15
- package/.agents/scripts/single-story-init.js +6 -10
- package/.agents/scripts/stories-wave-tick.js +380 -53
- package/.agents/scripts/story-plan.js +3 -3
- package/.agents/scripts/update-ticket-state.js +8 -50
- package/.agents/skills/core/code-review-and-quality/SKILL.md +28 -450
- package/.agents/skills/core/code-review-and-quality/reference.md +458 -0
- package/.agents/skills/core/debugging-and-error-recovery/SKILL.md +22 -315
- package/.agents/skills/core/debugging-and-error-recovery/reference.md +323 -0
- package/.agents/skills/core/diagnose-friction/SKILL.md +14 -18
- package/.agents/skills/core/documentation-and-adrs/SKILL.md +25 -397
- package/.agents/skills/core/documentation-and-adrs/reference.md +403 -0
- package/.agents/skills/core/gates-and-baselines/SKILL.md +12 -12
- package/.agents/skills/core/idea-refinement/SKILL.md +3 -3
- package/.agents/skills/core/scope-triage/SKILL.md +3 -0
- package/.agents/skills/core/security-and-hardening/SKILL.md +22 -367
- package/.agents/skills/core/security-and-hardening/reference.md +375 -0
- package/.agents/skills/skills.index.json +2 -12
- package/.agents/skills/stack/qa/playwright-bdd/SKILL.md +2 -4
- package/.agents/skills/stack/qa/qa-explore-driving/SKILL.md +1 -1
- package/.agents/skills/stack/qa/qa-harness/SKILL.md +1 -3
- package/.agents/workflows/audit-architecture.md +3 -4
- package/.agents/workflows/audit-clean-code.md +4 -4
- package/.agents/workflows/audit-documentation.md +4 -5
- package/.agents/workflows/audit-lighthouse.md +8 -0
- package/.agents/workflows/audit-navigability.md +10 -0
- package/.agents/workflows/audit-performance.md +2 -3
- package/.agents/workflows/audit-quality.md +8 -9
- package/.agents/workflows/audit-security.md +1 -2
- package/.agents/workflows/audit-seo.md +10 -0
- package/.agents/workflows/audit-ux-ui.md +7 -0
- package/.agents/workflows/deliver.md +133 -45
- package/.agents/workflows/git-cleanup.md +2 -2
- package/.agents/workflows/git-deliver.md +1 -1
- package/.agents/workflows/helpers/acceptance-self-eval.md +34 -17
- package/.agents/workflows/helpers/code-quality-guardrails.md +15 -12
- package/.agents/workflows/helpers/code-review.md +14 -12
- package/.agents/workflows/helpers/deliver-story-reference.md +73 -32
- package/.agents/workflows/helpers/deliver-story.md +209 -118
- package/.agents/workflows/helpers/parallel-tooling.md +2 -2
- package/.agents/workflows/helpers/worktree-lifecycle.md +28 -32
- package/.agents/workflows/plan.md +239 -19
- package/.agents/workflows/qa-assist.md +6 -6
- package/.agents/workflows/qa-explore.md +3 -3
- package/.agents/workflows/qa-run.md +1 -5
- package/bin/mandrel.js +12 -1
- package/docs/CHANGELOG.md +62 -0
- package/lib/cli/registry.js +262 -19
- package/lib/cli/sync-agents.js +157 -0
- package/lib/cli/sync-commands.js +115 -6
- package/lib/cli/sync.js +168 -6
- package/lib/cli/update.js +105 -8
- package/lib/cli/version-helpers.js +131 -0
- package/lib/migrations/README.md +7 -5
- package/lib/migrations/index.js +17 -9
- package/lib/migrations/steps/2.1.0-retire-mi-drop-knobs.js +100 -0
- package/lib/migrations/steps/2.1.0-retire-verify-concurrency-cap.js +101 -0
- package/lib/migrations/steps/2.2.0-retire-epic-ac-tags.js +154 -0
- package/package.json +2 -2
- package/.agents/schemas/epic-perf-report.schema.json +0 -89
- package/.agents/schemas/lifecycle/acceptance.reconcile.failed.schema.json +0 -13
- package/.agents/schemas/lifecycle/acceptance.reconcile.ok.schema.json +0 -13
- package/.agents/schemas/lifecycle/acceptance.reconcile.skipped.schema.json +0 -13
- package/.agents/schemas/lifecycle/acceptance.reconcile.start.schema.json +0 -12
- package/.agents/schemas/lifecycle/acceptance.reconcile.waived.schema.json +0 -13
- package/.agents/schemas/lifecycle/epic.automerge.end.schema.json +0 -15
- package/.agents/schemas/lifecycle/epic.automerge.start.schema.json +0 -13
- package/.agents/schemas/lifecycle/epic.blocked.schema.json +0 -13
- package/.agents/schemas/lifecycle/epic.cleanup.end.schema.json +0 -12
- package/.agents/schemas/lifecycle/epic.cleanup.start.schema.json +0 -12
- package/.agents/schemas/lifecycle/epic.close.end.schema.json +0 -12
- package/.agents/schemas/lifecycle/epic.complete.schema.json +0 -13
- package/.agents/schemas/lifecycle/epic.finalize.end.schema.json +0 -13
- package/.agents/schemas/lifecycle/epic.finalize.start.schema.json +0 -12
- package/.agents/schemas/lifecycle/epic.merge.armed.schema.json +0 -13
- package/.agents/schemas/lifecycle/epic.merge.blocked.schema.json +0 -14
- package/.agents/schemas/lifecycle/epic.merge.confirmed.schema.json +0 -17
- package/.agents/schemas/lifecycle/epic.merge.ready.schema.json +0 -15
- package/.agents/schemas/lifecycle/epic.plan.end.schema.json +0 -18
- package/.agents/schemas/lifecycle/epic.plan.start.schema.json +0 -12
- package/.agents/schemas/lifecycle/epic.snapshot.end.schema.json +0 -16
- package/.agents/schemas/lifecycle/epic.snapshot.start.schema.json +0 -12
- package/.agents/schemas/lifecycle/epic.watch.end.schema.json +0 -29
- package/.agents/schemas/lifecycle/epic.watch.start.schema.json +0 -16
- package/.agents/schemas/lifecycle/story.heartbeat.schema.json +0 -20
- package/.agents/schemas/risk-verdict.schema.json +0 -53
- package/.agents/schemas/story-perf-summary.schema.json +0 -73
- package/.agents/scripts/analyze-execution.js +0 -444
- package/.agents/scripts/check-prepush-recovery.js +0 -90
- package/.agents/scripts/lib/git-merge-orchestrator.js +0 -261
- package/.agents/scripts/lib/observability/baseline-refresh-rate.js +0 -221
- package/.agents/scripts/lib/observability/hook-heartbeat.js +0 -187
- package/.agents/scripts/lib/observability/perf-aggregator.js +0 -813
- package/.agents/scripts/lib/observability/perf-report-readers.js +0 -328
- package/.agents/scripts/lib/observability/perf-report-render.js +0 -182
- package/.agents/scripts/lib/orchestration/audit-lens-routing.js +0 -128
- package/.agents/scripts/lib/orchestration/bookkeeping-outbox.js +0 -273
- package/.agents/scripts/lib/orchestration/error-journal.js +0 -139
- package/.agents/scripts/lib/orchestration/lifecycle/emit-story-heartbeat.js +0 -155
- package/.agents/scripts/lib/orchestration/lifecycle/ledger-diff.js +0 -140
- package/.agents/scripts/lib/orchestration/lifecycle/listeners/merge-watcher.js +0 -665
- package/.agents/scripts/lib/orchestration/plan-review-routing.js +0 -63
- package/.agents/scripts/lib/orchestration/planning/risk-verdict.js +0 -104
- package/.agents/scripts/lib/orchestration/planning-context-budget.js +0 -213
- package/.agents/scripts/lib/orchestration/planning-risk.js +0 -194
- package/.agents/scripts/lib/orchestration/post-merge/phases/branch-cleanup.js +0 -56
- package/.agents/scripts/lib/orchestration/post-merge/phases/dashboard-refresh.js +0 -21
- package/.agents/scripts/lib/orchestration/post-merge/phases/notification.js +0 -78
- package/.agents/scripts/lib/orchestration/post-merge/phases/temp-cleanup.js +0 -68
- package/.agents/scripts/lib/orchestration/post-merge/phases/ticket-closure.js +0 -118
- package/.agents/scripts/lib/orchestration/post-merge/phases/worktree-reap.js +0 -397
- package/.agents/scripts/lib/orchestration/preflight-cache.js +0 -187
- package/.agents/scripts/lib/orchestration/resolve-plan-run.js +0 -155
- package/.agents/scripts/lib/orchestration/retro-perf-heuristics.js +0 -275
- package/.agents/scripts/lib/orchestration/story-progress/story-run-progress-writer.js +0 -400
- package/.agents/scripts/lib/single-story/confirm-merge-follow-ups.js +0 -36
- package/.agents/scripts/resolve-plan-run.js +0 -117
- package/.agents/skills/core/analyze-execution/SKILL.md +0 -101
|
@@ -17,9 +17,8 @@ the lift the floor gate represents.
|
|
|
17
17
|
|
|
18
18
|
The configuration knobs that drive these gates live in
|
|
19
19
|
[`.agents/docs/configuration.md`](../docs/configuration.md) under
|
|
20
|
-
`delivery.quality
|
|
21
|
-
|
|
22
|
-
bootstrap or refresh it.
|
|
20
|
+
`delivery.quality.*`. This file is the runbook side — what the gate does,
|
|
21
|
+
when it fires, and how to bootstrap or refresh it.
|
|
23
22
|
|
|
24
23
|
The **baseline envelope, per-kind shapes, component model, writer/reader
|
|
25
24
|
contract, and floor-override path** are documented in the
|
|
@@ -37,14 +36,13 @@ it once and reuse the context as you read through any individual gate.
|
|
|
37
36
|
## Concurrent close safety
|
|
38
37
|
|
|
39
38
|
`/deliver` may close multiple Stories from separate Story branches in quick
|
|
40
|
-
succession.
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
with a clear error and leaves the local tree clean for manual resolution.
|
|
39
|
+
succession. Each Story rebases onto the latest `main` in its own base-sync
|
|
40
|
+
phase (`phases/base-sync.js`) before the push, so concurrent closes serialize
|
|
41
|
+
through their own worktrees rather than racing one shared branch. The push
|
|
42
|
+
step itself does not retry: a rejected push fails the close non-zero and the
|
|
43
|
+
operator resolves it, and a real content conflict (both Stories touched the
|
|
44
|
+
same lines) surfaces at base-sync with a clear error, leaving the local tree
|
|
45
|
+
clean for manual resolution.
|
|
48
46
|
|
|
49
47
|
---
|
|
50
48
|
|
|
@@ -262,9 +260,9 @@ per-round mechanic lives in
|
|
|
262
260
|
with the gate CLI at
|
|
263
261
|
[`.agents/scripts/acceptance-eval.js`](../scripts/acceptance-eval.js)).
|
|
264
262
|
Each round, a fresh-context **critic pass** — independent of the
|
|
265
|
-
implementing agent — scores the
|
|
266
|
-
`acceptance[]` item, using `verify[]`
|
|
267
|
-
of three decisions:
|
|
263
|
+
implementing agent — scores the change set its caller injected (never one
|
|
264
|
+
it re-derives) against every inline `acceptance[]` item, using `verify[]`
|
|
265
|
+
output as evidence, and yields one of three decisions:
|
|
268
266
|
|
|
269
267
|
- **proceed** — all criteria met; the Story continues to close.
|
|
270
268
|
- **redraft** — unmet criteria are redrafted and re-implemented, then
|
|
@@ -515,7 +513,7 @@ does not pause automatically on `risk::high`.
|
|
|
515
513
|
|
|
516
514
|
The sole runtime HITL pause point is `agent::blocked`: when an agent
|
|
517
515
|
encounters an unresolvable blocker (including unsafe destructive actions
|
|
518
|
-
lacking explicit authorization), it flips the ticket
|
|
516
|
+
lacking explicit authorization), it flips the ticket to
|
|
519
517
|
`agent::blocked`, posts friction context, and waits for operator resume
|
|
520
518
|
(`agent::executing`).
|
|
521
519
|
|
|
@@ -753,10 +751,10 @@ Behaviour:
|
|
|
753
751
|
- The `components` map is optional. When omitted, the default
|
|
754
752
|
`{ "*": ["**"] }` applies and only `*` rows are ever evaluated.
|
|
755
753
|
- The unified `check-baselines.js` reports breaches per component, with
|
|
756
|
-
`*` always present in the output. The
|
|
757
|
-
(`
|
|
758
|
-
`
|
|
759
|
-
breached component in
|
|
754
|
+
`*` always present in the output. The shared baselines kernel
|
|
755
|
+
(`lib/baselines/kernel.js`, via the per-kind rollups in
|
|
756
|
+
`lib/baselines/kinds/`) groups rows by component and names the
|
|
757
|
+
breached component in its output so a `*` rollup is not falsely
|
|
760
758
|
implicated when only a component-scoped floor was crossed.
|
|
761
759
|
|
|
762
760
|
#### Floor axes must match rollup axes
|
|
@@ -14,10 +14,10 @@ modules, not runnable commands). The canonical workflow narrative lives in
|
|
|
14
14
|
compose. This file is only for "which command does X?" lookups.
|
|
15
15
|
|
|
16
16
|
Every command file lives at `.agents/workflows/<name>.md` and is projected
|
|
17
|
-
into a flat `.claude/commands/` tree by `npm run sync:commands` (
|
|
18
|
-
|
|
19
|
-
slash command (e.g. `/deliver`). The projection
|
|
20
|
-
`.claude/commands/<name>.md` — there is no plugin manifest and no
|
|
17
|
+
into a flat `.claude/commands/` tree by `npm run sync:commands` (kept
|
|
18
|
+
current at install time and on every `mandrel sync`/`update`) so it shows
|
|
19
|
+
up as a bare `/<name>` slash command (e.g. `/deliver`). The projection
|
|
20
|
+
writes only `.claude/commands/<name>.md` — there is no plugin manifest and no
|
|
21
21
|
marketplace listing. The commands load in every Claude Code environment.
|
|
22
22
|
|
|
23
23
|
Loop units are the one namespaced exception: files under
|
|
@@ -43,7 +43,7 @@ description, edit the workflow file’s front-matter and regenerate.
|
|
|
43
43
|
| `/audit-documentation` | Audit the repository's main documentation for staleness, semantic drift, and completeness; emit a structured High/Medium/Low findings report. |
|
|
44
44
|
| `/audit-lighthouse` | Run a Lighthouse audit (Performance / Accessibility / Best Practices / SEO) and produce a structured findings report |
|
|
45
45
|
| `/audit-navigability` | Audit the whole route tree against the consumer's nav-registry SSOT — every route has a persona nav door and no nav href is dead. A deliberately-global lens (Epic #4131, F2/F3) exempt from the cross-epic-leak guard and routed onto route-adding change sets. |
|
|
46
|
-
| `/audit-performance` | Audit hot paths, algorithmic complexity, and I/O bottlenecks in the tooling surface (`
|
|
46
|
+
| `/audit-performance` | Audit hot paths, algorithmic complexity, and I/O bottlenecks in the tooling surface (`single-story-close`, dispatcher, gates); propose remediations. |
|
|
47
47
|
| `/audit-privacy` | Audit logs, telemetry, and persistence paths for PII leakage and retention violations; surface secrets exposure and consent gaps. |
|
|
48
48
|
| `/audit-quality` | Audit test coverage gaps, flaky tests, missing assertions, and test-pyramid balance; recommend a remediation batch. |
|
|
49
49
|
| `/audit-security` | Audit dependency CVEs, input-validation gaps, secrets handling, and auth boundaries; emit a structured High/Medium/Low findings report. |
|
|
@@ -51,7 +51,7 @@ description, edit the workflow file’s front-matter and regenerate.
|
|
|
51
51
|
| `/audit-sre` | "Audit production-readiness for a release candidate: SLOs, observability, runbooks, error budgets, and rollback paths." |
|
|
52
52
|
| `/audit-to-stories` | Convert findings produced by the audit-\* workflows into actionable GitHub Stories. Reads temp/audits/audit-\*-results.md, groups findings cross-audit, deduplicates against existing Issues by fingerprint, and either chains into /plan --seed-file or opens standalone Stories. |
|
|
53
53
|
| `/audit-ux-ui` | Audit UX/UI consistency and design system adherence |
|
|
54
|
-
| `/deliver` | Unified delivery entry point.
|
|
54
|
+
| `/deliver` | Unified delivery entry point. Takes a list of Story ids, resolves their dependency graph from live state, and delivers each via the single deliver-story engine — story-<id> → PR → main. |
|
|
55
55
|
| `/git-cleanup` | Tidy the local checkout in four phases: fast-forward `main`, prune stale remote-tracking refs, sweep merged branches (squash-aware), and triage `git stash` entries — each step gated by operator confirmation. |
|
|
56
56
|
| `/git-deliver` | Single ad-hoc delivery command for working-tree changes. Detects the git setup and escalates to the right terminal step — commit only, commit + push, or commit + push + open a PR with native auto-merge — picking the default from observable state and letting flags pin any level explicitly. Replaces the retired git-commit-all, git-push, and git-pr-all trio. |
|
|
57
57
|
| `/mandrel-update` | npm-era upgrade wraparound for a Mandrel consumer. Runs `npx mandrel update` (resolve newest published version → install → re-materialize `.agents/` → migrate → doctor → surface changelog) as the single mechanical step, then walks the operator through the judgment wraparound the CLI deliberately leaves unowned: reconcile `.agentrc.json`, install the Epic #1386 quality-gate surface, refresh the harness permission allowlist, reconcile the consumer's `AGENTS.md` / runbooks against the surfaced changelog, and stage + commit the staged lockfile bump. |
|
package/.agents/instructions.md
CHANGED
|
@@ -38,9 +38,14 @@ The skill library uses a **two-tier architecture**:
|
|
|
38
38
|
|
|
39
39
|
When a task involves a specific domain or technology, you MUST read the
|
|
40
40
|
corresponding `.agents/skills/[tier]/[category]/[skill-name]/SKILL.md` file and
|
|
41
|
-
apply its constraints.
|
|
42
|
-
|
|
43
|
-
|
|
41
|
+
apply its constraints. A `SKILL.md` leads with its **Policy Capsule** — the
|
|
42
|
+
contract, and the whole cost of activating the skill — followed by pointers
|
|
43
|
+
into an on-demand `reference.md` sibling holding the long-form material
|
|
44
|
+
(patterns, worked examples, checklists). This is the same split the always-on
|
|
45
|
+
rules use (§ 1.F): read the capsule on activation, and open a `reference.md`
|
|
46
|
+
section only when the task actually engages it. Review the skill's `examples/`
|
|
47
|
+
directory or `examples.md` sibling **when present and relevant** to the task —
|
|
48
|
+
most skills do not ship one, so do not probe blindly. When uncertain which skill applies,
|
|
44
49
|
match the task against the one-line `description` in each skill's frontmatter
|
|
45
50
|
(catalogued in `.agents/skills/skills.index.json`). Skills compose: a complete
|
|
46
51
|
feature typically flows `idea-refinement` → the `/plan` workflow →
|
|
@@ -157,18 +162,17 @@ technology context is intentionally kept out of `.agentrc.json`.
|
|
|
157
162
|
|
|
158
163
|
You MUST log telemetry about operational difficulty or automation
|
|
159
164
|
opportunities you hit. Friction is a **local NDJSON signal**:
|
|
160
|
-
`diagnose-friction.js` appends one `kind: friction` record to the per-
|
|
165
|
+
`diagnose-friction.js` appends one `kind: friction` record to the per-run/
|
|
161
166
|
per-Story `signals.ndjson` stream on local disk — not posted to the ticket at
|
|
162
167
|
capture time; the retro phase surfaces the aggregate as routed proposals.
|
|
163
168
|
|
|
164
169
|
- **Command**:
|
|
165
170
|
`node .agents/scripts/diagnose-friction.js --story [STORY_ID] --cmd [FAILED_COMMAND]`
|
|
166
|
-
(add `--epic [EPIC_ID]` under an Epic).
|
|
167
171
|
- **When to fire**: after repeated tool-validation errors, an unrecoverable
|
|
168
172
|
command failure, ambiguity needing self-correction, or repetitive
|
|
169
173
|
boilerplate steps a workflow/skill could simplify.
|
|
170
174
|
|
|
171
|
-
The schema validation, the standalone
|
|
175
|
+
The schema validation, the standalone stream path, and the
|
|
172
176
|
never-silently-dropped guarantee are reference detail — see
|
|
173
177
|
[`docs/execution-reference.md` § Friction telemetry](docs/execution-reference.md#friction-telemetry).
|
|
174
178
|
|
|
@@ -203,15 +207,11 @@ recurred, and what assumption you would test next, then either Re-Plan or
|
|
|
203
207
|
hand back to the operator. Do not paper over the loop with another
|
|
204
208
|
just-in-case retry.
|
|
205
209
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
you genuinely cannot proceed, transition to `agent::blocked` and exit
|
|
212
|
-
non-zero — never fall silent. A child with no recent `story.heartbeat`, no
|
|
213
|
-
commit on its `story-<id>` branch, and no `agent::blocked` label is exactly
|
|
214
|
-
the stall shape the parent run must detect and escalate.
|
|
210
|
+
While executing as a Story delivery sub-agent (via `helpers/deliver-story`),
|
|
211
|
+
if you genuinely cannot proceed you MUST transition to `agent::blocked` and
|
|
212
|
+
exit non-zero — **never fall silent**. A stalled child that reports nothing
|
|
213
|
+
is indistinguishable from a dead one, and the parent `/deliver` run can only
|
|
214
|
+
escalate what you surface.
|
|
215
215
|
|
|
216
216
|
### J. HITL Blocker Escalation (Safe Execution)
|
|
217
217
|
|
|
@@ -258,14 +258,16 @@ Two carve-outs refine the ordering:
|
|
|
258
258
|
|
|
259
259
|
## 2. FinOps & Token Budgeting (Economic Guardrails)
|
|
260
260
|
|
|
261
|
-
Mandrel does **not** enforce live LLM spend from response metadata
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
261
|
+
Mandrel does **not** enforce live LLM spend from response metadata, and it has
|
|
262
|
+
no operator-tunable context budget. What it does bound are fixed framework
|
|
263
|
+
ceilings — the `/plan` context envelope and plan-time Story sizing — and they
|
|
264
|
+
**fail closed** with a message naming what to trim, rather than silently
|
|
265
|
+
handing the model a truncated context. Your host runtime owns session quota and
|
|
266
|
+
hard stops. The constants, the ≈4-char/token estimate, and the trim options are
|
|
267
|
+
reference detail — see
|
|
266
268
|
[`docs/execution-reference.md` § FinOps & token budgeting](docs/execution-reference.md#finops--token-budgeting-economic-guardrails).
|
|
267
|
-
Consult it when
|
|
268
|
-
|
|
269
|
+
Consult it when `/plan` refused an over-ceiling envelope or an over-budget
|
|
270
|
+
Story count.
|
|
269
271
|
|
|
270
272
|
---
|
|
271
273
|
|
|
@@ -273,70 +275,51 @@ budget grounds.
|
|
|
273
275
|
|
|
274
276
|
1. **Context First:** Before proposing any solution, understand the
|
|
275
277
|
repository's tech stack, historical context, and structure.
|
|
276
|
-
- **Digest-first Reading (
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
278
|
+
- **Digest-first Reading (Story #4433)** — stated once here; it governs
|
|
279
|
+
every call site. **Never ingest the whole `project.docsContextFiles` set
|
|
280
|
+
up front.** Read the **docs digest** — a compact outline (path, byte
|
|
281
|
+
size, heading outline with line numbers, and the first paragraph under
|
|
282
|
+
each `##`) built from those files — decide which docs bear on the task at
|
|
283
|
+
hand, then **pull the full file on demand**, jumping to the section at
|
|
284
|
+
the line number the digest names. This is a hard cutover: no
|
|
285
|
+
read-every-file branch is retained on any path.
|
|
286
|
+
|
|
287
|
+
The call sites differ only in how the digest reaches you — the
|
|
288
|
+
discipline above is identical for all of them:
|
|
289
|
+
- `/plan` and interactive tasks — a file at `temp/run-<id>/docs-digest.md`
|
|
290
|
+
(`plan-context.js`, via the shared generator in
|
|
291
|
+
`.agents/scripts/lib/orchestration/docs-digest.js`).
|
|
292
|
+
- `/deliver` Story sub-agents (`helpers/deliver-story`) — the
|
|
293
|
+
`docsDigestPath` the caller threads.
|
|
294
|
+
- Standalone-Story planning (`story-plan.js --emit-context`) — inline as
|
|
295
|
+
`corpusContext.docsDigest` (no per-run directory to anchor a
|
|
296
|
+
file), alongside `corpusContext.relevantSections`.
|
|
297
|
+
|
|
298
|
+
When no digest exists for the task at hand — an ad hoc task outside
|
|
299
|
+
`/deliver`, `project.docsContextFiles` unset, or a null `docsDigestPath` —
|
|
300
|
+
there is **no mandatory docs read**: read a full doc only when the task's
|
|
301
|
+
own context points you at one.
|
|
302
|
+
|
|
303
|
+
The decisions log (`decisions.md`) may be either a single-file
|
|
304
|
+
dated-entry log or an **index** into a `decisions/` ADR directory — both
|
|
305
|
+
are first-class layouts (see
|
|
293
306
|
[`skills/core/documentation-and-adrs`](skills/core/documentation-and-adrs/SKILL.md)).
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
auto-loaded into every task's context. When no digest exists yet for
|
|
297
|
-
the task at hand (an ad hoc interactive task with no Epic in scope, or
|
|
298
|
-
`project.docsContextFiles` unset) there is no mandatory docs read —
|
|
299
|
-
read a full doc only when the task itself points you at one. This is a
|
|
300
|
-
hard cutover: there is no read-every-`docsContextFiles`-file branch
|
|
301
|
-
retained.
|
|
302
|
-
- **Digest-first Reading (`/deliver` story sub-agents)**: A `/deliver`
|
|
303
|
-
Story delivery sub-agent (dispatched via `helpers/deliver-story`) does
|
|
304
|
-
**not** re-read the full `project.docsContextFiles` set per Story. When
|
|
305
|
-
the caller threads a `docsDigestPath`, use that compact outline to decide
|
|
306
|
-
which docs are relevant, then **pull the full file on demand**. When
|
|
307
|
-
`docsDigestPath` is null there is no digest to read and no per-Story docs
|
|
308
|
-
mandate — read a full doc only if the Story's own context points you at
|
|
309
|
-
one. This is the hard cutover from the former
|
|
310
|
-
read-every-file-per-Story rule: delivery children no longer ingest the
|
|
311
|
-
whole docs set up front.
|
|
312
|
-
- **Standalone-Story planning path (`story-plan.js --emit-context`)**:
|
|
313
|
-
The standalone counterpart to `/plan` for Stories that do not attach
|
|
314
|
-
to an Epic does not write a `docs-digest.md` file at all — there is
|
|
315
|
-
no per-Epic directory to anchor one. Instead `buildCorpusContext`
|
|
316
|
-
(`.agents/scripts/lib/planning-corpus.js`) builds the same compact
|
|
317
|
-
digest shape in memory and threads it inline as
|
|
318
|
-
`corpusContext.docsDigest` on the `--emit-context` envelope, next to
|
|
319
|
-
`corpusContext.relevantSections` (ranked excerpts from existing
|
|
320
|
-
Epics' Tech Spec sections). Treat `corpusContext.docsDigest` exactly
|
|
321
|
-
like the file-based digest above — decide relevance from the outline,
|
|
322
|
-
then pull the full file on demand — the only difference is the
|
|
323
|
-
delivery mechanism (inline JSON field vs. a temp file path), not the
|
|
324
|
-
content or the digest-first discipline.
|
|
307
|
+
Treat an index like any other digested doc: link-follow the per-ADR
|
|
308
|
+
bodies on demand rather than auto-loading them.
|
|
325
309
|
- **Conditional Reads**: When the task touches UI copy, layout, or
|
|
326
310
|
routing and the corresponding file is present in the project, also
|
|
327
311
|
read `docs/style-guide.md` and `docs/web-routes.md`. Skip both when
|
|
328
312
|
absent or unrelated to the task — they are not part of the universal
|
|
329
313
|
mandatory set.
|
|
330
|
-
- **
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
and the task-specific instructions.
|
|
314
|
+
- **Story Context**: Additionally, read the current Story's body — the
|
|
315
|
+
inline `## Spec` plus its `acceptance[]` / `verify[]` entries — and
|
|
316
|
+
the task-specific instructions.
|
|
334
317
|
- **Optimization**: For large projects, prioritize targeted retrieval
|
|
335
318
|
(semantic code search or focused text search) to isolate specific
|
|
336
319
|
schemas or decisions before reading broad files.
|
|
337
320
|
2. **Plan First:** For non-trivial tasks (3+ steps or architectural
|
|
338
|
-
decisions), enter **Plan Mode**. Update the
|
|
339
|
-
|
|
321
|
+
decisions), enter **Plan Mode**. Update the Story's `## Spec`
|
|
322
|
+
(via `/plan`) or create a new Technical Specification document
|
|
340
323
|
in the `docs/` root (if not already handled by a ticket) before
|
|
341
324
|
touching code.
|
|
342
325
|
3. **Artifacts over Chat:** Create log files for test results, build
|
|
@@ -429,10 +412,12 @@ v2 collapses the ticket model to **Story**. Acceptance criteria and
|
|
|
429
412
|
verification steps live inline on the Story body (`acceptance[]` /
|
|
430
413
|
`verify[]`); the folded Tech Spec lives inline in `## Spec` (over-budget
|
|
431
414
|
Specs fail closed — split or tighten; never write under `docs/`). Optional
|
|
432
|
-
`depends_on` edges order rare multi-Story
|
|
415
|
+
`depends_on` edges order rare multi-Story runs — and, because `/deliver`
|
|
416
|
+
resolves them from live state, they order Stories **across plan runs and
|
|
417
|
+
over time**, not just within one batch.
|
|
433
418
|
|
|
434
|
-
- `/plan` emits one or more `type::story` issues (default N=1)
|
|
435
|
-
`
|
|
419
|
+
- `/plan` emits one or more `type::story` issues (default N=1). There is no
|
|
420
|
+
batch label: `/deliver` takes ids and discovers the graph.
|
|
436
421
|
- Each Story is executed by `helpers/deliver-story` (invoked from
|
|
437
422
|
[`/deliver`](workflows/deliver.md)). There is no per-Task sub-loop; the
|
|
438
423
|
agent authors commit subjects directly per
|
|
@@ -26,8 +26,8 @@ guess.
|
|
|
26
26
|
|
|
27
27
|
Fetch the failing job log and record the failure signature (the failing check
|
|
28
28
|
name, the run id / run link, and the first distinctive error line). The
|
|
29
|
-
watcher already writes this to `temp/
|
|
30
|
-
|
|
29
|
+
watcher already writes this to `temp/story-<id>-ci-digest.{json,md}` — start
|
|
30
|
+
from that digest.
|
|
31
31
|
|
|
32
32
|
### 2. Classify the failure
|
|
33
33
|
|
|
@@ -71,7 +71,7 @@ get to wave it off because "CI was flaky."
|
|
|
71
71
|
genuine attempt, that itself is a finding — record it in the issue you file
|
|
72
72
|
in step 4.
|
|
73
73
|
2. **Check whether it also fails on `main`.** Run the same check against an
|
|
74
|
-
unmodified `main`
|
|
74
|
+
unmodified `main` checkout. If it fails on `main`
|
|
75
75
|
too, the defect is **pre-existing** — it is not caused by the diff under
|
|
76
76
|
review, and the fix belongs in a separate change, not silently folded into
|
|
77
77
|
this delivery.
|
|
@@ -23,6 +23,16 @@ scenarios. Use the canonical set below; do not invent ad-hoc tags.
|
|
|
23
23
|
- `@flaky` — operational quarantine tag. Scenarios carrying this tag are
|
|
24
24
|
excluded from the gating suite and run in a dedicated non-blocking job
|
|
25
25
|
until stabilized. Treat `@flaky` as a debt marker, not a permanent label.
|
|
26
|
+
- `@skip` — scaffold-gating tag. Applied to scenarios scaffolded ahead of
|
|
27
|
+
their implementation (e.g. by a wave-0 BDD scaffold Story); the scenario
|
|
28
|
+
is excluded from the gating suite until the implementing Story removes
|
|
29
|
+
the tag (the "de-skip" edit). Unlike `@flaky`, `@skip` marks planned
|
|
30
|
+
not-yet-implemented behavior, never a stability problem.
|
|
31
|
+
|
|
32
|
+
Retired: the `@epic-<id>-ac-N` namespaced AC tag. Its consumer
|
|
33
|
+
(`acceptance-spec-reconciler.js`) was deleted in the v2 Epic removal, so
|
|
34
|
+
the tag is inert — do not apply it to new scenarios. The `mandrel update`
|
|
35
|
+
migration strips surviving instances from consumer feature files.
|
|
26
36
|
|
|
27
37
|
Rules:
|
|
28
38
|
|
|
@@ -37,8 +37,10 @@ which deleted the existing compatibility shim layer across
|
|
|
37
37
|
`wave-session.js`, `IExecutionAdapter` / `ManualDispatchAdapter`, lifecycle
|
|
38
38
|
emit shims, and duplicate progress/comment writers in one pass. The
|
|
39
39
|
per-finding closing references (audit Findings #10, #11, #13, #17) live in
|
|
40
|
-
the merged PRs and the Epic #2646 history; the
|
|
41
|
-
|
|
40
|
+
the merged PRs and the Epic #2646 history; the Part 1 — Model-Evolution
|
|
41
|
+
Audit analysis this section grew out of is preserved at
|
|
42
|
+
`docs/roadmap.md` @ tag `mandrel-v1.94.0` (see the Historical-anchors
|
|
43
|
+
table in the live [`docs/roadmap.md`](../../docs/roadmap.md)).
|
|
42
44
|
|
|
43
45
|
Practical guidance when authoring a contract change:
|
|
44
46
|
|
|
@@ -117,55 +119,44 @@ operator intervention:
|
|
|
117
119
|
owning flow's hygiene step regressed — fix the flow, do not codify the manual
|
|
118
120
|
sweep.
|
|
119
121
|
|
|
120
|
-
### Shared-checkout contention (
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
the
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
**
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
this guard ever executes — this guard only ever refuses on a truly
|
|
159
|
-
_foreign_ epic's live lock or unrelated dirt.
|
|
160
|
-
- **Not fixed by this guard**: the guard reports the contention early and
|
|
161
|
-
actionably; it does not redesign the merge phase to use an isolated
|
|
162
|
-
worktree, and it does not change `restoreStartingBranch`'s existing
|
|
163
|
-
dirty-tree refusal behavior (`phases/branch-restore.js`) — both remain
|
|
164
|
-
out of scope. Resolution of an actual collision is still manual: wait for
|
|
165
|
-
the other Epic's story-close run to finish, or — only once you have
|
|
166
|
-
independently confirmed that process is no longer running — remove the
|
|
167
|
-
stale lock file and resolve the dirty tree by hand (stash/commit/reset;
|
|
168
|
-
never `git reset --hard` or `git checkout --force`).
|
|
122
|
+
### Shared-checkout contention (Stories #4460, #4424, #4545)
|
|
123
|
+
|
|
124
|
+
**One delivery per checkout is the model.** v2 has no Epic integration branch
|
|
125
|
+
and no merge phase that parks the shared checkout on someone else's branch:
|
|
126
|
+
each Story works in its own worktree (`.worktrees/story-<id>/`) and lands by
|
|
127
|
+
pushing `story-<id>` and opening a PR. The Epic-era collision this section used
|
|
128
|
+
to describe — `story-close.js` running `git checkout <epic-branch>` in the
|
|
129
|
+
shared main checkout under a per-Epic `epic-*.merge.lock` — is gone with the
|
|
130
|
+
machinery that caused it (Story #4545 deleted the last of that prose; the six
|
|
131
|
+
modules it named had already been removed in the v2.0.0 cutover).
|
|
132
|
+
|
|
133
|
+
Two guards remain, and they cover different hazards:
|
|
134
|
+
|
|
135
|
+
- **Per-Story lease** (`lib/orchestration/single-story-lease-guard.js`). The
|
|
136
|
+
standalone path has no Epic-scoped dispatch manifest to serialize two
|
|
137
|
+
operators driving the **same** Story, so `single-story-init.js` takes an
|
|
138
|
+
exclusive, time-bounded lease on the Story ticket (assignee-as-lease) and
|
|
139
|
+
clears it at close. It **fails closed** on a foreign assignee — there is no
|
|
140
|
+
heartbeat ledger to judge staleness from — so a foreign holder always blocks
|
|
141
|
+
unless you pass `--steal`, which you should do only after independently
|
|
142
|
+
confirming the other run is dead.
|
|
143
|
+
|
|
144
|
+
- **Wrong-tree guard** (`lib/orchestration/single-story-close/phases/wrong-tree-guard.js`,
|
|
145
|
+
Stories #3364 / #4424). `cd <workCwd>` steers the Bash tool's cwd but does
|
|
146
|
+
**not** scope path-based Edit/Write tools, which resolve absolute paths and
|
|
147
|
+
ignore cwd. An agent whose shell is correctly inside the worktree can still
|
|
148
|
+
edit the main checkout; close then gates a clean worktree and opens a
|
|
149
|
+
silent empty-diff PR. The guard inspects
|
|
150
|
+
`git -C <mainCheckout> status --porcelain` and intersects stray **tracked**
|
|
151
|
+
paths with the Story's own diff-path set, so a concurrent session's unrelated
|
|
152
|
+
dirt does not false-positive (framework-gap #4420). Untracked files are
|
|
153
|
+
ignored as scratch.
|
|
154
|
+
|
|
155
|
+
- **Recognition signature**: close aborts naming stray files in the main
|
|
156
|
+
checkout that intersect the Story's diff. **Resolution**: relocate those
|
|
157
|
+
edits under the worktree, restore the main checkout
|
|
158
|
+
(`git -C <main-repo> checkout -- <files>`), then re-run `/deliver <storyId>`.
|
|
159
|
+
Never `git reset --hard` or `git checkout --force` to clear the way.
|
|
169
160
|
|
|
170
161
|
## Documentation Freshness Gate
|
|
171
162
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
3
|
"$id": "acceptance-eval-verdict",
|
|
4
4
|
"title": "Acceptance Self-Eval Verdict",
|
|
5
|
-
"description": "Structured output of one independent (fresh-context) acceptance self-eval round (Story #3819). Produced by the critic pass in the Story-implementation phase (helpers/deliver-story.md Step 1a), written under the gitignored temp tree, and consumed by acceptance-eval.js to enforce the bounded round cap and decide whether the Story proceeds to `closing`, redrafts, or escalates to `agent::blocked`. The author MUST NOT be the evaluator — the verdict is an independent judgment of the
|
|
5
|
+
"description": "Structured output of one independent (fresh-context) acceptance self-eval round (Story #3819). Produced by the critic pass in the Story-implementation phase (helpers/deliver-story.md Step 1a), written under the gitignored temp tree, and consumed by acceptance-eval.js to enforce the bounded round cap and decide whether the Story proceeds to `closing`, redrafts, or escalates to `agent::blocked`. The author MUST NOT be the evaluator — the verdict is an independent judgment of the caller-injected change set against each inline acceptance[] item.",
|
|
6
6
|
"type": "object",
|
|
7
7
|
"required": ["storyId", "schemaVersion", "round", "criteria"],
|
|
8
8
|
"properties": {
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
"verdict": {
|
|
53
53
|
"type": "string",
|
|
54
54
|
"enum": ["met", "partial", "unmet"],
|
|
55
|
-
"description": "Per-criterion judgment of the
|
|
55
|
+
"description": "Per-criterion judgment of the caller-injected change set. `met` clears the criterion; `partial` and `unmet` both trigger a redraft round (subject to the cap)."
|
|
56
56
|
},
|
|
57
57
|
"evidence": {
|
|
58
58
|
"type": "string",
|