create-quiver 0.13.0 → 0.14.1

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 (92) hide show
  1. package/CHANGELOG.md +30 -0
  2. package/README.md +183 -511
  3. package/README_FOR_AI.md +36 -26
  4. package/ROADMAP.md +11 -0
  5. package/assets/quiver-wordmark.svg +22 -0
  6. package/docs/AI_CONTEXT.md.template +2 -0
  7. package/docs/AI_ONBOARDING_PROMPT.md.template +9 -1
  8. package/docs/CLI_UX_GUIDE.md +125 -0
  9. package/docs/COMMANDS.md.template +19 -4
  10. package/docs/GITFLOW_PR_GUIDE.md +70 -0
  11. package/docs/TROUBLESHOOTING.md.template +29 -0
  12. package/docs/WORKFLOW.md.template +13 -12
  13. package/docs/getting-started/linux.md +84 -0
  14. package/docs/getting-started/macos.md +85 -0
  15. package/docs/getting-started/windows-git-bash-wsl.md +78 -0
  16. package/docs/getting-started/windows-powershell.md +96 -0
  17. package/docs/reference/commands.md +94 -0
  18. package/docs/workflows/existing-project.md +131 -0
  19. package/docs/workflows/full-ai-spec-to-pr.md +311 -0
  20. package/docs/workflows/legacy-quiver-project.md +102 -0
  21. package/docs/workflows/new-project.md +76 -0
  22. package/package.json +5 -1
  23. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/COVERAGE_MATRIX.md +117 -0
  24. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/EVIDENCE_REPORT.md +200 -0
  25. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/EXECUTION_PLAN.md +60 -0
  26. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/SPEC.md +132 -0
  27. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/STATUS.md +36 -0
  28. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/pr.md +128 -0
  29. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-00-reconciliation-and-evidence-freeze/CLOSURE_BRIEF.md +44 -0
  30. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-00-reconciliation-and-evidence-freeze/EXECUTION_BRIEF.md +56 -0
  31. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-00-reconciliation-and-evidence-freeze/slice.json +71 -0
  32. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-01-ai-run-state-approvals-and-clean-output/CLOSURE_BRIEF.md +38 -0
  33. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-01-ai-run-state-approvals-and-clean-output/EXECUTION_BRIEF.md +53 -0
  34. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-01-ai-run-state-approvals-and-clean-output/slice.json +83 -0
  35. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-02-structured-technical-plan-contract-and-repair-flow/CLOSURE_BRIEF.md +33 -0
  36. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-02-structured-technical-plan-contract-and-repair-flow/EXECUTION_BRIEF.md +53 -0
  37. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-02-structured-technical-plan-contract-and-repair-flow/slice.json +85 -0
  38. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-03-active-slice-reconciliation-and-ai-inspect/CLOSURE_BRIEF.md +34 -0
  39. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-03-active-slice-reconciliation-and-ai-inspect/EXECUTION_BRIEF.md +52 -0
  40. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-03-active-slice-reconciliation-and-ai-inspect/slice.json +82 -0
  41. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-04-spec-validation-scope-and-worktree-reliability/CLOSURE_BRIEF.md +32 -0
  42. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-04-spec-validation-scope-and-worktree-reliability/EXECUTION_BRIEF.md +55 -0
  43. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-04-spec-validation-scope-and-worktree-reliability/slice.json +85 -0
  44. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-05-review-plan-closure-and-agent-dx/CLOSURE_BRIEF.md +35 -0
  45. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-05-review-plan-closure-and-agent-dx/EXECUTION_BRIEF.md +59 -0
  46. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-05-review-plan-closure-and-agent-dx/slice.json +94 -0
  47. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-06-backward-compatibility-docs-and-release-readiness/CLOSURE_BRIEF.md +40 -0
  48. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-06-backward-compatibility-docs-and-release-readiness/EXECUTION_BRIEF.md +56 -0
  49. package/specs/quiver-v28-pixel-quiver-feedback-reconciliation/slices/slice-06-backward-compatibility-docs-and-release-readiness/slice.json +98 -0
  50. package/specs/quiver-v29-planner-prepare-context-cli-ux/EVIDENCE_REPORT.md +163 -0
  51. package/specs/quiver-v29-planner-prepare-context-cli-ux/EXECUTION_PLAN.md +72 -0
  52. package/specs/quiver-v29-planner-prepare-context-cli-ux/SPEC.md +173 -0
  53. package/specs/quiver-v29-planner-prepare-context-cli-ux/STATUS.md +34 -0
  54. package/specs/quiver-v29-planner-prepare-context-cli-ux/pr.md +95 -0
  55. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-00-cli-ux-spec-foundation/CLOSURE_BRIEF.md +32 -0
  56. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-00-cli-ux-spec-foundation/EXECUTION_BRIEF.md +45 -0
  57. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-00-cli-ux-spec-foundation/slice.json +58 -0
  58. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-01-cli-ux-primitives-theme/CLOSURE_BRIEF.md +33 -0
  59. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-01-cli-ux-primitives-theme/EXECUTION_BRIEF.md +49 -0
  60. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-01-cli-ux-primitives-theme/slice.json +75 -0
  61. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-02-planner-context-proposal-contract/CLOSURE_BRIEF.md +32 -0
  62. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-02-planner-context-proposal-contract/EXECUTION_BRIEF.md +47 -0
  63. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-02-planner-context-proposal-contract/slice.json +71 -0
  64. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-03-prepare-context-planner-review-flow/CLOSURE_BRIEF.md +33 -0
  65. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-03-prepare-context-planner-review-flow/EXECUTION_BRIEF.md +52 -0
  66. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-03-prepare-context-planner-review-flow/slice.json +82 -0
  67. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-04-ux-flag-matrix-compatibility/CLOSURE_BRIEF.md +34 -0
  68. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-04-ux-flag-matrix-compatibility/EXECUTION_BRIEF.md +46 -0
  69. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-04-ux-flag-matrix-compatibility/slice.json +73 -0
  70. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-05-progressive-command-adoption/CLOSURE_BRIEF.md +34 -0
  71. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-05-progressive-command-adoption/EXECUTION_BRIEF.md +46 -0
  72. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-05-progressive-command-adoption/slice.json +83 -0
  73. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-06-docs-tests-smoke-readiness/CLOSURE_BRIEF.md +31 -0
  74. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-06-docs-tests-smoke-readiness/EXECUTION_BRIEF.md +50 -0
  75. package/specs/quiver-v29-planner-prepare-context-cli-ux/slices/slice-06-docs-tests-smoke-readiness/slice.json +95 -0
  76. package/src/create-quiver/commands/ai.js +938 -16
  77. package/src/create-quiver/commands/spec.js +74 -2
  78. package/src/create-quiver/index.js +91 -5
  79. package/src/create-quiver/lib/ai/context-packs.js +2 -2
  80. package/src/create-quiver/lib/ai/context-proposal.js +389 -0
  81. package/src/create-quiver/lib/ai/context-proposal.schema.js +31 -0
  82. package/src/create-quiver/lib/ai/export-state.js +52 -5
  83. package/src/create-quiver/lib/ai/github.js +14 -2
  84. package/src/create-quiver/lib/ai/plan-review.js +159 -0
  85. package/src/create-quiver/lib/ai/run-state.js +17 -2
  86. package/src/create-quiver/lib/ai/spec-generator.js +15 -0
  87. package/src/create-quiver/lib/cli/editor.js +118 -0
  88. package/src/create-quiver/lib/cli/theme.js +100 -0
  89. package/src/create-quiver/lib/cli/ux-flags.js +151 -0
  90. package/src/create-quiver/lib/cli/ux.js +130 -0
  91. package/src/create-quiver/lib/project-state-resolver.js +195 -1
  92. package/src/create-quiver/lib/spec-worktrees.js +50 -2
package/README_FOR_AI.md CHANGED
@@ -8,6 +8,7 @@ Important: slice numbering resets inside each spec. `slice-00` is the mandatory
8
8
  The canonical installer entrypoint is `npx create-quiver` run from the target project root.
9
9
  Do not recommend global installation; use `npx` or a project-local devDependency when the team needs a pinned version.
10
10
  The package also exposes `quiver` as a binary alias to the same CLI. Treat it as a local installed shortcut, not as a replacement for the bootstrap command `npx create-quiver`.
11
+ The root `README.md` is the public landing/onboarding page: keep it concise, Spanish-first, AI-first, and focused on what Quiver is, what problem it solves, the WDD + SDD flow, core commands, and links to deeper guides. Long step-by-step instructions live in `docs/getting-started/`, `docs/workflows/`, and `docs/reference/commands.md`; do not duplicate every procedural detail in the root README.
11
12
  The post-init contract is validated with `npx create-quiver doctor` from the project root. Use `npx create-quiver doctor --fix --dry-run` to preview safe non-destructive repairs, then `npx create-quiver doctor --fix` only after reviewing the plan.
