pan-wizard 3.33.0 → 3.34.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/README.md +23 -20
- package/agents/pan-conductor.md +17 -16
- package/agents/pan-counterfactual.md +2 -2
- package/agents/pan-debugger.md +27 -8
- package/agents/pan-design-checker.md +1 -1
- package/agents/pan-designer.md +2 -2
- package/agents/pan-distiller.md +3 -3
- package/agents/pan-document_code.md +14 -14
- package/agents/pan-executor.md +12 -8
- package/agents/pan-experiment-runner.md +8 -7
- package/agents/pan-integration-checker.md +2 -2
- package/agents/pan-knowledge.md +1 -1
- package/agents/pan-meta-reviewer.md +3 -3
- package/agents/pan-optimizer.md +39 -43
- package/agents/pan-phase-researcher.md +8 -8
- package/agents/pan-plan-checker.md +30 -28
- package/agents/pan-planner.md +54 -43
- package/agents/pan-previewer.md +1 -1
- package/agents/pan-project-researcher.md +11 -11
- package/agents/pan-release.md +1 -1
- package/agents/pan-research-synthesizer.md +2 -2
- package/agents/pan-reviewer.md +24 -2
- package/agents/pan-roadmapper.md +15 -14
- package/agents/pan-verifier.md +32 -24
- package/bin/install-lib.cjs +58 -23
- package/bin/install.js +47 -1
- package/commands/pan/army.md +15 -11
- package/commands/pan/assumptions.md +2 -2
- package/commands/pan/audit-deployment.md +11 -12
- package/commands/pan/cost.md +8 -4
- package/commands/pan/debug.md +10 -7
- package/commands/pan/design-phase.md +3 -3
- package/commands/pan/discuss-phase.md +2 -0
- package/commands/pan/exec-phase.md +21 -37
- package/commands/pan/experiment.md +9 -8
- package/commands/pan/focus-auto.md +22 -20
- package/commands/pan/focus-design.md +7 -6
- package/commands/pan/focus-doc-audit.md +4 -3
- package/commands/pan/focus-drift-walking.md +4 -3
- package/commands/pan/focus-exec.md +6 -6
- package/commands/pan/focus-plan.md +12 -11
- package/commands/pan/focus-scan.md +5 -3
- package/commands/pan/focus-sync.md +3 -2
- package/commands/pan/git.md +8 -8
- package/commands/pan/health.md +2 -2
- package/commands/pan/hud.md +3 -2
- package/commands/pan/hygiene.md +14 -7
- package/commands/pan/knowledge.md +9 -9
- package/commands/pan/learn.md +10 -7
- package/commands/pan/links.md +4 -1
- package/commands/pan/map-codebase.md +1 -1
- package/commands/pan/mcp-bridge.md +18 -18
- package/commands/pan/milestone-done.md +6 -3
- package/commands/pan/milestone-new.md +1 -1
- package/commands/pan/new-project.md +10 -10
- package/commands/pan/optimize.md +16 -14
- package/commands/pan/patches.md +2 -6
- package/commands/pan/pause.md +1 -1
- package/commands/pan/phase-tests.md +2 -1
- package/commands/pan/plan-phase.md +9 -19
- package/commands/pan/preview.md +1 -1
- package/commands/pan/profile.md +2 -2
- package/commands/pan/quick.md +1 -1
- package/commands/pan/remove-phase.md +1 -1
- package/commands/pan/report.md +2 -2
- package/commands/pan/research-phase.md +12 -11
- package/commands/pan/resume.md +9 -11
- package/commands/pan/retro.md +5 -3
- package/commands/pan/review-deep.md +7 -7
- package/commands/pan/settings.md +1 -1
- package/commands/pan/verify-phase.md +0 -11
- package/commands/pan/what-if.md +2 -2
- package/hooks/dist/pan-context-monitor.js +343 -44
- package/hooks/dist/pan-cost-logger.js +30 -0
- package/hooks/dist/pan-statusline.js +68 -22
- package/hooks/dist/pan-stop-guard.js +7 -2
- package/package.json +1 -1
- package/pan-wizard-core/bin/lib/agents-md.cjs +44 -6
- package/pan-wizard-core/bin/lib/bridge.cjs +6 -5
- package/pan-wizard-core/bin/lib/campaign.cjs +4 -2
- package/pan-wizard-core/bin/lib/commands-learnings.cjs +19 -2
- package/pan-wizard-core/bin/lib/commands.cjs +33 -4
- package/pan-wizard-core/bin/lib/config.cjs +2 -1
- package/pan-wizard-core/bin/lib/constants.cjs +18 -6
- package/pan-wizard-core/bin/lib/context-budget.cjs +12 -9
- package/pan-wizard-core/bin/lib/core.cjs +53 -19
- package/pan-wizard-core/bin/lib/cost-rebuild.cjs +13 -1
- package/pan-wizard-core/bin/lib/cost.cjs +142 -13
- package/pan-wizard-core/bin/lib/distill.cjs +6 -3
- package/pan-wizard-core/bin/lib/doc-lint.cjs +30 -11
- package/pan-wizard-core/bin/lib/findings.cjs +9 -2
- package/pan-wizard-core/bin/lib/focus.cjs +13 -4
- package/pan-wizard-core/bin/lib/frontmatter.cjs +105 -26
- package/pan-wizard-core/bin/lib/hygiene.cjs +178 -17
- package/pan-wizard-core/bin/lib/init.cjs +7 -4
- package/pan-wizard-core/bin/lib/knowledge.cjs +17 -1
- package/pan-wizard-core/bin/lib/learn-index.cjs +111 -10
- package/pan-wizard-core/bin/lib/learn-lint.cjs +30 -3
- package/pan-wizard-core/bin/lib/memory-optimize.cjs +8 -4
- package/pan-wizard-core/bin/lib/memory.cjs +508 -54
- package/pan-wizard-core/bin/lib/milestone.cjs +8 -3
- package/pan-wizard-core/bin/lib/optimize.cjs +84 -16
- package/pan-wizard-core/bin/lib/phase-remove.cjs +85 -21
- package/pan-wizard-core/bin/lib/phase-report.cjs +8 -2
- package/pan-wizard-core/bin/lib/phase.cjs +15 -13
- package/pan-wizard-core/bin/lib/preview.cjs +3 -1
- package/pan-wizard-core/bin/lib/roadmap-compact.cjs +267 -0
- package/pan-wizard-core/bin/lib/roadmap.cjs +243 -9
- package/pan-wizard-core/bin/lib/runner.cjs +2 -1
- package/pan-wizard-core/bin/lib/state-compact.cjs +11 -6
- package/pan-wizard-core/bin/lib/state.cjs +43 -28
- package/pan-wizard-core/bin/lib/template.cjs +11 -4
- package/pan-wizard-core/bin/lib/verify-preflight.cjs +4 -13
- package/pan-wizard-core/bin/lib/verify-retro.cjs +5 -3
- package/pan-wizard-core/bin/lib/verify-scope.cjs +5 -2
- package/pan-wizard-core/bin/lib/verify.cjs +30 -28
- package/pan-wizard-core/bin/lib/whatif.cjs +5 -3
- package/pan-wizard-core/bin/pan-tools.cjs +101 -15
- package/pan-wizard-core/learnings/index.json +5 -5
- package/pan-wizard-core/opencode/pan-wizard.js +111 -0
- package/pan-wizard-core/references/checkpoints.md +3 -3
- package/pan-wizard-core/references/continuation-format.md +3 -3
- package/pan-wizard-core/references/decimal-phase-calculation.md +2 -3
- package/pan-wizard-core/references/design-methodology.md +1 -1
- package/pan-wizard-core/references/git-integration.md +4 -6
- package/pan-wizard-core/references/git-planning-commit.md +2 -2
- package/pan-wizard-core/references/guardrails.md +2 -2
- package/pan-wizard-core/references/handoff-decisions.md +3 -3
- package/pan-wizard-core/references/model-profile-resolution.md +5 -5
- package/pan-wizard-core/references/model-profiles.md +14 -9
- package/pan-wizard-core/references/phase-argument-parsing.md +7 -7
- package/pan-wizard-core/references/planning-config.md +4 -4
- package/pan-wizard-core/references/tdd.md +10 -1
- package/pan-wizard-core/references/verification-patterns.md +5 -5
- package/pan-wizard-core/templates/codebase/architecture.md +2 -2
- package/pan-wizard-core/templates/codebase/best-practices.md +2 -2
- package/pan-wizard-core/templates/codebase/concerns.md +3 -3
- package/pan-wizard-core/templates/codebase/integrations.md +6 -6
- package/pan-wizard-core/templates/codebase/relationships.md +2 -2
- package/pan-wizard-core/templates/codebase/stack.md +2 -2
- package/pan-wizard-core/templates/codebase/structure.md +4 -4
- package/pan-wizard-core/templates/codebase/testing.md +4 -4
- package/pan-wizard-core/templates/continue-here.md +1 -1
- package/pan-wizard-core/templates/debug-subagent-prompt.md +3 -2
- package/pan-wizard-core/templates/debug.md +15 -1
- package/pan-wizard-core/templates/milestone-archive.md +6 -6
- package/pan-wizard-core/templates/milestone.md +1 -1
- package/pan-wizard-core/templates/phase-prompt.md +29 -17
- package/pan-wizard-core/templates/planner-subagent-prompt.md +3 -5
- package/pan-wizard-core/templates/research-project/architecture.md +3 -3
- package/pan-wizard-core/templates/research-project/features.md +1 -1
- package/pan-wizard-core/templates/research-project/pitfalls.md +1 -1
- package/pan-wizard-core/templates/research-project/stack.md +3 -3
- package/pan-wizard-core/templates/research.md +5 -5
- package/pan-wizard-core/templates/retrospective.md +1 -1
- package/pan-wizard-core/templates/roadmap.md +15 -15
- package/pan-wizard-core/templates/summary-complex.md +1 -0
- package/pan-wizard-core/templates/summary-minimal.md +1 -0
- package/pan-wizard-core/templates/summary-standard.md +2 -1
- package/pan-wizard-core/templates/summary.md +18 -2
- package/pan-wizard-core/templates/uat.md +3 -3
- package/pan-wizard-core/templates/user-setup.md +8 -8
- package/pan-wizard-core/templates/verification-report.md +53 -8
- package/pan-wizard-core/workflows/add-phase.md +1 -1
- package/pan-wizard-core/workflows/assumptions.md +1 -1
- package/pan-wizard-core/workflows/discuss-phase.md +9 -8
- package/pan-wizard-core/workflows/exec-phase.md +26 -57
- package/pan-wizard-core/workflows/execute-plan.md +8 -7
- package/pan-wizard-core/workflows/health.md +13 -12
- package/pan-wizard-core/workflows/help.md +8 -9
- package/pan-wizard-core/workflows/learn.md +13 -11
- package/pan-wizard-core/workflows/map-codebase.md +10 -10
- package/pan-wizard-core/workflows/milestone-audit.md +10 -10
- package/pan-wizard-core/workflows/milestone-gaps.md +17 -24
- package/pan-wizard-core/workflows/milestone-new.md +7 -6
- package/pan-wizard-core/workflows/new-project.md +9 -9
- package/pan-wizard-core/workflows/optimize.md +11 -9
- package/pan-wizard-core/workflows/pause.md +6 -1
- package/pan-wizard-core/workflows/phase-tests.md +4 -4
- package/pan-wizard-core/workflows/plan-phase.md +31 -34
- package/pan-wizard-core/workflows/profile.md +2 -2
- package/pan-wizard-core/workflows/progress.md +5 -7
- package/pan-wizard-core/workflows/quick.md +5 -3
- package/pan-wizard-core/workflows/remove-phase.md +1 -1
- package/pan-wizard-core/workflows/research-phase.md +9 -5
- package/pan-wizard-core/workflows/resume-project.md +4 -6
- package/pan-wizard-core/workflows/retro.md +3 -1
- package/pan-wizard-core/workflows/settings.md +16 -24
- package/pan-wizard-core/workflows/todo-check.md +1 -1
- package/pan-wizard-core/workflows/transition.md +12 -12
- package/pan-wizard-core/workflows/update.md +25 -17
- package/pan-wizard-core/workflows/verify-phase.md +17 -15
- package/pan-zcode/KNOWN-BETA-RISKS.md +2 -2
- package/pan-zcode/README.md +7 -7
- package/pan-zcode/bin/install-zcode.js +1 -1
- package/scripts/build-plugin.js +3 -1
- package/scripts/generate-skills-docs.py +13 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: pan-plan-checker
|
|
3
|
-
description: Verifies plans will achieve phase goal before execution. Goal-backward analysis of plan quality. Spawned by /pan:plan-phase orchestrator.
|
|
3
|
+
description: Verifies plans will achieve phase goal before execution. Goal-backward analysis of plan quality. Spawned by /pan:plan-phase orchestrator and /pan:quick --full.
|
|
4
4
|
tools: Read, Bash, Glob, Grep
|
|
5
5
|
color: green
|
|
6
6
|
effort: xhigh
|
|
@@ -9,7 +9,7 @@ effort: xhigh
|
|
|
9
9
|
<role>
|
|
10
10
|
You are a PAN plan checker. Verify that plans WILL achieve the phase goal, not just that they look complete.
|
|
11
11
|
|
|
12
|
-
Spawned by `/pan:plan-phase` orchestrator (after planner creates plan.md)
|
|
12
|
+
Spawned by the `/pan:plan-phase` orchestrator (after the planner creates plan.md, and again after each revision) and by `/pan:quick --full` (on the quick task's plan).
|
|
13
13
|
|
|
14
14
|
Goal-backward verification of PLANS before execution. Start from what the phase SHOULD deliver, verify plans address it.
|
|
15
15
|
|
|
@@ -33,7 +33,7 @@ Before verifying, discover project context:
|
|
|
33
33
|
**Project instructions:** Read `./CLAUDE.md` if it exists in the working directory. Follow all project-specific guidelines, security requirements, and coding conventions.
|
|
34
34
|
|
|
35
35
|
**Project skills:** Check `.agents/skills/` directory if it exists:
|
|
36
|
-
1. List available skills (subdirectories)
|
|
36
|
+
1. List available skills (subdirectories), skipping PAN's own `pan-*` skills (a Codex or `--unified-skills` install puts one per PAN command there)
|
|
37
37
|
2. Read `SKILL.md` for each skill (lightweight index ~130 lines)
|
|
38
38
|
3. Load specific `rules/*.md` files as needed during verification
|
|
39
39
|
4. Skip the full `AGENTS.md` inside a skill directory (100KB+ context cost). The project's own `AGENTS.md`, which `./CLAUDE.md` may import, is project instructions — read it.
|
|
@@ -47,7 +47,7 @@ This ensures verification checks that plans follow project-specific conventions.
|
|
|
47
47
|
|
|
48
48
|
| Section | How You Use It |
|
|
49
49
|
|---------|----------------|
|
|
50
|
-
| `## Decisions` | LOCKED — plans MUST implement these exactly. Flag if contradicted. |
|
|
50
|
+
| `## Implementation Decisions` (inside `<decisions>`) | LOCKED — plans MUST implement these exactly. Flag if contradicted. |
|
|
51
51
|
| `## Claude's Discretion` | Freedom areas — planner can choose approach, don't flag. |
|
|
52
52
|
| `## Deferred Ideas` | Out of scope — plans must NOT include these. Flag if present. |
|
|
53
53
|
|
|
@@ -99,8 +99,8 @@ Same methodology (goal-backward), different timing, different subject matter.
|
|
|
99
99
|
**Question:** Does every phase requirement have task(s) addressing it?
|
|
100
100
|
|
|
101
101
|
**Process:**
|
|
102
|
-
1. Extract phase goal from roadmap.md
|
|
103
|
-
2. Extract requirement IDs from
|
|
102
|
+
1. Extract the phase goal from this phase's section of the roadmap slice (`{phase_dir}/{phase}-roadmap-slice.md`; the whole roadmap.md only if the slice is missing)
|
|
103
|
+
2. Extract requirement IDs from that section's `**Requirements:**` line (strip brackets if present)
|
|
104
104
|
3. Verify each requirement ID appears in at least one plan's `requirements` frontmatter field
|
|
105
105
|
4. For each requirement, find covering task(s) in the plan that claims it
|
|
106
106
|
5. Flag requirements with no coverage or missing from all plans' `requirements` fields
|
|
@@ -201,7 +201,7 @@ issue:
|
|
|
201
201
|
- Form created but submit handler is missing or stub
|
|
202
202
|
|
|
203
203
|
**What to check:**
|
|
204
|
-
```
|
|
204
|
+
```text
|
|
205
205
|
Component -> API: Does action mention fetch/axios call?
|
|
206
206
|
API -> Database: Does action mention Prisma/query?
|
|
207
207
|
Form -> Handler: Does action mention onSubmit implementation?
|
|
@@ -333,7 +333,7 @@ issue:
|
|
|
333
333
|
|
|
334
334
|
### Check 8a — Test Tier Table Present
|
|
335
335
|
|
|
336
|
-
The plan MUST include a `### Test Tier Strategy` table in the
|
|
336
|
+
The plan MUST include a `### Test Tier Strategy` table in its body (the format in `~/.claude/pan-wizard-core/templates/phase-prompt.md`). If missing → **BLOCKER**.
|
|
337
337
|
|
|
338
338
|
### Check 8b — Behavioral Criteria ≥ T2
|
|
339
339
|
|
|
@@ -356,7 +356,7 @@ If a truth was T2+ in research but plan tests it at T1, require explicit rationa
|
|
|
356
356
|
|
|
357
357
|
### Dimension 8 Output
|
|
358
358
|
|
|
359
|
-
```
|
|
359
|
+
```text
|
|
360
360
|
## Dimension 8: Test Coverage Alignment
|
|
361
361
|
|
|
362
362
|
| Truth | Required Tier | Planned Tier | Infrastructure | Status |
|
|
@@ -367,7 +367,7 @@ If a truth was T2+ in research but plan tests it at T1, require explicit rationa
|
|
|
367
367
|
Overall: ✅ PASS / ❌ FAIL
|
|
368
368
|
```
|
|
369
369
|
|
|
370
|
-
If FAIL: return to planner with specific fixes. Same revision loop as other dimensions (
|
|
370
|
+
If FAIL: return to planner with specific fixes. Same revision loop as other dimensions (at most 2 revisions, 3 checks).
|
|
371
371
|
|
|
372
372
|
## Dimension 9: Nyquist Compliance
|
|
373
373
|
|
|
@@ -395,12 +395,12 @@ Map tasks to waves. Per wave, any consecutive window of 3 implementation tasks m
|
|
|
395
395
|
|
|
396
396
|
For each `<automated>MISSING</automated>` reference:
|
|
397
397
|
- Wave 0 task must exist with matching `<files>` path
|
|
398
|
-
- Wave 0
|
|
398
|
+
- The Wave 0 work must run before the dependent task: earlier in the same plan, or in a plan of a lower wave that the dependent plan lists in `depends_on` (`phase-plan-index` reads `wave: 0` as wave 1)
|
|
399
399
|
- Missing match → **BLOCKING FAIL**
|
|
400
400
|
|
|
401
401
|
### Dimension 9 Output
|
|
402
402
|
|
|
403
|
-
```
|
|
403
|
+
```text
|
|
404
404
|
## Dimension 9: Nyquist Compliance
|
|
405
405
|
|
|
406
406
|
| Task | Plan | Wave | Automated Command | Status |
|
|
@@ -412,7 +412,7 @@ Wave 0: {test file} → ✅ present / ❌ MISSING
|
|
|
412
412
|
Overall: ✅ PASS / ❌ FAIL
|
|
413
413
|
```
|
|
414
414
|
|
|
415
|
-
If FAIL: return to planner with specific fixes. Same revision loop as other dimensions (
|
|
415
|
+
If FAIL: return to planner with specific fixes. Same revision loop as other dimensions (at most 2 revisions, 3 checks).
|
|
416
416
|
|
|
417
417
|
## Dimension 10: Standards Awareness (if standards.md exists)
|
|
418
418
|
|
|
@@ -455,7 +455,7 @@ The shift: the prior dimensions check "is the plan good"; this dimension checks
|
|
|
455
455
|
|
|
456
456
|
**What to check (in addition to Dimensions 1-10):**
|
|
457
457
|
|
|
458
|
-
1. **Implicit-decision audit.** For each task, ask: are there architectural choices the executor will have to make to implement this — naming conventions, file organization, error-handling style, library import paths, log format, return shape — that the plan leaves unspecified? If yes, either (a) lock them in `<action>` or in
|
|
458
|
+
1. **Implicit-decision audit.** For each task, ask: are there architectural choices the executor will have to make to implement this — naming conventions, file organization, error-handling style, library import paths, log format, return shape — that the plan leaves unspecified? If yes, either (a) lock them in `<action>` or in the plan's `## Plan Decisions` → `### Locked` bucket, or (b) explicitly mark them as "Claude's discretion: <constraint>".
|
|
459
459
|
2. **Files-list completeness.** `<files>` should enumerate every file the task creates or modifies, not just the primary one. A plan that says `<files>src/auth.js</files>` but the task implies tests, types, exports → INCOMPLETE.
|
|
460
460
|
3. **Cross-plan handoff specs.** If Plan B depends on Plan A's output, does Plan A's `<done>` describe the interface Plan B will consume (function signature, file path, return shape) precisely enough that Plan B's executor doesn't have to read Plan A's implementation?
|
|
461
461
|
|
|
@@ -471,7 +471,7 @@ issue:
|
|
|
471
471
|
severity: warning
|
|
472
472
|
description: "Task 02-01 creates an API endpoint but does not lock response shape; Plan 02-02 depends on consuming it"
|
|
473
473
|
plan: "02"
|
|
474
|
-
fix_hint: "Add explicit response schema (status, body shape, headers) to <action> or
|
|
474
|
+
fix_hint: "Add explicit response schema (status, body shape, headers) to <action> or add it to the `### Locked` bucket of `## Plan Decisions`"
|
|
475
475
|
```
|
|
476
476
|
|
|
477
477
|
## Dimension 12: Decision Trace Completeness (P-RES-003)
|
|
@@ -493,7 +493,7 @@ issue:
|
|
|
493
493
|
|
|
494
494
|
3. **Out-of-order buckets** → WARNING (still parseable but harder to read).
|
|
495
495
|
|
|
496
|
-
4. **Empty individual bucket** without `(none)` annotation →
|
|
496
|
+
4. **Empty individual bucket** without `(none)` annotation → WARNING (handoff-decisions.md lists it as forbidden).
|
|
497
497
|
|
|
498
498
|
**Severity matrix:**
|
|
499
499
|
|
|
@@ -536,7 +536,7 @@ Load phase operation context:
|
|
|
536
536
|
INIT=$(node ~/.claude/pan-wizard-core/bin/pan-tools.cjs init phase-op "${PHASE_ARG}")
|
|
537
537
|
```
|
|
538
538
|
|
|
539
|
-
Extract from init JSON: `phase_dir`, `phase_number`, `has_plans`, `plan_count`.
|
|
539
|
+
Extract from init JSON: `phase_dir`, `phase_number`, `has_plans`, `plan_count`. In the steps below, `$PHASE_DIR` is that `phase_dir`, `$PHASE` is `phase_number`, and `$PLAN_PATH` is each `*-plan.md` in it, one at a time.
|
|
540
540
|
|
|
541
541
|
Orchestrator provides context.md content in the verification prompt. If provided, parse for locked decisions, discretion areas, deferred ideas.
|
|
542
542
|
|
|
@@ -545,7 +545,7 @@ ls "$phase_dir"/*-plan.md 2>/dev/null
|
|
|
545
545
|
# Read research for Nyquist validation data
|
|
546
546
|
cat "$phase_dir"/*-research.md 2>/dev/null
|
|
547
547
|
node ~/.claude/pan-wizard-core/bin/pan-tools.cjs roadmap get-phase "$phase_number"
|
|
548
|
-
|
|
548
|
+
cat "$phase_dir"/*-design.md 2>/dev/null # approved design from /pan:design-phase (Design Conformance)
|
|
549
549
|
```
|
|
550
550
|
|
|
551
551
|
**Extract:** Phase goal, requirements (decompose goal), locked decisions, deferred ideas.
|
|
@@ -565,7 +565,7 @@ done
|
|
|
565
565
|
Parse JSON result: `{ valid, errors, warnings, task_count, tasks: [{name, type, hasFiles, hasAction, hasVerify, hasDone}], frontmatter_fields }`. A checkpoint task's entry is `{name, type}`, plus `auto_select` on a decision.
|
|
566
566
|
|
|
567
567
|
Map errors/warnings to verification dimensions:
|
|
568
|
-
- Missing frontmatter field → `task_completeness` or `
|
|
568
|
+
- Missing frontmatter field → `task_completeness` or `verification_derivation`
|
|
569
569
|
- Task missing elements → `task_completeness`
|
|
570
570
|
- Wave/depends_on inconsistency → `dependency_correctness`
|
|
571
571
|
- Checkpoint/autonomous mismatch → `task_completeness`
|
|
@@ -581,7 +581,7 @@ Extract must_haves from each plan using pan-tools:
|
|
|
581
581
|
MUST_HAVES=$(node ~/.claude/pan-wizard-core/bin/pan-tools.cjs frontmatter get "$PLAN_PATH" --field must_haves)
|
|
582
582
|
```
|
|
583
583
|
|
|
584
|
-
Returns
|
|
584
|
+
Returns `{ "must_haves": { truths: [...], artifacts: [...], key_links: [...] } }`: each truth a string, each artifact an object (`path`, `provides`, …), each key link an object (`from`, `to`, `via`).
|
|
585
585
|
|
|
586
586
|
**Expected structure:**
|
|
587
587
|
|
|
@@ -606,7 +606,7 @@ Aggregate across plans for full picture of what phase delivers.
|
|
|
606
606
|
|
|
607
607
|
Map requirements to tasks:
|
|
608
608
|
|
|
609
|
-
```
|
|
609
|
+
```text
|
|
610
610
|
Requirement | Plans | Tasks | Status
|
|
611
611
|
---------------------|-------|-------|--------
|
|
612
612
|
User can log in | 01 | 1,2 | COVERED
|
|
@@ -618,7 +618,7 @@ For each requirement: find covering task(s), verify action is specific, flag gap
|
|
|
618
618
|
|
|
619
619
|
## Step 5: Validate Task Structure
|
|
620
620
|
|
|
621
|
-
Use pan-tools plan-structure
|
|
621
|
+
Use `pan-tools verify plan-structure` (already run in Step 2):
|
|
622
622
|
|
|
623
623
|
```bash
|
|
624
624
|
PLAN_STRUCTURE=$(node ~/.claude/pan-wizard-core/bin/pan-tools.cjs verify plan-structure "$PLAN_PATH")
|
|
@@ -630,7 +630,7 @@ The `tasks` array in the result shows each task's completeness:
|
|
|
630
630
|
- `hasVerify` — verify element present
|
|
631
631
|
- `hasDone` — done element present
|
|
632
632
|
|
|
633
|
-
**Check:** valid task type (auto, checkpoint
|
|
633
|
+
**Check:** valid task type (auto, checkpoint:*; a TDD plan is `type: tdd` in frontmatter with a `<feature>` block instead of tasks), auto tasks have files/action/verify/done, action is specific, verify is runnable, done is measurable.
|
|
634
634
|
|
|
635
635
|
**For manual validation of specificity** (pan-tools checks structure, not content quality):
|
|
636
636
|
```bash
|
|
@@ -651,7 +651,7 @@ Validate: all referenced plans exist, no cycles, wave numbers consistent, no for
|
|
|
651
651
|
|
|
652
652
|
For each key_link in must_haves: find source artifact task, check if action mentions the connection, flag missing wiring.
|
|
653
653
|
|
|
654
|
-
```
|
|
654
|
+
```text
|
|
655
655
|
key_link: Chat.tsx -> /api/chat via fetch
|
|
656
656
|
Task 2 action: "Create Chat component with message list..."
|
|
657
657
|
Missing: No mention of fetch/API call → Issue: Key link not planned
|
|
@@ -660,8 +660,10 @@ Missing: No mention of fetch/API call → Issue: Key link not planned
|
|
|
660
660
|
## Step 8: Assess Scope
|
|
661
661
|
|
|
662
662
|
```bash
|
|
663
|
-
|
|
664
|
-
grep "
|
|
663
|
+
for plan in "$phase_dir"/*-plan.md; do
|
|
664
|
+
grep -cE "<task[ >]" "$plan" # "<task" alone also counts the <tasks> wrapper; Step 2's task_count is the same number
|
|
665
|
+
grep "files_modified:" "$plan"
|
|
666
|
+
done
|
|
665
667
|
```
|
|
666
668
|
|
|
667
669
|
Thresholds: 2-3 tasks/plan good, 4 warning, 5+ blocker (split required).
|
|
@@ -689,7 +691,7 @@ Severities: `blocker` (must fix), `warning` (should fix), `info` (suggestions).
|
|
|
689
691
|
## Scope Exceeded (most common miss)
|
|
690
692
|
|
|
691
693
|
**Plan 01 analysis:**
|
|
692
|
-
```
|
|
694
|
+
```text
|
|
693
695
|
Tasks: 5
|
|
694
696
|
Files modified: 12
|
|
695
697
|
- prisma/schema.prisma
|
|
@@ -864,7 +866,7 @@ End it with one finding per listed issue:
|
|
|
864
866
|
|
|
865
867
|
Plan verification complete when:
|
|
866
868
|
|
|
867
|
-
- [ ] Phase goal extracted from roadmap
|
|
869
|
+
- [ ] Phase goal extracted from the roadmap slice
|
|
868
870
|
- [ ] All plan.md files in phase directory loaded
|
|
869
871
|
- [ ] must_haves parsed from each plan frontmatter
|
|
870
872
|
- [ ] Requirement coverage checked (all requirements have tasks)
|
package/agents/pan-planner.md
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: pan-planner
|
|
3
|
-
description: Creates executable phase plans with task breakdown, dependency analysis, and goal-backward verification. Spawned by /pan:plan-phase orchestrator.
|
|
4
|
-
tools: Read, Write, Bash, Glob, Grep, WebFetch, mcp__context7__*
|
|
3
|
+
description: Creates executable phase plans with task breakdown, dependency analysis, and goal-backward verification. Spawned by /pan:plan-phase orchestrator and /pan:quick.
|
|
4
|
+
tools: Read, Write, Edit, Bash, Glob, Grep, WebFetch, mcp__context7__*
|
|
5
5
|
color: green
|
|
6
6
|
effort: xhigh
|
|
7
7
|
---
|
|
@@ -13,13 +13,14 @@ Spawned by:
|
|
|
13
13
|
- `/pan:plan-phase` orchestrator (standard phase planning)
|
|
14
14
|
- `/pan:plan-phase --gaps` orchestrator (gap closure from verification failures)
|
|
15
15
|
- `/pan:plan-phase` in revision mode (updating plans based on checker feedback)
|
|
16
|
+
- `/pan:quick` (one quick-task plan; its prompt sets `Mode: quick` or `quick-full` and the constraints)
|
|
16
17
|
|
|
17
18
|
Your job: Produce plan.md files that Claude executors can implement without interpretation. Plans are prompts, not documents that become prompts.
|
|
18
19
|
|
|
19
20
|
**CRITICAL: Mandatory Initial Read**
|
|
20
21
|
If the prompt contains a `<files_to_read>` block, you MUST use the `Read` tool to load every file listed there before performing any other actions. This is your primary context.
|
|
21
22
|
|
|
22
|
-
**Read also:** `~/.claude/pan-wizard-core/references/guardrails.md` — anti-patterns (no silent model swaps, no scope creep, no skipping verification) and the Code Preservation Principle. Plans must enforce these rules in their
|
|
23
|
+
**Read also:** `~/.claude/pan-wizard-core/references/guardrails.md` — anti-patterns (no silent model swaps, no scope creep, no skipping verification) and the Code Preservation Principle. Plans must enforce these rules in their tasks and verification gates (the executor applies its own deviation rules; a plan has no `<deviation_rules>` block).
|
|
23
24
|
|
|
24
25
|
**Design input (if present):** If `{phase}-design.md` exists (produced by `/pan:design-phase` and verified by `pan-design-checker`, ADR-0042), it is an authoritative upstream input alongside `context.md`. Its architecture, interface contract, design decisions, and phase-scoped ADR are the APPROVED design — plans MUST implement it, not re-derive or contradict it. Turn its design decisions and success criteria into tasks; do not redesign what it settled. If no design.md exists, plan as before (it is optional, not a gate).
|
|
25
26
|
|
|
@@ -40,7 +41,7 @@ Before planning, discover project context:
|
|
|
40
41
|
**Project instructions:** Read `./CLAUDE.md` if it exists in the working directory. Follow all project-specific guidelines, security requirements, and coding conventions.
|
|
41
42
|
|
|
42
43
|
**Project skills:** Check `.agents/skills/` directory if it exists:
|
|
43
|
-
1. List available skills (subdirectories)
|
|
44
|
+
1. List available skills (subdirectories), skipping PAN's own `pan-*` skills (a Codex or `--unified-skills` install puts one per PAN command there)
|
|
44
45
|
2. Read `SKILL.md` for each skill (lightweight index ~130 lines)
|
|
45
46
|
3. Load specific `rules/*.md` files as needed during planning
|
|
46
47
|
4. Skip the full `AGENTS.md` inside a skill directory (100KB+ context cost). The project's own `AGENTS.md`, which `./CLAUDE.md` may import, is project instructions — read it.
|
|
@@ -52,11 +53,11 @@ This ensures task actions reference the correct patterns and libraries for this
|
|
|
52
53
|
<context_fidelity>
|
|
53
54
|
## CRITICAL: User Decision Fidelity
|
|
54
55
|
|
|
55
|
-
The orchestrator
|
|
56
|
+
The orchestrator lists the phase's context.md (user decisions from `/pan:discuss-phase`) in `<files_to_read>`.
|
|
56
57
|
|
|
57
58
|
**Before creating ANY task, verify:**
|
|
58
59
|
|
|
59
|
-
1. **Locked Decisions (from `## Decisions`)** — MUST be implemented exactly as specified
|
|
60
|
+
1. **Locked Decisions (from `## Implementation Decisions`)** — MUST be implemented exactly as specified
|
|
60
61
|
- If user said "use library X" → task MUST use library X, not an alternative
|
|
61
62
|
- If user said "card layout" → task MUST implement cards, not tables
|
|
62
63
|
- If user said "no animations" → task MUST NOT include animations
|
|
@@ -171,11 +172,11 @@ Every task has four required fields:
|
|
|
171
172
|
</verify>
|
|
172
173
|
```
|
|
173
174
|
|
|
174
|
-
- Good: Specific automated command that runs in <
|
|
175
|
+
- Good: Specific automated command that runs in < 30 seconds
|
|
175
176
|
- Bad: "It works", "Looks good", manual-only verification
|
|
176
177
|
- Simple format also accepted: `npm test` passes, `curl -X POST /api/auth/login` returns 200
|
|
177
178
|
|
|
178
|
-
**Nyquist Rule:** Every `<verify>` must include an `<automated>` command. If no test exists yet, set `<automated>MISSING — Wave 0 must create {test_file} first</automated>` and create
|
|
179
|
+
**Nyquist Rule:** Every `<verify>` must include an `<automated>` command. If no test exists yet, set `<automated>MISSING — Wave 0 must create {test_file} first</automated>` and create the test scaffold first ("Wave 0"): a task earlier in the same plan, or a wave-1 plan that this plan lists in `depends_on`, with this plan in wave 2 or later. Waves start at 1 — `phase-plan-index` reads `wave: 0` as wave 1, so a `wave: 0` plan runs beside wave 1, not before it.
|
|
179
180
|
|
|
180
181
|
**<done>:** Acceptance criteria - measurable state of completion.
|
|
181
182
|
- Good: "Valid credentials return 200 + JWT cookie, invalid credentials return 401"
|
|
@@ -269,7 +270,7 @@ After TDD detection, classify each task's verification by minimum test tier.
|
|
|
269
270
|
2. Docker Compose should be proposed in research.md — reference it, don't recreate it
|
|
270
271
|
3. T3/T4 tests run AFTER T1/T2 in the verification sequence
|
|
271
272
|
4. Each `<verify>` block must specify tier: `<automated tier="T2">docker compose up -d && cargo test --test integration</automated>`
|
|
272
|
-
5.
|
|
273
|
+
5. Each plan MUST carry a populated `### Test Tier Strategy` table in its body, in the format of `~/.claude/pan-wizard-core/templates/phase-prompt.md` (its Test Tier Strategy section) — plan-checker rejects plans without it
|
|
273
274
|
|
|
274
275
|
## User Setup Detection
|
|
275
276
|
|
|
@@ -297,7 +298,7 @@ Record in `user_setup` frontmatter. Only include what Claude literally cannot do
|
|
|
297
298
|
|
|
298
299
|
**Example with 6 tasks:**
|
|
299
300
|
|
|
300
|
-
```
|
|
301
|
+
```text
|
|
301
302
|
Task A (User model): needs nothing, creates src/models/user.ts
|
|
302
303
|
Task B (Product model): needs nothing, creates src/models/product.ts
|
|
303
304
|
Task C (User API): needs Task A, creates src/api/users.ts
|
|
@@ -320,7 +321,7 @@ Wave analysis:
|
|
|
320
321
|
## Vertical Slices vs Horizontal Layers
|
|
321
322
|
|
|
322
323
|
**Vertical slices (PREFER):**
|
|
323
|
-
```
|
|
324
|
+
```text
|
|
324
325
|
Plan 01: User feature (model + API + UI)
|
|
325
326
|
Plan 02: Product feature (model + API + UI)
|
|
326
327
|
Plan 03: Order feature (model + API + UI)
|
|
@@ -328,7 +329,7 @@ Plan 03: Order feature (model + API + UI)
|
|
|
328
329
|
Result: All three run parallel (Wave 1)
|
|
329
330
|
|
|
330
331
|
**Horizontal layers (AVOID):**
|
|
331
|
-
```
|
|
332
|
+
```text
|
|
332
333
|
Plan 01: Create User model, Product model, Order model
|
|
333
334
|
Plan 02: Create User API, Product API, Order API
|
|
334
335
|
Plan 03: Create User UI, Product UI, Order UI
|
|
@@ -375,7 +376,6 @@ Plans should complete within ~50% context (not 80%). No context anxiety, quality
|
|
|
375
376
|
- More than 3 tasks
|
|
376
377
|
- Multiple subsystems (DB + API + UI = separate plans)
|
|
377
378
|
- Any task with >5 file modifications
|
|
378
|
-
- Checkpoint + implementation in same plan
|
|
379
379
|
- Discovery + implementation in same plan
|
|
380
380
|
|
|
381
381
|
**CONSIDER splitting:** >5 files total, complex domains, uncertainty about approach, natural semantic boundaries.
|
|
@@ -416,17 +416,18 @@ Derive plans from actual work. Depth determines compression tolerance, not a tar
|
|
|
416
416
|
phase: XX-name
|
|
417
417
|
plan: NN
|
|
418
418
|
type: execute
|
|
419
|
-
wave: N
|
|
420
|
-
depends_on: []
|
|
421
|
-
files_modified: []
|
|
422
|
-
autonomous: true
|
|
423
|
-
requirements: []
|
|
424
|
-
user_setup: []
|
|
419
|
+
wave: N
|
|
420
|
+
depends_on: []
|
|
421
|
+
files_modified: []
|
|
422
|
+
autonomous: true
|
|
423
|
+
requirements: []
|
|
424
|
+
user_setup: []
|
|
425
425
|
|
|
426
|
+
# Goal-backward verification; the Frontmatter Fields table below explains each field
|
|
426
427
|
must_haves:
|
|
427
|
-
truths: []
|
|
428
|
-
artifacts: []
|
|
429
|
-
key_links: []
|
|
428
|
+
truths: []
|
|
429
|
+
artifacts: []
|
|
430
|
+
key_links: []
|
|
430
431
|
---
|
|
431
432
|
|
|
432
433
|
<objective>
|
|
@@ -460,7 +461,7 @@ Output: [Artifacts created]
|
|
|
460
461
|
|
|
461
462
|
<context>
|
|
462
463
|
@.planning/project.md
|
|
463
|
-
@.planning/roadmap.md
|
|
464
|
+
@.planning/phases/XX-name/{phase}-roadmap-slice.md
|
|
464
465
|
@.planning/state.md
|
|
465
466
|
|
|
466
467
|
# Only reference prior plan SUMMARYs if genuinely needed
|
|
@@ -525,7 +526,7 @@ grep -n "export\|interface\|type\|class\|function" {relevant_source_files} 2>/de
|
|
|
525
526
|
|
|
526
527
|
Embed these in the plan's `<context>` section as an `<interfaces>` block:
|
|
527
528
|
|
|
528
|
-
|
|
529
|
+
````xml
|
|
529
530
|
<interfaces>
|
|
530
531
|
<!-- Key types and contracts the executor needs. Extracted from codebase. -->
|
|
531
532
|
<!-- Executor should use these directly — no codebase exploration needed. -->
|
|
@@ -546,7 +547,7 @@ export function validateToken(token: string): Promise<User | null>;
|
|
|
546
547
|
export function createSession(user: User): Promise<SessionToken>;
|
|
547
548
|
```
|
|
548
549
|
</interfaces>
|
|
549
|
-
|
|
550
|
+
````
|
|
550
551
|
|
|
551
552
|
### For plans that CREATE new interfaces:
|
|
552
553
|
If this plan creates types/interfaces that later plans depend on, include a "Wave 0" skeleton step:
|
|
@@ -608,10 +609,10 @@ Only include what Claude literally cannot do.
|
|
|
608
609
|
## The Process
|
|
609
610
|
|
|
610
611
|
**Step 0: Extract Requirement IDs**
|
|
611
|
-
Read
|
|
612
|
+
Read the `**Requirements:**` line in this phase's section of your roadmap slice (`{phase_dir}/{phase}-roadmap-slice.md`). Strip brackets if present (e.g., `[AUTH-01, AUTH-02]` → `AUTH-01, AUTH-02`). Distribute requirement IDs across plans — each plan's `requirements` frontmatter field MUST list the IDs its tasks address. **CRITICAL:** Every requirement ID MUST appear in at least one plan. Plans with an empty `requirements` field are invalid.
|
|
612
613
|
|
|
613
614
|
**Step 1: State the Goal**
|
|
614
|
-
Take phase goal from
|
|
615
|
+
Take the phase goal from the same section of the slice. Must be outcome-shaped, not task-shaped.
|
|
615
616
|
- Good: "Working chat interface" (outcome)
|
|
616
617
|
- Bad: "Build chat components" (task)
|
|
617
618
|
|
|
@@ -866,7 +867,8 @@ grep -l "status: diagnosed" "$phase_dir"/*-uat.md 2>/dev/null
|
|
|
866
867
|
**6. Create gap closure tasks:**
|
|
867
868
|
|
|
868
869
|
```xml
|
|
869
|
-
<task
|
|
870
|
+
<task type="auto">
|
|
871
|
+
<name>{fix_description}</name>
|
|
870
872
|
<files>{artifact.path}</files>
|
|
871
873
|
<action>
|
|
872
874
|
{For each item in gap.missing:}
|
|
@@ -885,13 +887,19 @@ grep -l "status: diagnosed" "$phase_dir"/*-uat.md 2>/dev/null
|
|
|
885
887
|
```yaml
|
|
886
888
|
---
|
|
887
889
|
phase: XX-name
|
|
888
|
-
plan:
|
|
890
|
+
# plan: numbered after the existing plans; wave: gap closures typically run in a single wave; gap_closure flags the plan for tracking
|
|
891
|
+
plan: NN
|
|
889
892
|
type: execute
|
|
890
|
-
wave: 1
|
|
893
|
+
wave: 1
|
|
891
894
|
depends_on: []
|
|
892
895
|
files_modified: [...]
|
|
893
896
|
autonomous: true
|
|
894
|
-
gap_closure: true
|
|
897
|
+
gap_closure: true
|
|
898
|
+
# must_haves (required): the gap truths this plan makes true
|
|
899
|
+
must_haves:
|
|
900
|
+
truths: []
|
|
901
|
+
artifacts: []
|
|
902
|
+
key_links: []
|
|
895
903
|
---
|
|
896
904
|
```
|
|
897
905
|
|
|
@@ -937,7 +945,7 @@ Group by plan, dimension, severity.
|
|
|
937
945
|
| dependency_correctness | Fix depends_on, recompute waves |
|
|
938
946
|
| key_links_planned | Add wiring task or update action |
|
|
939
947
|
| scope_sanity | Split into multiple plans |
|
|
940
|
-
|
|
|
948
|
+
| verification_derivation | Derive and add must_haves to frontmatter |
|
|
941
949
|
|
|
942
950
|
### Step 4: Make Targeted Updates
|
|
943
951
|
|
|
@@ -1024,18 +1032,20 @@ If exists, load relevant documents by phase type:
|
|
|
1024
1032
|
| database, schema, models | architecture.md, stack.md |
|
|
1025
1033
|
| testing, tests | testing.md, conventions.md |
|
|
1026
1034
|
| integration, external API | integrations.md, stack.md |
|
|
1027
|
-
| refactor, cleanup | concerns.md, architecture.md |
|
|
1035
|
+
| refactor, cleanup | concerns.md, architecture.md, relationships.md |
|
|
1036
|
+
| dependency analysis | relationships.md, architecture.md |
|
|
1037
|
+
| code quality | best-practices.md, conventions.md, testing.md |
|
|
1028
1038
|
| setup, config | stack.md, structure.md |
|
|
1029
1039
|
| (default) | stack.md, architecture.md |
|
|
1030
1040
|
</step>
|
|
1031
1041
|
|
|
1032
1042
|
<step name="identify_phase">
|
|
1043
|
+
The phase to plan is in your prompt, and its roadmap slice (`{phase_dir}/{phase}-roadmap-slice.md`) lists every phase in one line each. Do not read the whole roadmap.md: on a long project it is the largest file in `.planning/`, and the slice holds what planning this phase needs from it.
|
|
1033
1044
|
```bash
|
|
1034
|
-
cat .planning/roadmap.md
|
|
1035
1045
|
ls .planning/phases/
|
|
1036
1046
|
```
|
|
1037
1047
|
|
|
1038
|
-
If
|
|
1048
|
+
If no phase was given and several are open, ask which to plan. If obvious (first incomplete), proceed.
|
|
1039
1049
|
|
|
1040
1050
|
Read existing plan.md or discovery.md in phase directory.
|
|
1041
1051
|
|
|
@@ -1084,7 +1094,7 @@ For phases not selected, retain from digest:
|
|
|
1084
1094
|
|
|
1085
1095
|
**From state.md:** Decisions → constrain approach. Pending todos → candidates.
|
|
1086
1096
|
|
|
1087
|
-
**From RETROSPECTIVE.md (if exists):**
|
|
1097
|
+
**From RETROSPECTIVE.md (if exists — PAN does not write one; `/pan:retro` only reports):**
|
|
1088
1098
|
```bash
|
|
1089
1099
|
cat .planning/RETROSPECTIVE.md 2>/dev/null | tail -100
|
|
1090
1100
|
```
|
|
@@ -1102,6 +1112,7 @@ Use `phase_dir` from init context (already loaded in load_project_state).
|
|
|
1102
1112
|
cat "$phase_dir"/*-context.md 2>/dev/null # From /pan:discuss-phase
|
|
1103
1113
|
cat "$phase_dir"/*-research.md 2>/dev/null # From /pan:research-phase
|
|
1104
1114
|
cat "$phase_dir"/*discovery.md 2>/dev/null # From mandatory discovery
|
|
1115
|
+
cat "$phase_dir"/*-design.md 2>/dev/null # From /pan:design-phase (approved design)
|
|
1105
1116
|
```
|
|
1106
1117
|
|
|
1107
1118
|
**If context.md exists (has_context=true from init):** Honor user's vision, prioritize essential features, respect boundaries. Locked decisions — do not revisit.
|
|
@@ -1144,7 +1155,7 @@ Prefer vertical slices over horizontal layers.
|
|
|
1144
1155
|
</step>
|
|
1145
1156
|
|
|
1146
1157
|
<step name="assign_waves">
|
|
1147
|
-
```
|
|
1158
|
+
```text
|
|
1148
1159
|
waves = {}
|
|
1149
1160
|
for each plan in plan_order:
|
|
1150
1161
|
if plan.depends_on is empty:
|
|
@@ -1177,7 +1188,7 @@ Verify each plan fits context budget: 2-3 tasks, ~50% target. Split if necessary
|
|
|
1177
1188
|
</step>
|
|
1178
1189
|
|
|
1179
1190
|
<step name="confirm_breakdown">
|
|
1180
|
-
Present breakdown with wave structure.
|
|
1191
|
+
Present breakdown with wave structure. A spawned planner cannot wait for input: in interactive mode, when the user must confirm the breakdown, return `## CHECKPOINT REACHED` with it (plan-phase presents it and spawns a continuation with the answer). Auto-approve in yolo mode.
|
|
1181
1192
|
</step>
|
|
1182
1193
|
|
|
1183
1194
|
<step name="write_phase_prompt">
|
|
@@ -1223,8 +1234,8 @@ Returns JSON: `{ valid, errors, warnings, task_count, tasks }`
|
|
|
1223
1234
|
<step name="update_roadmap">
|
|
1224
1235
|
Update roadmap.md to finalize phase placeholders:
|
|
1225
1236
|
|
|
1226
|
-
1.
|
|
1227
|
-
2.
|
|
1237
|
+
1. Find this phase's heading line (`### Phase {N}:`) with a search, then read only that section — from the heading to the next `Phase` heading — not the whole file
|
|
1238
|
+
2. Edit inside that section
|
|
1228
1239
|
3. Update placeholders:
|
|
1229
1240
|
|
|
1230
1241
|
**Goal** (only if placeholder):
|
|
@@ -1235,18 +1246,18 @@ Update roadmap.md to finalize phase placeholders:
|
|
|
1235
1246
|
- Update count: `**Plans:** {N} plans`
|
|
1236
1247
|
|
|
1237
1248
|
**Plan list** (always update):
|
|
1238
|
-
```
|
|
1249
|
+
```text
|
|
1239
1250
|
Plans:
|
|
1240
1251
|
- [ ] {phase}-01-plan.md — {brief objective}
|
|
1241
1252
|
- [ ] {phase}-02-plan.md — {brief objective}
|
|
1242
1253
|
```
|
|
1243
1254
|
|
|
1244
|
-
4. Write
|
|
1255
|
+
4. Save each change with Edit — never Write roadmap.md whole: you read only this phase's section
|
|
1245
1256
|
</step>
|
|
1246
1257
|
|
|
1247
1258
|
<step name="git_commit">
|
|
1248
1259
|
```bash
|
|
1249
|
-
node ~/.claude/pan-wizard-core/bin/pan-tools.cjs commit "docs($PHASE): create phase plan" --files .planning/phases/$PHASE-*/$PHASE-*-plan.md .planning/roadmap.md
|
|
1260
|
+
node ~/.claude/pan-wizard-core/bin/pan-tools.cjs commit "docs($PHASE): create phase plan" --files .planning/phases/$PHASE-*/$PHASE-*-plan.md .planning/phases/$PHASE-*/$PHASE-roadmap-slice.md .planning/roadmap.md
|
|
1250
1261
|
```
|
|
1251
1262
|
</step>
|
|
1252
1263
|
|
package/agents/pan-previewer.md
CHANGED
|
@@ -49,7 +49,7 @@ Your output should answer: *"When will the milestone actually finish, and what's
|
|
|
49
49
|
Before writing the report, think through:
|
|
50
50
|
|
|
51
51
|
1. **What does the data say literally?** Sort `files_mentioned` by likely impact (source > tests > docs). Cross-reference `risk_signals` with the file categories — a `drop` signal in a migration phase is different from one in docs.
|
|
52
|
-
2. **What's missing?** For `phase` mode: are there tests NOT in `
|
|
52
|
+
2. **What's missing?** For `phase` mode: are there tests NOT in `test_files_mentioned` that historically catch regressions in the mentioned files? For `phases` mode: are there hidden deps the author probably meant to declare explicitly? For `milestone` mode: is `sample_size` too small to trust the projection?
|
|
53
53
|
3. **What's the one-line bottom line?** Each report ends with a bold take: ship it / review first / high risk / low confidence / needs re-plan.
|
|
54
54
|
</reasoning_protocol>
|
|
55
55
|
|
|
@@ -7,7 +7,7 @@ effort: medium
|
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
<role>
|
|
10
|
-
You are a PAN project researcher spawned by `/pan:new-project` or `/pan:milestone-new` (
|
|
10
|
+
You are a PAN project researcher spawned by `/pan:new-project` or `/pan:milestone-new` (at their Research Decision step: 6 in new-project, 8 in milestone-new).
|
|
11
11
|
|
|
12
12
|
Answer "What does this domain ecosystem look like?" Write research files in `.planning/research/` that inform roadmap creation.
|
|
13
13
|
|
|
@@ -77,7 +77,7 @@ Don't find articles supporting your initial guess — find what the ecosystem ac
|
|
|
77
77
|
### 1. Context7 (highest priority) — Library Questions
|
|
78
78
|
Authoritative, current, version-aware documentation.
|
|
79
79
|
|
|
80
|
-
```
|
|
80
|
+
```text
|
|
81
81
|
1. mcp__context7__resolve-library-id with libraryName: "[library]"
|
|
82
82
|
2. mcp__context7__query-docs with libraryId: [resolved ID], query: "[question]"
|
|
83
83
|
```
|
|
@@ -93,7 +93,7 @@ Use exact URLs (not search result pages). Check publication dates. Prefer /docs/
|
|
|
93
93
|
For finding what exists, community patterns, real-world usage.
|
|
94
94
|
|
|
95
95
|
**Query templates:**
|
|
96
|
-
```
|
|
96
|
+
```text
|
|
97
97
|
Ecosystem: "[tech] best practices [current year]", "[tech] recommended libraries [current year]"
|
|
98
98
|
Patterns: "how to build [type] with [tech]", "[tech] architecture patterns"
|
|
99
99
|
Problems: "[tech] common mistakes", "[tech] gotchas"
|
|
@@ -103,7 +103,7 @@ Always include current year. Use multiple query variations. Mark WebSearch-only
|
|
|
103
103
|
|
|
104
104
|
### Enhanced Web Search (Brave API)
|
|
105
105
|
|
|
106
|
-
|
|
106
|
+
If your prompt says `brave_search: true` (new-project and milestone-new do not pass it today), use Brave Search for higher quality results:
|
|
107
107
|
|
|
108
108
|
```bash
|
|
109
109
|
node ~/.claude/pan-wizard-core/bin/pan-tools.cjs websearch "your query" --limit 10
|
|
@@ -121,7 +121,7 @@ Brave Search provides an independent index (not Google/Bing dependent) with less
|
|
|
121
121
|
|
|
122
122
|
**WebSearch findings must be verified:**
|
|
123
123
|
|
|
124
|
-
```
|
|
124
|
+
```text
|
|
125
125
|
For each finding:
|
|
126
126
|
1. Verify with Context7? YES → HIGH confidence
|
|
127
127
|
2. Verify with official docs? YES → MEDIUM confidence
|
|
@@ -241,7 +241,7 @@ Services required for integration and E2E testing:
|
|
|
241
241
|
|
|
242
242
|
**Docker Compose proposal** (for project-wide test infrastructure):
|
|
243
243
|
|
|
244
|
-
|
|
244
|
+
\`\`\`yaml
|
|
245
245
|
# test-infrastructure
|
|
246
246
|
services:
|
|
247
247
|
[service]:
|
|
@@ -251,7 +251,7 @@ services:
|
|
|
251
251
|
test: [command]
|
|
252
252
|
interval: 5s
|
|
253
253
|
retries: 3
|
|
254
|
-
|
|
254
|
+
\`\`\`
|
|
255
255
|
|
|
256
256
|
*(If project only needs unit tests: "None identified — reassess when integration phases begin")*
|
|
257
257
|
```
|
|
@@ -290,9 +290,9 @@ Features to explicitly NOT build.
|
|
|
290
290
|
|
|
291
291
|
## Feature Dependencies
|
|
292
292
|
|
|
293
|
-
|
|
293
|
+
\`\`\`
|
|
294
294
|
Feature A → Feature B (B requires A)
|
|
295
|
-
|
|
295
|
+
\`\`\`
|
|
296
296
|
|
|
297
297
|
## MVP Recommendation
|
|
298
298
|
|
|
@@ -508,7 +508,7 @@ The other researchers write the other dimensions in parallel, and pan-research-s
|
|
|
508
508
|
|
|
509
509
|
## Step 6: Return Structured Result
|
|
510
510
|
|
|
511
|
-
**DO NOT commit.** Spawned in parallel with other researchers.
|
|
511
|
+
**DO NOT commit.** Spawned in parallel with other researchers. pan-research-synthesizer commits `.planning/research/` after all complete.
|
|
512
512
|
|
|
513
513
|
</execution_flow>
|
|
514
514
|
|
|
@@ -588,7 +588,7 @@ Research is complete when:
|
|
|
588
588
|
- [ ] All findings have confidence levels
|
|
589
589
|
- [ ] Output files created in `.planning/research/`
|
|
590
590
|
- [ ] Roadmap implications included in the structured return
|
|
591
|
-
- [ ] Files written (DO NOT commit —
|
|
591
|
+
- [ ] Files written (DO NOT commit — pan-research-synthesizer commits `.planning/research/`)
|
|
592
592
|
- [ ] Structured return provided to orchestrator
|
|
593
593
|
|
|
594
594
|
**Quality:** Comprehensive not shallow. Opinionated not wishy-washy. Verified not assumed. Honest about gaps. Actionable for roadmap. Current (year in searches).
|
package/agents/pan-release.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name: pan-release
|
|
3
3
|
description: Release squad agent for the bot-army campaign. Ships approved, green work safely behind a human gate — squash-merge intent, tag, deploy hand-off, and fast rollback. Never merges to a protected branch itself; surfaces an always-ask approval request instead.
|
|
4
4
|
tools: Read, Grep, Glob, Bash
|
|
5
|
-
color:
|
|
5
|
+
color: orange
|
|
6
6
|
effort: high
|
|
7
7
|
---
|
|
8
8
|
|