pan-wizard 3.26.0 → 3.28.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/README.md +48 -48
  2. package/agents/pan-previewer.md +1 -1
  3. package/bin/install-lib.cjs +580 -18
  4. package/bin/install.js +25 -44
  5. package/commands/pan/army.md +1 -1
  6. package/commands/pan/hygiene.md +14 -8
  7. package/commands/pan/milestone-audit.md +10 -4
  8. package/commands/pan/preview.md +2 -2
  9. package/hooks/dist/pan-cost-logger.js +69 -5
  10. package/hooks/dist/pan-stop-guard.js +32 -1
  11. package/hooks/dist/pan-trace-logger.js +35 -2
  12. package/package.json +5 -2
  13. package/pan-wizard-core/bin/lib/bridge.cjs +0 -1
  14. package/pan-wizard-core/bin/lib/bus.cjs +0 -1
  15. package/pan-wizard-core/bin/lib/campaign.cjs +3 -2
  16. package/pan-wizard-core/bin/lib/commands-learnings.cjs +8 -8
  17. package/pan-wizard-core/bin/lib/commands.cjs +15 -14
  18. package/pan-wizard-core/bin/lib/config.cjs +5 -5
  19. package/pan-wizard-core/bin/lib/constants.cjs +49 -0
  20. package/pan-wizard-core/bin/lib/context-budget.cjs +98 -0
  21. package/pan-wizard-core/bin/lib/core.cjs +190 -26
  22. package/pan-wizard-core/bin/lib/cost.cjs +113 -11
  23. package/pan-wizard-core/bin/lib/distill.cjs +3 -3
  24. package/pan-wizard-core/bin/lib/focus.cjs +16 -16
  25. package/pan-wizard-core/bin/lib/foreign-planning.cjs +56 -0
  26. package/pan-wizard-core/bin/lib/hud.cjs +1 -1
  27. package/pan-wizard-core/bin/lib/hygiene.cjs +428 -37
  28. package/pan-wizard-core/bin/lib/init.cjs +98 -13
  29. package/pan-wizard-core/bin/lib/knowledge.cjs +0 -1
  30. package/pan-wizard-core/bin/lib/memory.cjs +1 -1
  31. package/pan-wizard-core/bin/lib/milestone.cjs +3 -3
  32. package/pan-wizard-core/bin/lib/optimize.cjs +3 -3
  33. package/pan-wizard-core/bin/lib/phase.cjs +4 -4
  34. package/pan-wizard-core/bin/lib/planning-root.cjs +327 -0
  35. package/pan-wizard-core/bin/lib/preview.cjs +0 -1
  36. package/pan-wizard-core/bin/lib/review-deep.cjs +0 -1
  37. package/pan-wizard-core/bin/lib/roadmap.cjs +1 -1
  38. package/pan-wizard-core/bin/lib/state-compact.cjs +339 -0
  39. package/pan-wizard-core/bin/lib/state.cjs +0 -1
  40. package/pan-wizard-core/bin/lib/template.cjs +1 -1
  41. package/pan-wizard-core/bin/lib/utils.cjs +39 -11
  42. package/pan-wizard-core/bin/lib/verify.cjs +26 -5
  43. package/pan-wizard-core/bin/lib/whatif.cjs +0 -1
  44. package/pan-wizard-core/bin/pan-tools.cjs +58 -4
  45. package/pan-wizard-core/mcp/server.cjs +92 -8
  46. package/pan-wizard-core/mcp/tool-registry.cjs +50 -3
  47. package/pan-wizard-core/references/model-profiles.md +2 -2
  48. package/pan-wizard-core/workflows/health.md +1 -0
  49. package/pan-wizard-core/workflows/milestone-audit.md +35 -6
  50. package/pan-zcode/README.md +1 -1
  51. package/scripts/build-agent-plugin.js +220 -0
  52. package/scripts/build-plugin.js +48 -3
  53. package/scripts/generate-skills-docs.py +1 -1
  54. package/scripts/release-check.js +58 -12
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  # PanWizard
6
6
 