12
13
  If the project already exists from an older Quiver version and was previously initialized by Quiver, run `npx create-quiver migrate` before `analyze` from the project root.
13
14
  If the project was never initialized by Quiver, do not use `migrate` as bootstrap; run `npx create-quiver init --name "Project Name"` first.
@@ -18,20 +19,28 @@ The v24 spec is implemented under `specs/quiver-v24-dx-onboarding-hardening/`; i
18
19
  The v25 spec is implemented under `specs/quiver-v25-ai-first-lifecycle-orchestrator/` and shipped in `create-quiver@0.12.0`; it covers safe AI onboarding docs, strict run state, phase locks, agent adapters, approval gates, spec/slice generation, execution planning, controlled slice execution, worktree/PR lifecycle, validation hardening, export, and migration.
19
20
  The v26 hotfix spec is implemented under `specs/quiver-v26-0121-smoke-hardening/` and shipped in `create-quiver@0.12.1`; it covers smoke hardening for CLI help/version output, generated doc links, AI approval/review guidance, local validation, slice brief validation, demo readiness, scoped plan/graph performance, and release smoke coverage.
20
21
  The v27 spec is implemented under `specs/quiver-v27-reliability-ai-workflow-hardening/` and shipped in `create-quiver@0.13.0`; it captures Pixel Quiver dogfooding findings (`QP-001` to `QP-019`, `QIS-001` to `QIS-022`) and includes shared state resolution, canonical statuses, schema v2 exports, structured spec creation, AI artifact cleanup, worktree locks, validation gates, context diagnostics, cross-platform DX, fixtures, smoke suites, and package/tarball release readiness.
22
+ The v28 spec is implemented under `specs/quiver-v28-pixel-quiver-feedback-reconciliation/` and shipped in `create-quiver@0.14.0`; it captures the Pixel Quiver follow-up reconciliation with active-slice reconciliation, stale `ai inspect` recovery, structured review closure, stricter technical-plan approval, spec/worktree validation hardening, agent-safe commands, GitHub auth/alias guidance, and package-readiness evidence.
23
+ The v29 spec is implemented under `specs/quiver-v29-planner-prepare-context-cli-ux/` and is pending package publication; it adds shared CLI UX primitives, Quiver palette usage, guarded UX flags, planner-assisted `ai prepare-context`, and review/interactive adoption for selected planner/spec/PR commands.
21
24
  Guided AI workflow behavior is available: prepare, approvals, production-readiness plan review, spec worktrees, executor commits, execution waves, PR creation, spec close, and package safety.
22
25
  Generated projects also get `quiver:*` npm scripts that call the Node CLI directly; prefer those for repeatable project workflows, including `quiver:flow` for the read-only guided entrypoint, `quiver:plan` for sequential planning, `quiver:graph` for parallel-level inspection, `quiver:next` for the next ready slice, `quiver:evidence` for local command evidence, `quiver:spec:create` for real spec generation, `quiver:spec:validate` for full spec validation, and the AI family `quiver:ai:agent`, `quiver:ai:inspect`, `quiver:ai:export`, `quiver:ai:specs`, `quiver:ai:slices`, `quiver:ai:trace`, `quiver:ai:onboard`, `quiver:ai:prepare-context`, `quiver:ai:plan`, `quiver:ai:review-plan`, `quiver:ai:approve`, `quiver:ai:prompt-slice`, `quiver:ai:execute-slice`, `quiver:ai:execute-plan`, `quiver:ai:pr`, and `quiver:ai:doctor`. Use `quiver:graph --format mermaid` for PR-ready Markdown or `quiver:graph --format dot` for Graphviz source.
23
26
  `quiver:ai:execute-plan` supports `--mode manual` for paste-ready executor prompts and `--mode delegated` for temporary worktrees on parallel-ready waves; unsafe waves fall back to sequential execution.
24
27
  Agent profiles live in `.quiver/agents/profiles.json`; they store role, provider, model label, context label, and display label only. Do not store API keys, tokens, or credentials there.
25
28
  Planner drafts are versioned under `.quiver/approvals/<phase>/drafts/`; review the technical-plan draft with `npx create-quiver ai review-plan --dry-run` before approving it, then approve a concrete version with `npx create-quiver ai approve --phase <phase> --version <n>` when reviewing iterations.
29
+ `ai review-plan` stores structured closure metadata under `.quiver/approvals/plan-review/meta.json`: `approval_recommendation` is `approve`, `approve-with-risk`, or `revise`; required fixes block technical-plan approval, while optional hardening does not.
26
30
  AI lifecycle runs are persisted under `.quiver/runs/<run-id>/`; use `npx create-quiver ai run create --input <requirements.md>` to start one explicitly, `npx create-quiver ai status` to inspect it, `npx create-quiver ai resume` to continue from the last valid phase without relying on chat memory, and `npx create-quiver ai export --format json|markdown` when another agent, PR, or dashboard needs the current specs/slices/runs state.
31
+ Use `npx create-quiver ai active-slice reconcile --dry-run` when `docs/ai/ACTIVE_SLICE.md`, `ACTIVE_SLICES.md`, worktrees, or `ai inspect` appear out of sync. The command is dry-run-first and reports preserve, close, replace, or blocked decisions without writing files.
32
+ When generating commands for another AI agent, prefer non-interactive package-pinned examples such as `npx --yes create-quiver@<version> ai prompt-slice --slice <slice.json> --dry-run`.
27
33
  Maintain release notes and package publishing with `scripts/release-quiver.sh`.
28
34
  Use `npm run smoke:doctor-fixtures` after changing doctor, preflight, validation, actionable errors, or fixture coverage.
29
35
  The primary generated project context for agents is `docs/AI_CONTEXT.md`.
30
36
  The project map is the single source of truth for stack, package manager, commands, and file hints: `docs/PROJECT_MAP.md`.
31
37
  The raw analyzer output is internal machinery at `.quiver/scans/PROJECT_SCAN.json`; read it only when the visible map is not enough.
32
38
  `npx create-quiver analyze --dry-run` must remain read-only and only preview the scan/project-map/context writes. `npx create-quiver flow` reports the context source/freshness and the package-manager-aware generated script command so agents can see whether the project map is current, stale, partial, legacy, invalid, or missing.
39
+ `npx create-quiver ai prepare-context --dry-run` remains the deterministic default and must not execute provider CLIs. `npx create-quiver ai prepare-context --with-planner --dry-run` previews planner-assisted context preparation. `--with-planner --print-prompt` prints the exact prompt without provider auth; live planner writes should use `--review` and/or `--interactive` when the human wants review before docs-only writes.
33
40
  `npx create-quiver ai agent set <role> --provider <provider> --model "<label>" --dry-run` must preview `.quiver/agents/profiles.json` changes without writing. Use it before saving planner/executor/reviewer/doctor profiles.
34
41
  GitHub PR diagnostics must stay cross-platform: auth failures should point to likely account, scope, and SSH alias issues; path examples with spaces must be copy-safe for macOS/Linux, Windows PowerShell, Git Bash, and WSL.
42
+ CLI UX standard lives in `docs/CLI_UX_GUIDE.md`. Supported Quiver colors are `#86C8F2`, `#6BADEB`, `#7F9EE8`, `#9B82E6`, and `#D56AB0`; output must respect `--no-color`, `NO_COLOR`, CI, and no-TTY environments.
43
+ UX flags are intentionally limited: `ai prepare-context`, `ai plan`, and `spec create` support `--with-planner`, `--interactive`, and `--review`; `ai pr` supports `--interactive` and `--review` but rejects `--with-planner`; read-only commands such as `flow`, `next`, `graph`, `ai inspect`, `ai export`, `ai specs list`, `ai slices list`, and `ai trace report` reject these UX flags. `--json` must reject `--interactive` and `--review` before writing human output.
35
44
  The universal router for generated projects is `AGENTS.md`; read it before `docs/AI_CONTEXT.md` and `docs/AI_ONBOARDING_PROMPT.md`.
36
45
  Generated projects also get `docs/DECISIONS.md`; use it for durable choices that should not be re-litigated.
37
46
  If a generated project has been analyzed, the exact agent handoff prompt is `docs/AI_ONBOARDING_PROMPT.md`.
@@ -137,32 +146,33 @@ Init preserves existing target files and reports skipped copies instead of overw
137
146
  After initialization, the user should:
138
147
 
139
148
  1. Run `npx create-quiver flow` when unsure about the next safe command
140
- 2. Run `npx create-quiver ai prepare-context --dry-run` to preview onboarding docs, diffs, assumptions, risks, contradictions, and omitted paths
141
- 3. After review, run `npx create-quiver ai prepare-context` to write docs-only context updates; Quiver snapshots touched docs under `.quiver/runs/<run-id>/snapshots/` and preserves human-authored content
142
- 4. Run `npx create-quiver analyze --dry-run` when unsure what analysis would update, then run `npx create-quiver analyze` if `docs/PROJECT_MAP.md` or `.quiver/scans/PROJECT_SCAN.json` is missing or stale
143
- 5. If the project already exists from an older Quiver version and was previously initialized by Quiver, run `npx create-quiver migrate`
144
- 6. If the project was never initialized by Quiver, run `npx create-quiver init --name "Project Name"` instead of `migrate`
145
- 7. Ask the AI agent to execute `docs/AI_ONBOARDING_PROMPT.md`
146
- 8. Review context docs before creating the first implementation slice
147
- 9. Open and merge the documentation PR that establishes the workflow files
148
- 10. Preview reusable provider choices with `npx create-quiver ai agent set <role> --provider <provider> --model "<label>" --dry-run`, then save planner/executor/doctor profiles without `--dry-run` after review
149
- 11. Use `npx create-quiver ai plan --phase acceptance --input requirements.md --dry-run`; use `--print-prompt` when you need the exact prompt without provider auth
150
- 12. If the human asks for changes, create a new draft with `npx create-quiver ai revise --phase acceptance --input feedback.md --dry-run`; after human approval, save the selected current draft with `npx create-quiver ai approve --phase acceptance --version <n>`
151
- 13. Use `npx create-quiver ai plan --phase technical-plan --dry-run`
152
- 14. Review the technical plan with `npx create-quiver ai review-plan --dry-run`, inspect exact prompt with `--print-prompt` if needed, then run it without `--dry-run` when ready
153
- 15. After human approval, save the reviewed plan version with `npx create-quiver ai approve --phase technical-plan --version <n>`
154
- 16. Use `npx create-quiver spec create --dry-run` to preview the real spec, slices, handoffs, execution plan, and PR body, then run it without `--dry-run` when ready
155
- 17. Run `npx create-quiver spec start specs/<spec-slug> --dry-run` to inspect the planned worktree, then run without `--dry-run` to create or reuse it
156
- 18. Run `npx create-quiver plan` or `npm run quiver:plan`
157
- 19. Run `npx create-quiver next` or `npm run quiver:next`
158
- 20. Run `npx create-quiver ai execute-plan --dry-run --commit --mode manual` to inspect prompts, or `npx create-quiver ai execute-plan --dry-run --commit --mode delegated` to inspect delegated execution waves
159
- 21. For manual assignment, print a minimal executor prompt with `npx create-quiver ai prompt-slice --slice <slice.json> --dry-run`
160
- 22. Execute one slice with `npx create-quiver ai execute-slice --slice <slice.json> --commit` or execute delegated waves with `npx create-quiver ai execute-plan --execute --commit --mode delegated`; single-slice execution must run from the declared slice branch, validates `allowed_write_paths`/`files`, redacts captured logs, and updates closure, evidence, command log, status, and `slice.json`
161
- 23. Keep one commit per slice
162
- 24. Open one PR per spec with `npx create-quiver ai pr --dry-run --input specs/<spec-slug>/pr.md --ssh-host-alias <alias> ...`, then `--create` only after review; PR creation is blocked while spec slices remain open
163
- 25. After merge, close the worktree with `npx create-quiver spec close specs/<spec-slug>`
164
- 26. Validate the spec with `npx create-quiver spec validate specs/<spec-slug>` or `npm run quiver:spec:validate -- specs/<spec-slug>`
165
- 27. Validate the slice and the final PR with the workflow gates
149
+ 2. Run `npx create-quiver ai prepare-context --dry-run` to preview deterministic onboarding docs, diffs, assumptions, risks, contradictions, and omitted paths without provider execution
150
+ 3. If the user wants planner-generated context, run `npx create-quiver ai prepare-context --with-planner --dry-run`; use `--print-prompt` for external planner execution or `--with-planner --review --interactive` before live docs-only writes
151
+ 4. After review, run `npx create-quiver ai prepare-context` for deterministic writes or `npx create-quiver ai prepare-context --with-planner --review --interactive` for planner-assisted writes; Quiver snapshots touched docs under `.quiver/runs/<run-id>/snapshots/` and preserves human-authored content
152
+ 5. Run `npx create-quiver analyze --dry-run` when unsure what analysis would update, then run `npx create-quiver analyze` if `docs/PROJECT_MAP.md` or `.quiver/scans/PROJECT_SCAN.json` is missing or stale
153
+ 6. If the project already exists from an older Quiver version and was previously initialized by Quiver, run `npx create-quiver migrate`
154
+ 7. If the project was never initialized by Quiver, run `npx create-quiver init --name "Project Name"` instead of `migrate`
155
+ 8. Ask the AI agent to execute `docs/AI_ONBOARDING_PROMPT.md`
156
+ 9. Review context docs before creating the first implementation slice
157
+ 10. Open and merge the documentation PR that establishes the workflow files
158
+ 11. Preview reusable provider choices with `npx create-quiver ai agent set <role> --provider <provider> --model "<label>" --dry-run`, then save planner/executor/doctor profiles without `--dry-run` after review
159
+ 12. Use `npx create-quiver ai plan --phase acceptance --input requirements.md --dry-run`; use `--print-prompt` when you need the exact prompt without provider auth and `--review --interactive` when the human should edit or confirm before saving
160
+ 13. If the human asks for changes, create a new draft with `npx create-quiver ai revise --phase acceptance --input feedback.md --dry-run`; after human approval, save the selected current draft with `npx create-quiver ai approve --phase acceptance --version <n>`
161
+ 14. Use `npx create-quiver ai plan --phase technical-plan --dry-run`
162
+ 15. Review the technical plan with `npx create-quiver ai review-plan --dry-run`, inspect exact prompt with `--print-prompt` if needed, then run it without `--dry-run` when ready
163
+ 16. After human approval, save the reviewed plan version with `npx create-quiver ai approve --phase technical-plan --version <n>`
164
+ 17. Use `npx create-quiver spec create --dry-run` to preview the real spec, slices, handoffs, execution plan, and PR body; use `--review --interactive` when the human should inspect the package before writing
165
+ 18. Run `npx create-quiver spec start specs/<spec-slug> --dry-run` to inspect the planned worktree, then run without `--dry-run` to create or reuse it
166
+ 19. Run `npx create-quiver plan` or `npm run quiver:plan`
167
+ 20. Run `npx create-quiver next` or `npm run quiver:next`
168
+ 21. Run `npx create-quiver ai execute-plan --dry-run --commit --mode manual` to inspect prompts, or `npx create-quiver ai execute-plan --dry-run --commit --mode delegated` to inspect delegated execution waves
169
+ 22. For manual assignment, print a minimal executor prompt with `npx create-quiver ai prompt-slice --slice <slice.json> --dry-run`
170
+ 23. Execute one slice with `npx create-quiver ai execute-slice --slice <slice.json> --commit` or execute delegated waves with `npx create-quiver ai execute-plan --execute --commit --mode delegated`; single-slice execution must run from the declared slice branch, validates `allowed_write_paths`/`files`, redacts captured logs, and updates closure, evidence, command log, status, and `slice.json`
171
+ 24. Keep one commit per slice
172
+ 25. Open one PR per spec with `npx create-quiver ai pr --dry-run --input specs/<spec-slug>/pr.md --ssh-host-alias <alias> ...`, optionally use `--review`, then `--create --interactive` only after review; PR creation is blocked while spec slices remain open
173
+ 26. After merge, close the worktree with `npx create-quiver spec close specs/<spec-slug>`
174
+ 27. Validate the spec with `npx create-quiver spec validate specs/<spec-slug>` or `npm run quiver:spec:validate -- specs/<spec-slug>`
175
+ 28. Validate the slice and the final PR with the workflow gates
166
176
 
167
177
  Bootstrap note: `start-slice` should resolve paths canonically, prefer a local `develop` or `main` base branch before reaching for `origin`, and reject `draft` slices unless `--allow-draft` is passed intentionally.
168
178
  Release note: `scripts/package-quiver.sh` runs package safety against the npm tarball and must fail if local AI state, env files, npm credentials, or worktree state would be published.