7
- **Command a bot army for your codebase** — a *Mission Control* agent delegates whole-project goals to specialist squads and ships behind a human merge gate. Five AI CLIs, zero context rot.
7
+ **Command a bot army for your codebase** — a *Mission Control* agent delegates whole-project goals to specialist squads and ships behind a human merge gate (the army runs on Claude Code; the planning pipeline runs on all five CLIs). Five AI CLIs, zero context rot.
8
8
 
9
9
  **Solves context rot** — the quality degradation that happens as the model fills its context window.
10
10
 
@@ -42,7 +42,7 @@ PAN is the context engineering layer that makes Claude Code reliable. It breaks
42
42
 
43
43
  ### Architecture
44
44
 
45
- ```
45
+ ```text
46
46
  ┌─────────────────────────────────────────────────────────────┐
47
47
  │ YOU │
48
48
  │ /pan:new-project → /pan:plan-phase → /pan:exec-phase │
@@ -76,7 +76,7 @@ PAN is the context engineering layer that makes Claude Code reliable. It breaks
76
76
 
77
77
  ## Bot Army
78
78
 
79
- > **Don't run one phase — run the whole project.** `/pan:army` turns PAN's agents into a coordinated army that delivers a goal end-to-end: a **Mission Control** agent plans the mission and delegates to specialist **squads**, parallel builders each work an isolated git worktree, and **nothing reaches your main branch without green checks and your explicit approval.**
79
+ > **Don't run one phase — run the whole project.** `/pan:army` (Claude Code only — it needs native sub-agent spawning; the other runtimes run the flat pipeline) turns PAN's agents into a coordinated army that delivers a goal end-to-end: a **Mission Control** agent plans the mission and delegates to specialist **squads**, parallel builders each work an isolated git worktree, and **nothing reaches your main branch without green checks and your explicit approval.**
80
80
 
81
81
  <div align="center">
82
82
  <img src="https://cdn.jsdelivr.net/npm/pan-wizard@latest/assets/pan-orchestration.png" alt="PanWizard specialist agents orchestrated along a pipeline" width="340" />
@@ -101,9 +101,9 @@ PAN is the context engineering layer that makes Claude Code reliable. It breaks
101
101
 
102
102
  - **A human merges.** The Release squad prepares a squash-merge and surfaces an `always-ask` approval instead of merging; pair it with branch protection on your repo, which is what makes that unbypassable rather than merely instructed. Recovery is `git revert` or the previous tag, never a force-push.
103
103
  - **Isolated builders.** Each Build agent forks its own `army/<task>` branch + git worktree, so parallel agents never share a file.
104
- - **Caps.** Delegation-depth cap, per-cycle spawn + budget ceilings, and a `.planning/orchestration/abort` kill-switch, re-checked before every spawn — the same harness as hierarchical exec, at campaign scale.
104
+ - **Caps.** Delegation-depth cap, per-cycle spawn + budget ceilings, and a `.planning/orchestration/abort` kill-switch, re-checked before every spawn by Mission Control's protocol (prompt-enforced; the MCP `pan_next_action` path enforces the cycle cap, the budget cap when `caps.enforceBudget` is set, the abort switch and the human gate in code — delegation depth is bounded by which agents hold the `Task` tool) — the same harness as hierarchical exec, at campaign scale.
105
105
 