package/ROADMAP.md CHANGED
@@ -75,6 +75,15 @@
75
75
  - Published package `0.13.0`.
76
76
  - **v27** — Reliability hardening from Pixel Quiver dogfooding: shared state resolver, canonical statuses, JSON export contract, approved-plan spec generation, AI artifact cleanup, token compaction, worktree lifecycle, validation gates, context diagnostics, cross-platform DX, fixtures, smoke tests, and package/tarball release readiness live in `specs/quiver-v27-reliability-ai-workflow-hardening/`.
77
77
 
78
+ ## v0.14 — Pixel Quiver Feedback Reconciliation (shipped 2026-05-25)
79
+
80
+ - Published package `0.14.0`.
81
+ - **v28** — Follow-up hardening from Pixel Quiver dogfooding: active-slice reconciliation, spec-aware `ai inspect` recovery, structured plan-review closure, safer technical-plan approval, stronger spec/worktree validation, agent-safe command examples, GitHub auth/alias guidance, and final release-readiness evidence live in `specs/quiver-v28-pixel-quiver-feedback-reconciliation/`.
82
+
83
+ ## v0.15 — Planner Context and CLI UX Standard (in progress)
84
+
85
+ - **v29** — Planner-assisted context preparation and CLI UX standard: shared output helpers, Quiver palette, guarded `--with-planner` / `--interactive` / `--review` flags, optional planner-generated `ai prepare-context`, review/interactive adoption for selected commands, docs, tests, and smoke readiness live in `specs/quiver-v29-planner-prepare-context-cli-ux/`.
86
+
78
87
  ## Post-Checkpoint Plan (do not execute before validating v14)
79
88
 
80
89
  > This section now records the follow-up line from the v14-era plan.
@@ -91,6 +100,8 @@
91
100
  - **v25 — AI-First Lifecycle Orchestrator** (shipped in `0.12.0`): safe AI onboarding docs, strict run state, phase locks, agent adapters, approval gates, generated specs/slices/handoffs/PR body, execution waves, controlled slice execution, worktree/PR lifecycle, validation hardening, export, and migration live in `specs/quiver-v25-ai-first-lifecycle-orchestrator/`.
92
101
  - **v26 — 0.12.1 Smoke Hardening** (shipped in `0.12.1`): first-use hardening from clean npm smoke testing, covering CLI help/version output, generated doc links, AI approval/review guidance, local validation, slice brief validation, demo readiness, scoped plan/graph performance, and release smoke coverage live in `specs/quiver-v26-0121-smoke-hardening/`.
93
102
  - **v27 — Reliability and AI Workflow Hardening** (shipped in `0.13.0`): Pixel Quiver dogfooding follow-up covering resolver/export/spec-create/AI-artifact/worktree/validation/context/DX hardening lives in `specs/quiver-v27-reliability-ai-workflow-hardening/`.
103
+ - **v28 — Pixel Quiver Feedback Reconciliation** (shipped in `0.14.0`): active-slice reconciliation, stale inspect recovery, structured review closure, validation/worktree hardening, agent-safe commands, GitHub auth guidance, and release-readiness evidence live in `specs/quiver-v28-pixel-quiver-feedback-reconciliation/`.
104
+ - **v29 — Planner Context and CLI UX Standard** (in progress): planner-assisted `ai prepare-context`, CLI UX primitives, guarded UX flags, human review/interactive flows, and final docs/smoke readiness live in `specs/quiver-v29-planner-prepare-context-cli-ux/`.
94
105
 
95
106
  The shipped v20/v21/v22/v23 work is no longer pending. The older context-diagnostics and slice-archaeology ideas remain deferred until real demand justifies them.
96
107
 
@@ -0,0 +1,22 @@
1
+ <svg width="1120" height="360" viewBox="0 0 1120 360" fill="none" xmlns="http://www.w3.org/2000/svg" role="img" aria-labelledby="title desc">
2
+ <title id="title">Quiver</title>
3
+ <desc id="desc">Pixel style Quiver wordmark for the AI-first WDD and SDD workflow framework.</desc>
4
+ <rect width="1120" height="360" fill="#11151d"/>
5
+ <rect x="34" y="34" width="1052" height="292" fill="#151b25" stroke="#334155" stroke-width="6"/>
6
+ <g transform="translate(448 34)">
7
+ <rect x="0" y="36" width="34" height="34" fill="#7dd3fc"/>
8
+ <rect x="34" y="36" width="34" height="34" fill="#38bdf8"/>
9
+ <rect x="68" y="36" width="34" height="34" fill="#60a5fa"/>
10
+ <rect x="102" y="36" width="34" height="34" fill="#a78bfa"/>
11
+ <rect x="136" y="36" width="34" height="34" fill="#f472b6"/>
12
+ <rect x="34" y="70" width="34" height="34" fill="#0f172a"/>
13
+ <rect x="68" y="70" width="34" height="34" fill="#0f172a"/>
14
+ <rect x="102" y="70" width="34" height="34" fill="#0f172a"/>
15
+ </g>
16
+ <text x="560" y="206" text-anchor="middle" font-family="'Courier New', monospace" font-size="118" font-weight="900" fill="#ffffff" stroke="#020617" stroke-width="16" paint-order="stroke">
17
+ QUIVER
18
+ </text>
19
+ <text x="560" y="276" text-anchor="middle" font-family="'Courier New', monospace" font-size="28" font-weight="700" fill="#93c5fd">
20
+ AI-FIRST WDD + SDD WORKFLOW FRAMEWORK
21
+ </text>
22
+ </svg>
@@ -26,6 +26,7 @@ This file is the main context pack after `AGENTS.md` and `docs/PROJECT_MAP.md`.
26
26
  - `docs/DECISIONS.md` tracks durable choices so agents do not re-litigate them.
27
27
  - `docs/STATUS.md` tracks progress, blockers, and the current slice.
28
28
  - `npx create-quiver ai prepare-context --dry-run` previews docs-only context drafts before writing.
29
+ - `npx create-quiver ai prepare-context --with-planner --dry-run` previews an optional planner-generated context proposal. Use `--print-prompt` to run the prompt elsewhere, `--review` to inspect the proposal, and `--interactive` to confirm before writing.
29
30
 
30
31
  ## Critical Rules
31
32
 
@@ -37,6 +38,7 @@ This file is the main context pack after `AGENTS.md` and `docs/PROJECT_MAP.md`.
37
38
  - Never overwrite user-authored content without checking whether the file is meant to be preserved.
38
39
  - If a command or path is ambiguous, prefer the local project root and the generated docs.
39
40
  - Context preparation must stay in docs/context files and should use TODO, Assumption, or Pending confirmation markers for uncertain statements.
41
+ - Planner-assisted context proposals must remain docs-only. Do not accept product-code, dependency, build, runtime, lockfile, generated-output, absolute-path, or traversal writes.
40
42
 
41
43
  ## What To Update After A Slice
42
44
 
@@ -15,7 +15,8 @@ Actúa como asistente de onboarding de IA para este proyecto. Tu objetivo es com
15
15
  - Lee `docs/INDEX.md`, si existe, y úsalo como mapa para decidir qué abrir después.
16
16
  - Lee `docs/PROJECT_MAP.md` para stack, comandos y estructura. Usa `.quiver/scans/PROJECT_SCAN.json` solo si el mapa visible no alcanza.
17
17
  - Lee `docs/AI_CONTEXT.md`, `docs/AI_ONBOARDING_PROMPT.md`, `docs/WORKFLOW.md`, `docs/STATUS.md` y `docs/DECISIONS.md` solo cuando existan y sean relevantes para la tarea.
18
- - Si usás `npx create-quiver ai prepare-context`, revisá los borradores propuestos antes de escribir y mantené las escrituras limitadas a docs/context.
18
+ - Si usás `npx create-quiver ai prepare-context`, empezá con `--dry-run`, revisá los borradores propuestos antes de escribir y mantené las escrituras limitadas a docs/context.
19
+ - Usá `--with-planner` solo cuando el humano quiera una propuesta generada por un planner IA; combiná `--review` y `--interactive` antes de aplicar escrituras.
19
20
  - Lee specs, slices o handoffs solo si la tarea actual lo requiere.
20
21
  - No leas todo `docs/` por defecto.
21
22
  - Si un documento referenciado no existe, repórtalo como deuda documental.
@@ -73,6 +74,9 @@ Si usás los comandos de IA de Quiver, empezá con `--dry-run` para revisar prov
73
74
  ```bash
74
75
  npm run quiver:prepare -- --dry-run
75
76
  npm run quiver:ai:prepare-context -- --dry-run
77
+ npm run quiver:ai:prepare-context -- --with-planner --dry-run
78
+ npm run quiver:ai:prepare-context -- --with-planner --print-prompt
79
+ npm run quiver:ai:prepare-context -- --with-planner --review --interactive
76
80
  npm run quiver:ai:onboard -- --dry-run
77
81
  npm run quiver:ai:inspect
78
82
  npm run quiver:ai:export -- --format json
@@ -80,18 +84,21 @@ npm run quiver:ai:specs
80
84
  npm run quiver:ai:slices
81
85
  npm run quiver:ai:trace
82
86
  npm run quiver:ai:plan -- --phase acceptance --input requirements.md --dry-run
87
+ npm run quiver:ai:plan -- --phase acceptance --input requirements.md --review --interactive
83
88
  npm run quiver:ai:revise -- --phase acceptance --input feedback.md --dry-run
84
89
  npm run quiver:ai:approve -- --phase acceptance --version <n>
85
90
  npm run quiver:ai:plan -- --phase technical-plan --dry-run
86
91
  npm run quiver:ai:review-plan -- --dry-run
87
92
  npm run quiver:ai:approve -- --phase technical-plan --version <n>
88
93
  npm run quiver:spec:create -- --dry-run
94
+ npm run quiver:spec:create -- --review --interactive
89
95
  npm run quiver:spec:start -- specs/{{PROJECT_SLUG}}
90
96
  npm run quiver:ai:prompt-slice -- --slice specs/{{PROJECT_SLUG}}/slices/<slice-id>/slice.json --dry-run
91
97
  npm run quiver:ai:execute-slice -- --slice specs/{{PROJECT_SLUG}}/slices/<slice-id>/slice.json --dry-run --commit
92
98
  npm run quiver:ai:execute-plan -- --dry-run --commit --mode manual
93
99
  npm run quiver:ai:execute-plan -- --dry-run --commit --mode delegated
94
100
  npm run quiver:ai:pr -- --dry-run --input specs/{{PROJECT_SLUG}}/pr.md --ssh-host-alias github-work --identity-file ~/.ssh/github-work
101
+ npm run quiver:ai:pr -- --review --dry-run --input specs/{{PROJECT_SLUG}}/pr.md --ssh-host-alias github-work --identity-file ~/.ssh/github-work
95
102
  npm run quiver:spec:close -- specs/{{PROJECT_SLUG}} --dry-run
96
103
  ```
97
104
 
@@ -113,6 +120,7 @@ npm run quiver:spec:close -- specs/{{PROJECT_SLUG}} --dry-run
113
120
  - Indica rutas omitidas o señales faltantes.
114
121
  - Mantén la respuesta enfocada en documentación y contexto de onboarding salvo que el usuario haya autorizado cambios de código de producto.
115
122
  - No cambies reglas del workflow de Quiver salvo que el usuario lo pida explícitamente.
123
+ - No combines `--json` con `--interactive` ni `--review`. Si necesitás salida machine-readable, evitá prompts, editores y loaders humanos.
116
124
 
117
125
  ## Reporte final
118
126
 
@@ -0,0 +1,125 @@
1
+ # Guia de UX del CLI de Quiver
2
+
3
+ Este documento define el estandar de experiencia para los comandos de Quiver. La meta es que el CLI sea claro para humanos, seguro para automatizacion y consistente para agentes de IA.
4
+
5
+ ## Principios
6
+
7
+ - Los comandos deben explicar que modo estan usando: deterministico, planner-assisted, dry-run, review, interactive, JSON o CI.
8
+ - `--dry-run` debe ser el primer paso recomendado antes de escrituras, proveedores externos, worktrees, PRs o reparaciones.
9
+ - La salida humana puede usar jerarquia visual, loaders y color; la salida JSON debe permanecer limpia y parseable.
10
+ - Los prompts interactivos son opt-in. Ningun comando debe bloquear automatizaciones si `--interactive` no fue pedido.
11
+ - Las revisiones humanas ocurren antes de escrituras persistentes siempre que el comando soporte `--review`.
12
+ - Las credenciales viven en los CLIs de proveedor, `gh`, Git o el sistema operativo. Quiver no debe guardarlas.
13
+
14
+ ## Colores de Quiver
15
+
16
+ Usar esta paleta en loaders, estados, etiquetas y enfasis visual:
17
+
18
+ | Token | Hex | Uso sugerido |
19
+ |---|---:|---|
20
+ | `sky` | `#86C8F2` | informacion, rutas, contexto |
21
+ | `blue` | `#6BADEB` | acciones primarias, progreso |
22
+ | `periwinkle` | `#7F9EE8` | modo planner, prompts |
23
+ | `violet` | `#9B82E6` | revision, decisiones humanas |
24
+ | `magenta` | `#D56AB0` | advertencias suaves, approval gates |
25
+
26
+ Reglas:
27
+
28
+ - Respetar `--no-color`, `NO_COLOR`, CI y terminales sin TTY.
29
+ - No depender solo del color para comunicar estado.
30
+ - Mantener fallback ASCII cuando Unicode no sea seguro.
31
+
32
+ ## Banderas UX
33
+
34
+ | Flag | Definicion | Regla |
35
+ |---|---|---|
36
+ | `--with-planner` | Activa comportamiento asistido por planner cuando el comando lo soporta. | No debe ser decorativo. Si no cambia el comportamiento o contrato del comando, debe rechazarse. |
37
+ | `--interactive` | Habilita prompts humanos de confirmacion o eleccion. | Nunca se activa por defecto. Debe tener alternativa no interactiva. |
38
+ | `--review` | Abre o prepara revision humana antes de escrituras persistentes. | Debe usar `$VISUAL`, `$EDITOR` o dejar un artefacto revisable cuando no haya TTY. |
39
+ | `--dry-run` | Previsualiza sin escribir ni ejecutar acciones irreversibles. | Debe ser seguro y no requerir credenciales salvo que el comando lo documente. |
40
+ | `--print-prompt` | Imprime el prompt exacto sin ejecutar proveedor. | Debe evitar auth/provider execution. |
41
+ | `--json` | Emite salida machine-readable. | Incompatible con `--interactive` y `--review`. |
42
+ | `--no-color` | Desactiva color ANSI. | Debe respetarse en toda salida humana. |
43
+
44
+ ## Matriz de soporte
45
+
46
+ | Comando | `--with-planner` | `--interactive` | `--review` | Notas |
47
+ |---|---:|---:|---:|---|
48
+ | `ai prepare-context` | si | si | si | Modo deterministico por defecto; planner opcional con contrato docs-only. |
49
+ | `ai plan` | si | si | si | El planner ya es implicito; `--with-planner` se acepta por consistencia. |
50
+ | `spec create` | si | si | si | Consume un plan tecnico aprobado del planner; no vuelve a ejecutar proveedor. Review previsualiza el paquete antes de escribir. |
51
+ | `ai pr` | no | si | si | Review edita `pr.md`; interactive confirma `gh pr create`. |
52
+ | `flow`, `next`, `graph` | no | no | no | Lectura/inspeccion; no deben exponer flags decorativas. |
53
+ | `ai inspect`, `ai export`, `ai specs list`, `ai slices list`, `ai trace report` | no | no | no | Superficies read-only o machine-readable. |
54
+
55
+ ## Flujo recomendado para contexto de IA
56
+
57
+ Modo deterministico:
58
+
59
+ ```bash
60
+ npx create-quiver ai prepare-context --dry-run
61
+ npx create-quiver ai prepare-context
62
+ ```
63
+
64
+ Modo asistido por planner:
65
+
66
+ ```bash
67
+ npx create-quiver ai prepare-context --with-planner --dry-run
68
+ npx create-quiver ai prepare-context --with-planner --print-prompt
69
+ npx create-quiver ai prepare-context --with-planner --review --interactive
70
+ ```
71
+
72
+ El planner debe devolver una propuesta validable. Quiver solo acepta cambios en documentación/contexto permitida y rechaza rutas de producto, dependencias, build, runtime, lockfiles, salidas generadas, rutas absolutas y traversal.
73
+
74
+ ## Loaders y prompts
75
+
76
+ Usar loaders solo cuando aportan claridad:
77
+
78
+ ```text
79
+ Analizando estructura del proyecto...
80
+ Leyendo contexto base...
81
+ Preparando prompt para planner...
82
+ Ejecutando agente...
83
+ ```
84
+
85
+ Usar prompts interactivos cuando hay una decision humana real:
86
+
87
+ ```text
88
+ ? Aplicar 3 actualizaciones docs-only de contexto?
89
+ ? Crear spec "quiver-demo"?
90
+ ? Crear PR "Implementar dashboard"?
91
+ ```
92
+
93
+ No usar prompts para informacion que ya se pueda expresar con flags.
94
+
95
+ ## Revision con editor
96
+
97
+ Los comandos con `--review` deben:
98
+
99
+ 1. Crear o abrir un artefacto revisable.
100
+ 2. Respetar `$VISUAL` antes que `$EDITOR`.
101
+ 3. No usar shell interpolation para abrir editores.
102
+ 4. Bloquear escrituras si la revision se cancela.
103
+ 5. Revalidar la propuesta editada cuando el contenido tiene contrato estructurado.
104
+ 6. Reportar la ruta del artefacto si no se puede abrir un editor.
105
+
106
+ ## Testing minimo
107
+
108
+ Cada comando que adopte estas reglas debe cubrir:
109
+
110
+ - modo `--dry-run`;
111
+ - salida sin TTY/CI;
112
+ - `--json` limpio o rechazo temprano si corresponde;
113
+ - `--interactive` aceptado y cancelado;
114
+ - `--review` aceptado, cancelado y editado;
115
+ - `--no-color`;
116
+ - rechazo de flags no soportadas con mensaje accionable.
117
+
118
+ ## Checklist para nuevos comandos
119
+
120
+ - [ ] El comando define si es lectura, escritura, proveedor, worktree, PR o validacion.
121
+ - [ ] `--dry-run` existe si hay escrituras o efectos externos.
122
+ - [ ] `--with-planner`, `--interactive` y `--review` solo se aceptan si agregan valor real.
123
+ - [ ] La salida JSON no se mezcla con prompts, colores, loaders ni texto humano.
124
+ - [ ] Los mensajes de error incluyen proximo paso seguro.
125
+ - [ ] La documentacion publica y `README_FOR_AI.md` quedan sincronizados.
@@ -30,6 +30,7 @@ This document is the canonical command reference for the orchestration roadmap.
30
30
  | `npx create-quiver ai inspect` | Shows actionable lifecycle state for specs, slices, runs, agents, layout, and next commands | macOS, Linux, Windows | v0.13 | `npx create-quiver ai inspect` |