106
- **Run it over days.** `--schedule` arms a self-resuming campaign with a per-day budget that burns the backlog down across sessions — and *still* waits for you at every merge. **Autonomy runs up to the irreversible step; a human is at the step.**
106
+ **Run it over days.** `--schedule` arms a resumable campaign with a per-day budget that burns the backlog down across sessions (the per-day budget is advisory — `campaign status` shows the day's spend — and an external scheduler triggers each `--continue`) — and *still* waits for you at every merge. **Autonomy runs up to the irreversible step; a human is at the step.**
107
107
 
108
108
  **Watch it live.** `/pan:hud` renders a single self-contained HTML dashboard — Mission Control over the squads, in-flight worktrees, campaign budget, telemetry, and the safety harness — in one page.
109
109
 
@@ -130,9 +130,7 @@ People who want to describe what they want and have it built correctly — witho
130
130
  npx pan-wizard@latest
131
131
  ```
132
132
 
133
- The installer prompts you to choose:
134
- 1. **Runtime** — Claude Code, OpenCode, Gemini, Codex, Copilot CLI, or all
135
- 2. **Location** — Global (all projects) or local (current project only)
133
+ The installer prompts you to choose the **runtime** — Claude Code, OpenCode, Gemini, Codex, Copilot CLI, or all. Location is not prompted: it defaults to the current project (`--local`); pass `--global` to install into your home config directory instead.
136
134
 
137
135
  Verify with:
138
136
  - Claude Code / Gemini: `/pan:help`
@@ -176,7 +174,7 @@ npx pan-wizard --copilot --local # Install to ./.github/
176
174
  npx pan-wizard --all --global # Install to all directories
177
175
  ```
178
176
 
179
- Use `--global` (`-g`) or `--local` (`-l`) to skip the location prompt.
177
+ Use `--global` (`-g`) to install into your home config directory; `--local` (`-l`) is the default and may be omitted.
180
178
  Use `--claude`, `--opencode`, `--gemini`, `--codex`, `--copilot`, or `--all` to skip the runtime prompt.
181
179
  Add `--unified-skills` to install commands as one shared `.agents/skills/` tree read natively by every runtime (and Antigravity CLI) instead of per-runtime formats — see the User Guide for details.
182
180
 
@@ -285,11 +283,11 @@ If you prefer not to use that flag, add this to your project's `.claude/settings
285
283
 
286
284
  ## How It Works
287
285
 
288
- > **Already have code?** Run `/pan:map-codebase` first. It spawns parallel agents to analyze your stack, architecture, conventions, and concerns. Then `/pan:new-project` knows your codebase — questions focus on what you're adding, and planning automatically loads your patterns.
286
+ > **Already have code?** Run `/pan:map-codebase` first. It analyzes your stack, architecture, conventions, and concerns — single-shot with one agent for repositories under the sharding threshold, six-way sharded above it. Then `/pan:new-project` knows your codebase — questions focus on what you're adding, and planning automatically loads your patterns.
289
287
 
290
288
  ### 1. Initialize Project
291
289
 
292
- ```
290
+ ```text
293
291
  /pan:new-project
294
292
  ```
295
293
 
@@ -308,7 +306,7 @@ You approve the roadmap. Now you're ready to build.
308
306
 
309
307
  ### 2. Discuss Phase
310
308
 
311
- ```
309
+ ```text
312
310
  /pan:discuss-phase 1
313
311
  ```
314
312
 
@@ -336,15 +334,15 @@ The deeper you go here, the more the system builds what you actually want. Skip
336
334
 
337
335
  ### 3. Plan Phase
338
336
 
339
- ```
337
+ ```text
340
338
  /pan:plan-phase 1
341
339
  ```
342
340
 
343
341
  The system:
344
342
 
345
343
  1. **Researches** — Investigates how to implement this phase, guided by your context.md decisions
346
- 2. **Plans** — Creates 2-3 atomic task plans with XML structure
347
- 3. **Verifies** — Checks plans against requirements, loops until they pass
344
+ 2. **Plans** — Creates atomic plans of 2-3 tasks each, with XML structure
345
+ 3. **Verifies** — Checks plans against requirements; up to three checker passes (two revisions), then the remaining issues come to you
348
346
 
349
347
  Each plan is small enough to execute in a fresh context window. No degradation, no "I'll be more concise now."
350
348
 
@@ -354,15 +352,15 @@ Each plan is small enough to execute in a fresh context window. No degradation,
354
352
 
355
353
  ### 4. Execute Phase
356
354
 
357
- ```
355
+ ```text
358
356
  /pan:exec-phase 1
359
357
  ```
360
358
 
361
359
  The system:
362
360
 
363
361
  1. **Runs plans in waves** — Parallel where possible, sequential when dependent
364
- 2. **Fresh context per plan** — a whole context window purely for implementation, zero accumulated garbage
365
- 3. **Commits per task** — Every task gets its own atomic commit
362
+ 2. **Fresh context per plan** — a whole context window purely for implementation, zero accumulated garbage (native sub-agent spawning on Claude Code; the other runtimes delegate through their own agent mechanism)
363
+ 3. **Commits per task** — Every task gets its own atomic commit (consecutive trivial chore or docs tasks may be coalesced into one)
366
364
  4. **Verifies against goals** — Checks the codebase delivers what the phase promised
367
365
 
368
366
  Walk away, come back to completed work with clean git history.
@@ -371,7 +369,7 @@ Walk away, come back to completed work with clean git history.
371
369
 
372
370
  Plans are grouped into "waves" based on dependencies. Within each wave, plans run in parallel. Waves run sequentially.
373
371
 
374
- ```
372
+ ```text
375
373
  ┌─────────────────────────────────────────────────────────────────────┐
376
374
  │ PHASE EXECUTION │
377
375
  ├─────────────────────────────────────────────────────────────────────┤
@@ -405,36 +403,36 @@ This is why "vertical slices" (Plan 01: User feature end-to-end) parallelize bet
405
403
 
406
404
  ### 5. Verify Work
407
405
 
408
- ```
406
+ ```text
409
407
  /pan:verify-phase 1
410
408
  ```
411
409
 
412
410
  **This is where you confirm it actually works.**
413
411
 
414
- Automated verification checks that code exists and tests pass. But does the feature *work* the way you expected? This is your chance to use it.
412
+ Automated verification checks that code exists and tests pass. `/pan:verify-phase` re-runs that check on demand, goal-backward: does the codebase deliver what the phase promised?
415
413
 
416
414
  The system:
417
415
 
418
- 1. **Extracts testable deliverables** — What you should be able to do now
419
- 2. **Walks you through one at a time** — "Can you log in with email?" Yes/no, or describe what's wrong
420
- 3. **Diagnoses failures automatically** — Spawns debug agents to find root causes
421
- 4. **Creates verified fix plans** — Ready for immediate re-execution
416
+ 1. **Gates on the test suite** — a failing (or non-running) suite forces the verdict to `gaps_found`; the must-have checks still run so the report is complete
417
+ 2. **Checks every must-have** — each phase promise is verified against the code, not the task list
418
+ 3. **Reports the gaps** — a verification report with a per-truth status and the recommended fix plans
419
+ 4. **Hands the gaps to the planner** — `/pan:plan-phase N --gaps` writes the fix plans (`gap_closure: true`); `/pan:exec-phase N --gaps-only` runs just those
422
420
 
423
- If everything passes, you move on. If something's broken, you don't manually debug — you just run `/pan:exec-phase` again with the fix plans it created.
421
+ On Claude Code, `/pan-diagnose-issues <phase>` spawns one debugger per failed UAT truth to find root causes. Manual acceptance testing stays yours: use the feature and record what you find in the phase's UAT file.
424
422
 
425
- **Creates:** `{phase_num}-uat.md`, fix plans if issues found
423
+ **Creates:** `{phase_num}-verification.md`; fix plans follow from `/pan:plan-phase N --gaps`
426
424
 
427
425
  ---
428
426
 
429
427
  ### 6. Repeat → Complete → Next Milestone
430
428
 
431
- ```
429
+ ```text
432
430
  /pan:discuss-phase 2
433
431
  /pan:plan-phase 2
434
432
  /pan:exec-phase 2
435
433
  /pan:verify-phase 2
436
434
  ...
437
- /pan:milestone-done
435
+ /pan:milestone-done 1.0
438
436
  /pan:milestone-new
439
437
  ```
440
438
 
@@ -450,7 +448,7 @@ Then `/pan:milestone-new` starts the next version — same flow as `new-project`
450
448
 
451
449
  ### Quick Mode
452
450
 
453
- ```
451
+ ```text
454
452
  /pan:quick
455
453
  ```
456
454
 
@@ -464,12 +462,12 @@ Quick mode gives you PAN guarantees (atomic commits, state tracking) with a fast
464
462
 
465
463
  Use for: bug fixes, small features, config changes, one-off tasks.
466
464
 
467
- ```
465
+ ```text
468
466
  /pan:quick
469
467
  > What do you want to do? "Add dark mode toggle to settings"
470
468
  ```
471
469
 
472
- **Creates:** `.planning/quick/001-add-dark-mode-toggle/plan.md`, `summary.md`
470
+ **Creates:** `.planning/quick/001-add-dark-mode-toggle/001-plan.md`, `001-summary.md`
473
471
 
474
472
  ---
475
473
 
@@ -522,7 +520,7 @@ Every stage uses the same pattern: a thin orchestrator spawns specialized agents
522
520
  | Stage | Orchestrator does | Agents do |
523
521
  |-------|------------------|-----------|
524
522
  | Research | Coordinates, presents findings | 4 parallel researchers investigate stack, features, architecture, pitfalls |
525
- | Planning | Validates, manages iteration | Planner creates plans, checker verifies, loop until pass |
523
+ | Planning | Validates, manages iteration | Planner creates plans, checker verifies, up to three passes |
526
524
  | Execution | Groups into waves, tracks progress | Executors implement in parallel, each with a fresh context window |
527
525
  | Verification | Presents results, routes next | Verifier checks codebase against goals, debuggers diagnose failures |
528
526
 
@@ -550,7 +548,7 @@ PAN runs autonomous experiments in isolated folders, harvests the resulting tele
550
548
 
551
549
  ### Atomic Git Commits
552
550
 
553
- Each task gets its own commit immediately after completion:
551
+ Each task gets its own commit immediately after completion (consecutive trivial chore or docs tasks are coalesced):
554
552
 
555
553
  ```bash
556
554
  abc123f docs(08-02): complete user registration plan
@@ -604,9 +602,9 @@ PAN is not a replacement for your IDE or AI agent — it's the orchestration lay
604
602
  | `/pan:design-phase [N]` | Design a phase — architecture, ADR, threat-lite — before planning |
605
603
  | `/pan:plan-phase [N] [--auto]` | Research + plan + verify for a phase |
606
604
  | `/pan:exec-phase <N>` | Execute all plans in parallel waves, verify when complete |
607
- | `/pan:verify-phase [N]` | Manual user acceptance testing ¹ |
605
+ | `/pan:verify-phase [N]` | Re-run goal-backward verification with a test-suite gate; lists gaps for `/pan:plan-phase N --gaps` ¹ |
608
606
  | `/pan:milestone-audit` | Verify milestone achieved its definition of done |
609
- | `/pan:milestone-done` | Archive milestone, tag release |
607
+ | `/pan:milestone-done <version>` | Archive milestone, tag release |
610
608
  | `/pan:milestone-new [name]` | Start next version: questions → research → requirements → roadmap |
611
609
 
612
610
  ### Navigation
@@ -615,6 +613,7 @@ PAN is not a replacement for your IDE or AI agent — it's the orchestration lay
615
613
  |---------|--------------|
616
614
  | `/pan:progress` | Where am I? What's next? |
617
615
  | `/pan:hud` (alias `/pan:dashboard`) | Render a self-contained HTML dashboard of project + bot-army state to `.planning/hud.html` (`--open`, `--out`, `--stdout`) |
616
+ | `/pan:report phase <N> \| index \| all` | Self-contained HTML report for one phase, or a timeline index linking every phase report (`--out`, `--open`, `--stdout`; `--bundle` on `index` inlines every phase report into one file) |
618
617
  | `/pan:help` | Show all commands and usage guide |
619
618
  | `/pan:update` | Update PAN with changelog preview |
620
619
  | `/pan:discord` | Join the PAN Discord community |
@@ -635,9 +634,9 @@ PAN is not a replacement for your IDE or AI agent — it's the orchestration lay
635
634
 
636
635
  | Command | What it does |
637
636
  |---------|--------------|
638
- | `/pan:add-phase` | Append phase to roadmap |
639
- | `/pan:insert-phase [N]` | Insert urgent work between phases |
640
- | `/pan:remove-phase [N]` | Remove future phase, renumber |
637
+ | `/pan:add-phase <description>` | Append phase to roadmap |
638
+ | `/pan:insert-phase <after> <description>` | Insert urgent work between phases |
639
+ | `/pan:remove-phase <N>` | Remove future phase, renumber |
641
640
  | `/pan:assumptions [N]` | See Claude's intended approach before planning |
642
641
  | `/pan:milestone-gaps` | Create phases to close gaps from audit |
643
642
 
@@ -659,14 +658,15 @@ PAN is not a replacement for your IDE or AI agent — it's the orchestration lay
659
658
  | `/pan:debug [desc]` | Systematic debugging with persistent state |
660
659
  | `/pan:quick [--full]` | Execute ad-hoc task with PAN guarantees (`--full` adds plan-checking and verification) |
661
660
  | `/pan:health [--repair]` | Validate `.planning/` directory integrity; `--repair` auto-fixes detected issues |
662
- | `/pan:hygiene [--apply] [--trace-age-days N]` | Scan for PAN version drift and stale project artifacts (legacy filenames, .tmp orphans, memory bloat, poisoned cost ledgers, trace debris, fragment planning dirs); `--apply` executes the safe fixes — ledgers are quarantined by rename, never deleted |
661
+ | `/pan:hygiene [--apply] [--trace-age-days N] [--all-tracks]` | Scan for PAN version drift and stale project artifacts (legacy filenames, .tmp orphans, memory bloat, poisoned cost ledgers, trace and report debris, cached-context bloat, fragment planning dirs); `--apply` executes the safe fixes — poisoned ledgers are quarantined by rename (only the newest quarantine copy is kept), and settled `state.md` history is archived rather than dropped |
663
662
  | `/pan:links [--strict]` | Validate the doc-code link graph: inline `[[<id>]]` refs, `// @pan:` source anchors, `require-code-mention` contracts (ADR-0027, v3.8.0+) |
664
- | `/pan:phase-tests [N]` | Generate tests for a completed phase based on UAT criteria |
663
+ | `/pan:phase-tests <N> [instructions]` | Generate tests for a completed phase based on UAT criteria |
665
664
  | `/pan:milestone-cleanup` | Archive accumulated phase directories from completed milestones |
666
665
  | `/pan:retro` | Milestone retrospective — estimation accuracy, verification patterns, gap analysis |
667
666
  | `/pan:patches` | Restore local modifications after a PAN update |
668
667
  | `/pan:research-phase [N]` | Standalone deep research for a phase (usually part of plan-phase) |
669
668
  | `/pan:phase-budget` | Estimate context window utilization for current phase |
669
+ | `/pan:experiment <subcommand>` | Manage external self-improvement experiments — scaffold, run, harvest, promote findings back to PAN (never inside the PAN source repo) |
670
670
 
671
671
  ### Operations
672
672
 
@@ -710,7 +710,7 @@ PAN is not a replacement for your IDE or AI agent — it's the orchestration lay
710
710
  | `/pan:learn` | Analyze trace events, generate optimization report with auto-apply block |
711
711
  | `/pan:optimize {apply\|list\|stats\|trace}` | Apply optimizer recommendations, list reports, view stats, manage trace sessions |
712
712
  | `/pan:git <subcommand>` | Phase-aware git workflow: commit/branch/push/status/log/stash/diff/rollback/tag/sync |
713
- | `/pan:audit-deployment` | Audit a PAN installation for integrity (manifest verification, drift detection) |
713
+ | `/pan:audit-deployment <target-directory> [--enhancements] [--repair]` | Audit a PAN installation for integrity, project health, and draft enhancement specs |
714
714
 
715
715
  <sup>¹ Contributed by reddit user OracleGreyBeard</sup>
716
716
 
@@ -724,8 +724,8 @@ PAN stores project settings in `.planning/config.json`. Configure during `/pan:n
724
724
 
725
725
  | Setting | Options | Default | What it controls |
726
726
  |---------|---------|---------|------------------|
727
- | `mode` | `yolo`, `interactive` | `interactive` | Auto-approve vs confirm at each step |
728
- | `depth` | `quick`, `standard`, `comprehensive` | `standard` | Planning thoroughness (phases × plans) |
727
+ | `mode` | `yolo`, `interactive` | chosen at `/pan:new-project` (usually `interactive`) | Auto-approve vs confirm at each step |
728
+ | `depth` | `quick`, `standard`, `comprehensive` | chosen at `/pan:new-project` (usually `standard`) | Planning thoroughness (phases × plans) |
729
729
 
730
730
  ### Model Profiles
731
731
 
@@ -737,10 +737,10 @@ Control which Claude model each agent uses. Balance quality vs token spend.
737
737
  | `balanced` (default) | reasoning | reasoning | reasoning |
738
738
  | `budget` | Sonnet | Sonnet | Haiku |
739
739
 
740
- > `reasoning` = the session model (inherit) — every agent runs on the model you launched the session with. Both `quality` and `balanced` resolve this way; only `budget` steps down to a Sonnet/Haiku mix. Actual assignment varies by agent role — see [User Guide](docs/USER-GUIDE.md#model-profiles-per-agent-breakdown) for the full per-agent breakdown.
740
+ > `reasoning` = the session model (inherit) — every agent runs on the model you launched the session with, except the reviewer-class agents (reviewer, hardener, meta-reviewer), which pin a reasoning-tier model. Both `quality` and `balanced` resolve this way; only `budget` steps down to a Sonnet/Haiku mix. Actual assignment varies by agent role — see [User Guide](docs/USER-GUIDE.md#model-profiles-per-agent-breakdown) for the full per-agent breakdown.
741
741
 
742
742
  Switch profiles:
743
- ```
743
+ ```text
744
744
  /pan:profile budget
745
745
  ```
746
746
 
@@ -784,7 +784,7 @@ Control how PAN handles branches during execution.
784
784
  - **`phase`** — Creates a branch per phase, merges at phase completion
785
785
  - **`milestone`** — Creates one branch for entire milestone, merges at completion
786
786
 
787
- At milestone completion, PAN Wizard offers squash merge (recommended) or merge with history.
787
+ At milestone completion you merge the milestone branch yourself (`git merge --squash` or `--no-ff`); `/pan:milestone-done <version>` archives and tags but does not merge.
788
788
 
789
789
  ---
790
790
 
@@ -883,7 +883,7 @@ This removes all PAN commands, agents, hooks, and settings while preserving your
883
883
  | [Development Guide](docs/DEVELOPMENT.md) | Contributors | Setup, how to add commands/agents/tests, cross-platform pitfalls |
884
884
  | [CLI Reference](docs/CLI-REFERENCE.md) | Contributors | Every pan-tools.cjs subcommand with args, flags, and JSON output |
885
885
  | [Agent System](docs/AGENTS.md) | Contributors | Agent inventory, lifecycle, model profiles, collaboration patterns |
886
- | [Hook System](docs/HOOKS.md) | Contributors | 5 built-in hooks, bridge file architecture, custom hook development |
886
+ | [Hook System](docs/HOOKS.md) | Contributors | The built-in hooks, bridge file architecture, custom hook development |
887
887
  | [Internals](docs/INTERNALS.md) | Power Users | Checkpoint system, TDD, verification patterns, model profiles |
888
888
  | [Troubleshooting](docs/TROUBLESHOOTING.md) | Users | Deep-dive diagnostics for execution, state, git, and verification issues |
889
889
  | [Contributing](CONTRIBUTING.md) | Contributors | Project structure, code style, PR process |
@@ -57,7 +57,7 @@ Before writing the report, think through:
57
57
 
58
58
  Write exactly one file at the path provided in your prompt. Use the template at `~/.claude/pan-wizard-core/templates/preview-report.md` as the skeleton.
59
59
 
60
- **For `phase` mode**, output path is `.planning/phases/<N>/preview.md`. Required sections:
60
+ **For `phase` mode**, output path is `.planning/phases/<NN-slug>/preview.md`. Required sections:
61
61
  - `# Phase Preview: Phase N — <name>`
62
62
  - `## Summary` (one paragraph — what this phase changes + risk verdict)
63
63
  - `## Files likely touched` (bulleted, grouped by source/tests/docs)