31
31
  | `npx create-quiver ai export --format json` | Emits machine-readable specs, slices, runs, agents, dependencies, blockers, and migration state | macOS, Linux, Windows | v0.13 | `npx create-quiver ai export --format json` |
32
32
  | `npx create-quiver ai export --format markdown` | Emits readable Markdown lifecycle state for PRs or docs | macOS, Linux, Windows | v0.13 | `npx create-quiver ai export --format markdown` |
33
+ | `npx create-quiver ai active-slice reconcile --dry-run` | Reports active-slice state from supported local sources and previews preserve, close, replace, or blocked reconciliation decisions without writing files | macOS, Linux, Windows | next | `npx create-quiver ai active-slice reconcile --dry-run` |
33
34
  | `npx create-quiver ai specs list` | Lists specs with state, progress, slice counts, and paths | macOS, Linux, Windows | v0.13 | `npx create-quiver ai specs list` |
34
35
  | `npx create-quiver ai slices list` | Lists slices with state, progress, dependencies, and blockers | macOS, Linux, Windows | v0.13 | `npx create-quiver ai slices list --json` |
35
36
  | `npx create-quiver ai trace report` | Reports AI runs, execution waves, and migration guidance | macOS, Linux, Windows | v0.13 | `npx create-quiver ai trace report` |
@@ -50,7 +51,11 @@ This document is the canonical command reference for the orchestration roadmap.
50
51
  | `quiver:ai:trace` | Prints a trace report through the generated npm script | macOS, Linux, Windows | v0.13 | `npm run quiver:ai:trace` |
51
52
  | `quiver:ai:onboard` | Runs AI onboarding prompt through a supported local provider CLI | macOS, Linux, Windows | v0.10 | `npm run quiver:ai:onboard -- --dry-run` |
52
53
  | `quiver:ai:prepare-context` | Prepares docs-only AI context drafts with diff preview, assumptions, risks, contradictions, and snapshots before writes | macOS, Linux, Windows | v0.11 | `npm run quiver:ai:prepare-context -- --dry-run` |
54
+ | `quiver:ai:prepare-context -- --with-planner --dry-run` | Previews a planner-generated docs-only context proposal without writing files | macOS, Linux, Windows | next | `npm run quiver:ai:prepare-context -- --with-planner --dry-run` |
55
+ | `quiver:ai:prepare-context -- --with-planner --print-prompt` | Prints the exact planner context prompt without running provider CLIs | macOS, Linux, Windows | next | `npm run quiver:ai:prepare-context -- --with-planner --print-prompt` |
56
+ | `quiver:ai:prepare-context -- --with-planner --review --interactive` | Runs planner-assisted context preparation, opens review, and asks before docs-only writes | macOS, Linux, Windows | next | `npm run quiver:ai:prepare-context -- --with-planner --review --interactive` |
53
57
  | `quiver:ai:plan` | Runs phase-gated AI planning for acceptance criteria, technical plan, or spec generation | macOS, Linux, Windows | v0.10 | `npm run quiver:ai:plan -- --phase acceptance --input requirements.md --dry-run` |
58
+ | `quiver:ai:plan -- --review --interactive` | Lets a human edit and confirm planner drafts before saving them | macOS, Linux, Windows | next | `npm run quiver:ai:plan -- --phase acceptance --input requirements.md --review --interactive` |
54
59
  | `quiver:ai:revise` | Creates a new draft version from human feedback without approving or advancing the planner phase | macOS, Linux, Windows | v0.13 | `npm run quiver:ai:revise -- --phase acceptance --input feedback.md --dry-run` |
55
60
  | `quiver:ai:review-plan` | Reviews the technical-plan draft for production readiness before approval and spec generation | macOS, Linux, Windows | v0.11 | `npm run quiver:ai:review-plan -- --dry-run` |
56
61
  | `quiver:ai:approve` | Approves a concrete saved draft version for the next planner phase | macOS, Linux, Windows | v0.10 | `npm run quiver:ai:approve -- --phase acceptance --version 1` |
@@ -59,7 +64,9 @@ This document is the canonical command reference for the orchestration roadmap.
59
64
  | `quiver:ai:execute-plan` | Prints or executes dependency-safe waves of slices, with manual prompts or delegated worktrees | macOS, Linux, Windows | v0.10 | `npm run quiver:ai:execute-plan -- --dry-run --commit --mode delegated` |
60
65
  | `quiver:ai:doctor` | Runs GitHub PR preflight checks without opening a PR | macOS, Linux, Windows | v0.10 | `npm run quiver:ai:doctor -- --dry-run --ssh-host-alias github-work --identity-file ~/.ssh/github-work` |
61
66
  | `quiver:ai:pr` | Validates `gh`, reads `pr.md`, prints a PR plan, and creates a PR only with `--create` | macOS, Linux, Windows | v0.10 | `npm run quiver:ai:pr -- --dry-run --input specs/<spec>/pr.md --ssh-host-alias github-work --identity-file ~/.ssh/github-work` |
67
+ | `quiver:ai:pr -- --review` | Opens `pr.md` for human review and rebuilds the PR plan from the edited body | macOS, Linux, Windows | next | `npm run quiver:ai:pr -- --review --dry-run --input specs/<spec>/pr.md` |
62
68
  | `quiver:spec:create` | Creates the real spec tree from the reviewed approved technical plan | macOS, Linux, Windows | v0.11 | `npm run quiver:spec:create -- --dry-run` |
69
+ | `quiver:spec:create -- --review --interactive` | Reviews the generated spec package preview and asks before writing files | macOS, Linux, Windows | next | `npm run quiver:spec:create -- --review --interactive` |
63
70
  | `quiver:spec:start` | Creates or reuses the dedicated worktree for one spec | macOS, Linux, Windows | v0.10 | `npm run quiver:spec:start -- specs/<spec>` |
64
71
  | `quiver:spec:status` | Shows spec worktree, branch, `slice-00`, and pending slices | macOS, Linux, Windows | v0.10 | `npm run quiver:spec:status -- specs/<spec>` |
65
72
  | `quiver:spec:validate` | Validates spec docs, slices, briefs, evidence, status, dependencies, and safe paths | macOS, Linux, Windows | v0.13 | `npm run quiver:spec:validate -- specs/<spec>` |
@@ -90,8 +97,12 @@ This document is the canonical command reference for the orchestration roadmap.
90
97
  | `--provider <codex\|claude\|gemini>` | `ai onboard`, `ai plan`, `ai revise`, `ai review-plan`, `ai execute-slice`, `ai execute-plan` | Select the local AI CLI adapter |
91
98
  | `--model <label>` | `ai agent set` | Store a free-form model label in an agent profile; Quiver does not verify model availability |
92
99
  | `--label <label>` | `ai agent set` | Store a display label for the profile |
93
- | `--dry-run` | `ai agent set` | Preview profile writes without creating or updating `.quiver/agents/profiles.json` |
94
- | `--print-prompt` | `ai onboard`, `ai plan`, `ai revise`, `ai review-plan` | Print the exact provider prompt and exit without executing provider CLIs or requiring provider auth |
100
+ | `--dry-run` | init, analyze, migrate, prepare, spec, demo, AI, PR, worktree, and repair commands that support preview | Preview planned actions without writes, provider execution, PR creation, or irreversible changes |
101
+ | `--with-planner` | `ai prepare-context`, `ai plan`, `spec create` | Enable planner-assisted behavior only on commands that explicitly support it |
102
+ | `--interactive` | `ai prepare-context`, `ai plan`, `spec create`, `ai pr` | Enable human prompts for confirmation or choices |
103
+ | `--review` | `ai prepare-context`, `ai plan`, `spec create`, `ai pr` | Open or prepare human review before persistent writes |
104
+ | `--no-color` | all human-output commands | Disable ANSI color in human output |
105
+ | `--print-prompt` | `ai onboard`, `ai prepare-context`, `ai plan`, `ai revise`, `ai review-plan` | Print the exact provider prompt and exit without executing provider CLIs or requiring provider auth |
95
106
  | `--role <planner\|executor\|reviewer\|doctor>` | `ai onboard`, `ai plan`, `ai revise`, `ai execute-slice`, `ai execute-plan` | Select an AI role; execution requires executor |
96
107
  | `--context <full\|planning\|slice\|minimal>` | `ai onboard`, `ai plan`, `ai revise`, `ai review-plan`, `ai execute-slice`, `ai execute-plan` | Select a token-budgeted context pack |
97
108
  | `--phase <acceptance\|technical-plan\|spec>` | `ai plan`, `ai revise`, `ai approve` | Select the gated planner phase; `ai revise` and `ai approve` do not support `spec` |
@@ -118,14 +129,18 @@ This document is the canonical command reference for the orchestration roadmap.
118
129
  - `check-slice` validates `depends_on` targets and requires `parallel_safe_reason` when `parallel_safe` is `never`.
119
130
  - `check-handoff` validates both exceptional `HANDOFF.md` transfers and current slice-local `EXECUTION_BRIEF.md` / `CLOSURE_BRIEF.md` contracts.
120
131
  - `quiver:ai:onboard`, `quiver:ai:plan`, `quiver:ai:revise`, `quiver:ai:review-plan`, and `quiver:ai:execute-slice` support `codex`, `claude`, and `gemini` through local CLIs. Use `--dry-run` first to inspect the invocation without requiring provider auth, or `--print-prompt` to print the exact planner/reviewer prompt without executing a provider.
121
- - `quiver:ai:prepare-context -- --dry-run` previews docs-only context drafts, diff snippets, assumptions, risks, contradictions, and omitted paths. Write mode stores snapshots under `.quiver/runs/<run-id>/snapshots/` and preserves human-authored content by appending or refreshing a Quiver-managed block.
132
+ - `quiver:ai:prepare-context -- --dry-run` previews deterministic docs-only context drafts, diff snippets, assumptions, risks, contradictions, and omitted paths. Write mode stores snapshots under `.quiver/runs/<run-id>/snapshots/` and preserves human-authored content by appending or refreshing a Quiver-managed block.
133
+ - `quiver:ai:prepare-context -- --with-planner` invokes a planner provider and only accepts a validated docs-only proposal. Use `--print-prompt` for external planners, `--review` to inspect the proposal before writing, and `--interactive` to require confirmation.
134
+ - UX flags are centralized: `--with-planner`, `--interactive`, and `--review` are accepted only by commands where they add real behavior. Read-only inspection commands reject them with an actionable next step. `spec create --with-planner` consumes an already approved planner output and does not call a provider again. `--json` is incompatible with `--interactive` and `--review`.
135
+ - Quiver human output uses the palette `#86C8F2`, `#6BADEB`, `#7F9EE8`, `#9B82E6`, and `#D56AB0`; respect `--no-color`, `NO_COLOR`, CI, and no-TTY environments.
122
136
  - `quiver:flow` reports the detected package manager and the matching generated project script, for example `npm run quiver:flow`, `pnpm run quiver:flow`, `yarn run quiver:flow`, or `bun run quiver:flow`.
123
137
  - `quiver:ai:agent -- set ... --dry-run` previews provider/model profile changes without writing `.quiver/agents/profiles.json`.
124
138
  - `quiver:ai:agent` stores provider/model labels under `.quiver/agents/profiles.json`; credentials stay in the provider CLI or OS credential store.
125
139
  - `quiver:ai:inspect`, `quiver:ai:specs`, `quiver:ai:slices`, and `quiver:ai:trace` are read-only inspection surfaces for humans and agents.
126
140
  - `quiver:ai:export -- --format json` is the dashboard/agent-friendly state contract; `--format markdown` is the PR/docs-friendly version.
127
- - Planner drafts are versioned under `.quiver/approvals/<phase>/drafts/`; use `quiver:ai:review-plan -- --dry-run` before approving a technical-plan draft, then `quiver:ai:approve -- --phase technical-plan --version 1` to approve the reviewed version.
141
+ - Planner drafts are versioned under `.quiver/approvals/<phase>/drafts/`; use `quiver:ai:review-plan -- --dry-run` before approving a technical-plan draft, then `quiver:ai:approve -- --phase technical-plan --version 1` to approve the reviewed version. Plan reviews store structured recommendations: `approve`, `approve-with-risk`, or `revise`.
128
142
  - `quiver:ai:prompt-slice -- --dry-run` prints a paste-ready manual executor prompt and does not call a provider.
143
+ - For commands pasted into another AI agent, prefer a non-interactive pinned form such as `npx --yes create-quiver@<version> ai prompt-slice --slice specs/<spec>/slices/<slice>/slice.json --dry-run`.
129
144
  - `quiver:evidence -- run -- <command>` preserves the wrapped command exit code. Redaction is best effort; avoid commands that intentionally print secrets.
130
145
  - `demo create spec-viewer` is optional and static; it must stay outside default `init`.
131
146
  - `quiver:spec:start -- --dry-run specs/<spec>` previews the spec worktree path and branch without creating a worktree.
@@ -0,0 +1,70 @@
1
+ # Git and PR Guide
2
+
3
+ **Version:** 2.0
4
+ **Last updated:** 2026-05-26
5
+
6
+ ## Purpose
7
+
8
+ This guide explains how to open and review spec PRs without breaking the canonical workflow.
9
+
10
+ ## Core Rule
11
+
12
+ - One slice = one commit
13
+ - One spec = one PR
14
+ - One spec should be worked from one dedicated worktree/branch.
15
+ - Slice numbers reset per spec. `slice-01` is the first slice in each spec.
16
+ - Do not commit directly to `develop`
17
+ - Open and merge the documentation PR before the first slice starts execution
18
+ - Do not open the spec PR before the documentation PR is merged
19
+
20
+ ## AI PR Preflight
21
+
22
+ Before asking an AI agent to prepare PR work, validate the local setup:
23
+
24
+ ```bash
25
+ npm run quiver:ai:pr -- --dry-run --ssh-host-alias github-work --identity-file ~/.ssh/github-work
26
+ ```
27
+
28
+ Use the SSH host alias from your Git remote separately from the key path. Quiver validates `gh`, `gh auth status`, the remote, branch/worktree state, this guide, and the identity file. It does not install `gh`, edit SSH config, or create a PR in dry-run mode.
29
+
30
+ ## Review Guidance
31
+
32
+ - Start with `git diff` and the slice scope before opening full files.
33
+ - Use the diff to confirm what changed, then open full files only for gaps, regressions, or unclear context.
34
+ - For debugging reviews, inspect the first relevant error, stacktrace, or failing command before reading large logs.
35
+ - Keep review notes anchored to the changed lines and the slice acceptance criteria.
36
+
37
+ ## Required PR Headings
38
+
39
+ All spec PR notes must use:
40
+
41
+ - `## Title`
42
+ - `## Summary`
43
+ - `## Scope`
44
+ - `## Files`
45
+ - `## How to Test (DETAILED - REQUIRED)`
46
+ - `## Evidence`
47
+ - `## Rollback`
48
+ - `## Risks / Notes`
49
+
50
+ Inside `How to Test`, use:
51
+
52
+ - `### Required Environment`
53
+ - `### Worktree Access`
54
+ - `### Run the Project`
55
+ - `### Use Cases`
56
+ - `### Technical Verification`
57
+
58
+ ## Branch Strategy
59
+
60
+ | Type | Prefix | Source | Target |
61
+ |------|--------|--------|--------|
62
+ | feature | `feature/` | `develop` | `develop` |
63
+ | bugfix | `bugfix/` | `develop` | `develop` |
64
+ | hotfix | `hotfix/` | `main` | `main` |
65
+
66
+ ## Anti-Patterns
67
+
68
+ - Pushing directly to `develop`
69
+ - Reusing the same branch for multiple specs
70
+ - Writing PR bodies outside `pr.md`
@@ -147,6 +147,35 @@ Use this guide when a first-run bootstrap or gate check fails. The recovery path
147
147
  3. Use `--provider codex`, `--provider claude`, or `--provider gemini` explicitly if your default is unclear.
148
148
  4. Re-run the command from a clean worktree when using `ai execute-slice`.
149
149
 
150
+ ## Plan Review Blocks Approval
151
+
152
+ ### Symptom
153
+
154
+ - `ai approve --phase technical-plan` says the plan review blocks approval
155
+ - `ai approvals` shows `Approval recommendation: revise`
156
+
157
+ ### Recovery
158
+
159
+ 1. Read `.quiver/approvals/plan-review/review.md` and the `required_fixes` in `.quiver/approvals/plan-review/meta.json`.
160
+ 2. Create a revised technical-plan draft with `npx create-quiver ai revise --phase technical-plan --input <feedback.md> --dry-run`.
161
+ 3. Run `npx create-quiver ai review-plan --dry-run`, then `npx create-quiver ai review-plan` after inspecting the prompt.
162
+ 4. Approve only when the review recommendation is `approve` or `approve-with-risk`.
163
+
164
+ ## Active Slice State Conflict
165
+
166
+ ### Symptom
167
+
168
+ - `ai inspect` reports an active-slice blocker
169
+ - `docs/ai/ACTIVE_SLICE.md` and `ACTIVE_SLICES.md` point to different slices
170
+ - The current active slice was already completed but local active-state files still exist
171
+
172
+ ### Recovery
173
+
174
+ 1. Run `npx create-quiver ai active-slice reconcile --dry-run`.
175
+ 2. If the decision is `preserve`, continue with the suggested next command.
176
+ 3. If the decision is `close` or `replace`, review the planned file changes before changing local active-state files.
177
+ 4. If the decision is `blocked`, fix the missing, ambiguous, or conflicting slice reference before assigning more executor work.
178
+
150
179
  ## GitHub PR Preflight Failure
151
180
 
152
181
  ### Symptom
@@ -37,8 +37,8 @@ Use maps, metadata, diffs, and summaries first. Open full files only when the sm
37
37
  3. Save reusable planner/executor provider choices with `ai agent set` when the team has preferred local AI CLIs.
38
38
  4. Use `ai plan --phase acceptance` to draft criteria, then save the approved version with `ai approve --phase acceptance`.
39
39
  5. Use `ai plan --phase technical-plan` to draft the plan.
40
- 6. Use `ai review-plan` to review the technical-plan draft for production readiness without changing product code.
41
- 7. Save the reviewed plan version with `ai approve --phase technical-plan --version <n>`.
40
+ 6. Use `ai review-plan` to review the technical-plan draft for production readiness without changing product code. Treat `approve` and `approve-with-risk` as approvable states; treat `revise` or required fixes as blockers.
41
+ 7. Save the reviewed plan version with `ai approve --phase technical-plan --version <n>` only after the review recommendation is approvable.
42
42
  8. Use `spec create` to generate the spec, mandatory `slice-00`, implementation slices, handoffs, execution plan, and `pr.md`.
43
43
  9. Open and merge the documentation PR or commit that establishes `slice-00` before running implementation slices.
44
44
  10. Read the AI context pack, support matrix, and troubleshooting guide before the first slice if the environment is new or uncertain.
@@ -50,21 +50,22 @@ Use maps, metadata, diffs, and summaries first. Open full files only when the sm
50
50
 
51
51
  1. Create or reuse the spec worktree with `npx create-quiver spec start specs/<spec-slug>` or `npm run quiver:spec:start -- specs/<spec-slug>`. Use `--dry-run` first when you want to inspect the planned branch/path without changing Git state.
52
52
  2. Inspect lifecycle state with `npx create-quiver ai inspect`, or export it with `npx create-quiver ai export --format json` for dashboards/agents and `--format markdown` for PRs/docs.
53
- 3. Inspect manual prompts with `npx create-quiver ai execute-plan --dry-run --commit --mode manual` or delegated waves with `npm run quiver:ai:execute-plan -- --dry-run --commit --mode delegated`.
54
- 4. Print a minimal manual executor prompt with `npx create-quiver ai prompt-slice --slice <slice.json> --dry-run` when assigning the slice to another agent.
55
- 5. Bootstrap a single slice with `npx create-quiver start-slice <slice.json>` or `npm run quiver:start-slice -- <slice.json>` when manual execution is preferred.
53
+ 3. If active-slice state looks stale or conflicting, run `npx create-quiver ai active-slice reconcile --dry-run` before assigning more execution work.
54
+ 4. Inspect manual prompts with `npx create-quiver ai execute-plan --dry-run --commit --mode manual` or delegated waves with `npm run quiver:ai:execute-plan -- --dry-run --commit --mode delegated`.
55
+ 5. Print a minimal manual executor prompt with `npx create-quiver ai prompt-slice --slice <slice.json> --dry-run` when assigning the slice to another agent. For commands pasted into another AI agent, prefer `npx --yes create-quiver@<version> ai prompt-slice --slice <slice.json> --dry-run`.
56
+ 6. Bootstrap a single slice with `npx create-quiver start-slice <slice.json>` or `npm run quiver:start-slice -- <slice.json>` when manual execution is preferred.
56
57
  - The bootstrap step should work with canonical paths and a local base branch when `origin` is absent.
57
58
  - Draft slices require `--allow-draft`; otherwise `npx create-quiver start-slice` exits before execution.
58
59
  - Legacy Bash wrappers remain available for compatibility, but generated projects should prefer the Node CLI and `quiver:*` npm scripts.
59
60
  - `start-slice` generates `docs/ai/ACTIVE_SLICE.md` and `WORKTREE_CONTEXT.md`; use the active slice brief as the source of truth for execution.
60
- 6. Implement only what the slice declares.
61
- 7. Make one commit for that slice, or let `ai execute-slice --commit` / `ai execute-plan --execute --commit --mode delegated` create it after provider, branch/worktree, scope, and validation pass.
61
+ 7. Implement only what the slice declares.
62
+ 8. Make one commit for that slice, or let `ai execute-slice --commit` / `ai execute-plan --execute --commit --mode delegated` create it after provider, branch/worktree, scope, and validation pass.
62
63
  - `ai execute-slice` updates `CLOSURE_BRIEF.md`, `EVIDENCE_REPORT.md`, `COMMAND_LOG.md`, `STATUS.md`, and `slice.json` only after the provider changes in-scope files and validation passes.
63
- 8. Validate with `npx create-quiver check-slice <slice.json>` or `npm run quiver:check-slice -- <slice.json>`.
64
- 9. Write evidence. Prefer `npx create-quiver evidence run -- <command>` when you need a compact local Markdown record of validation output.
65
- 10. Repeat for the next slice until the spec is complete.
66
- 11. Open one PR for the spec. Use `npx create-quiver ai pr --dry-run --input specs/<spec-slug>/pr.md --ssh-host-alias <alias> ...` first, then add `--create` only after review. Quiver blocks PR creation while slices in that spec remain open.
67
- 12. After the PR is merged and the spec worktree is clean, close it with `npx create-quiver spec close specs/<spec-slug>`.
64
+ 9. Validate with `npx create-quiver check-slice <slice.json>` or `npm run quiver:check-slice -- <slice.json>`.
65
+ 10. Write evidence. Prefer `npx create-quiver evidence run -- <command>` when you need a compact local Markdown record of validation output.
66
+ 11. Repeat for the next slice until the spec is complete.
67
+ 12. Open one PR for the spec. Use `npx create-quiver ai pr --dry-run --input specs/<spec-slug>/pr.md --ssh-host-alias <alias> ...` first, then add `--create` only after review. Quiver blocks PR creation while slices in that spec remain open.
68
+ 13. After the PR is merged and the spec worktree is clean, close it with `npx create-quiver spec close specs/<spec-slug>`.
68
69
 
69
70
  ## Support Contract
70
71