create-quiver 0.9.1 → 0.12.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 (245) hide show
  1. package/BACKLOG.md +16 -17
  2. package/CHANGELOG.md +34 -0
  3. package/README.md +419 -330
  4. package/README_FOR_AI.md +93 -56
  5. package/ROADMAP.md +22 -11
  6. package/docs/AI_CONTEXT.md.template +2 -0
  7. package/docs/AI_ONBOARDING_PROMPT.md.template +36 -19
  8. package/docs/COMMANDS.md.template +73 -1
  9. package/docs/CONTEXTO.md.template +2 -0
  10. package/docs/DECISIONS.md.template +1 -0
  11. package/docs/GITFLOW_PR_GUIDE.md.template +11 -0
  12. package/docs/INDEX.md.template +20 -18
  13. package/docs/STANDARD.md.template +1 -1
  14. package/docs/STATUS.md.template +1 -0
  15. package/docs/SUPPORT_MATRIX.md.template +6 -2
  16. package/docs/TROUBLESHOOTING.md.template +79 -1
  17. package/docs/WORKFLOW.md.template +26 -18
  18. package/package.json +24 -2
  19. package/package.template.json +24 -7
  20. package/scripts/check-pr-readiness.sh +1 -1
  21. package/scripts/check-scope.sh +0 -1
  22. package/scripts/check-slice-readiness.sh +3 -4
  23. package/scripts/init-docs.sh +53 -6
  24. package/scripts/package-quiver.sh +18 -2
  25. package/specs/quiver-v20-ai-cli-orchestration/EVIDENCE_REPORT.md +23 -0
  26. package/specs/quiver-v20-ai-cli-orchestration/EXECUTION_PLAN.md +57 -0
  27. package/specs/quiver-v20-ai-cli-orchestration/SPEC.md +202 -0
  28. package/specs/quiver-v20-ai-cli-orchestration/STATUS.md +35 -0
  29. package/specs/quiver-v20-ai-cli-orchestration/pr.md +100 -0
  30. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-00-spec-foundation/CLOSURE_BRIEF.md +30 -0
  31. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-00-spec-foundation/EXECUTION_BRIEF.md +61 -0
  32. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-00-spec-foundation/slice.json +54 -0
  33. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-01-ai-provider-runner/CLOSURE_BRIEF.md +39 -0
  34. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-01-ai-provider-runner/EXECUTION_BRIEF.md +63 -0
  35. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-01-ai-provider-runner/slice.json +55 -0
  36. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-02-context-packs-token-budget/CLOSURE_BRIEF.md +40 -0
  37. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-02-context-packs-token-budget/EXECUTION_BRIEF.md +60 -0
  38. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-02-context-packs-token-budget/slice.json +54 -0
  39. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-03-ai-phase-gated-planner/CLOSURE_BRIEF.md +43 -0
  40. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-03-ai-phase-gated-planner/EXECUTION_BRIEF.md +62 -0
  41. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-03-ai-phase-gated-planner/slice.json +62 -0
  42. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-04-spec-slice-handoff-pr-generation/CLOSURE_BRIEF.md +36 -0
  43. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-04-spec-slice-handoff-pr-generation/EXECUTION_BRIEF.md +63 -0
  44. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-04-spec-slice-handoff-pr-generation/slice.json +59 -0
  45. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-05-execution-plan-parallel-worktrees/CLOSURE_BRIEF.md +32 -0
  46. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-05-execution-plan-parallel-worktrees/EXECUTION_BRIEF.md +61 -0
  47. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-05-execution-plan-parallel-worktrees/slice.json +59 -0
  48. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-06-ai-execute-slice-scope-enforcement/CLOSURE_BRIEF.md +36 -0
  49. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-06-ai-execute-slice-scope-enforcement/EXECUTION_BRIEF.md +64 -0
  50. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-06-ai-execute-slice-scope-enforcement/slice.json +65 -0
  51. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-07-github-pr-preflight/CLOSURE_BRIEF.md +36 -0
  52. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-07-github-pr-preflight/EXECUTION_BRIEF.md +66 -0
  53. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-07-github-pr-preflight/slice.json +63 -0
  54. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-08-docs-smokes-release-readiness/CLOSURE_BRIEF.md +35 -0
  55. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-08-docs-smokes-release-readiness/EXECUTION_BRIEF.md +64 -0
  56. package/specs/quiver-v20-ai-cli-orchestration/slices/slice-08-docs-smokes-release-readiness/slice.json +77 -0
  57. package/specs/quiver-v21-ai-first-layout/EVIDENCE_REPORT.md +31 -0
  58. package/specs/quiver-v21-ai-first-layout/EXECUTION_PLAN.md +185 -0
  59. package/specs/quiver-v21-ai-first-layout/SPEC.md +212 -0
  60. package/specs/quiver-v21-ai-first-layout/STATUS.md +37 -0
  61. package/specs/quiver-v21-ai-first-layout/pr.md +110 -0
  62. package/specs/quiver-v21-ai-first-layout/slices/slice-00-spec-foundation/CLOSURE_BRIEF.md +30 -0
  63. package/specs/quiver-v21-ai-first-layout/slices/slice-00-spec-foundation/EXECUTION_BRIEF.md +63 -0
  64. package/specs/quiver-v21-ai-first-layout/slices/slice-00-spec-foundation/slice.json +45 -0
  65. package/specs/quiver-v21-ai-first-layout/slices/slice-01-init-profiles-dry-run/CLOSURE_BRIEF.md +31 -0
  66. package/specs/quiver-v21-ai-first-layout/slices/slice-01-init-profiles-dry-run/EXECUTION_BRIEF.md +59 -0
  67. package/specs/quiver-v21-ai-first-layout/slices/slice-01-init-profiles-dry-run/slice.json +57 -0
  68. package/specs/quiver-v21-ai-first-layout/slices/slice-02-internal-layout-template-resolver/CLOSURE_BRIEF.md +32 -0
  69. package/specs/quiver-v21-ai-first-layout/slices/slice-02-internal-layout-template-resolver/EXECUTION_BRIEF.md +60 -0
  70. package/specs/quiver-v21-ai-first-layout/slices/slice-02-internal-layout-template-resolver/slice.json +58 -0
  71. package/specs/quiver-v21-ai-first-layout/slices/slice-03-generation-profiles-visible-contract/CLOSURE_BRIEF.md +34 -0
  72. package/specs/quiver-v21-ai-first-layout/slices/slice-03-generation-profiles-visible-contract/EXECUTION_BRIEF.md +61 -0
  73. package/specs/quiver-v21-ai-first-layout/slices/slice-03-generation-profiles-visible-contract/slice.json +64 -0
  74. package/specs/quiver-v21-ai-first-layout/slices/slice-04-analyze-scan-relocation/CLOSURE_BRIEF.md +32 -0
  75. package/specs/quiver-v21-ai-first-layout/slices/slice-04-analyze-scan-relocation/EXECUTION_BRIEF.md +58 -0
  76. package/specs/quiver-v21-ai-first-layout/slices/slice-04-analyze-scan-relocation/slice.json +64 -0
  77. package/specs/quiver-v21-ai-first-layout/slices/slice-05-empty-specs-layout-doctor/CLOSURE_BRIEF.md +32 -0
  78. package/specs/quiver-v21-ai-first-layout/slices/slice-05-empty-specs-layout-doctor/EXECUTION_BRIEF.md +60 -0
  79. package/specs/quiver-v21-ai-first-layout/slices/slice-05-empty-specs-layout-doctor/slice.json +65 -0
  80. package/specs/quiver-v21-ai-first-layout/slices/slice-06-legacy-migration-optional-assets/CLOSURE_BRIEF.md +31 -0
  81. package/specs/quiver-v21-ai-first-layout/slices/slice-06-legacy-migration-optional-assets/EXECUTION_BRIEF.md +62 -0
  82. package/specs/quiver-v21-ai-first-layout/slices/slice-06-legacy-migration-optional-assets/slice.json +66 -0
  83. package/specs/quiver-v21-ai-first-layout/slices/slice-07-docs-guidance-alignment/CLOSURE_BRIEF.md +33 -0
  84. package/specs/quiver-v21-ai-first-layout/slices/slice-07-docs-guidance-alignment/EXECUTION_BRIEF.md +61 -0
  85. package/specs/quiver-v21-ai-first-layout/slices/slice-07-docs-guidance-alignment/slice.json +67 -0
  86. package/specs/quiver-v21-ai-first-layout/slices/slice-08-smokes-release-readiness/CLOSURE_BRIEF.md +35 -0
  87. package/specs/quiver-v21-ai-first-layout/slices/slice-08-smokes-release-readiness/EXECUTION_BRIEF.md +66 -0
  88. package/specs/quiver-v21-ai-first-layout/slices/slice-08-smokes-release-readiness/slice.json +62 -0
  89. package/specs/quiver-v22-guided-ai-workflow/EVIDENCE_REPORT.md +58 -0
  90. package/specs/quiver-v22-guided-ai-workflow/EXECUTION_PLAN.md +88 -0
  91. package/specs/quiver-v22-guided-ai-workflow/SPEC.md +228 -0
  92. package/specs/quiver-v22-guided-ai-workflow/STATUS.md +42 -0
  93. package/specs/quiver-v22-guided-ai-workflow/pr.md +104 -0
  94. package/specs/quiver-v22-guided-ai-workflow/slices/slice-00-spec-foundation/CLOSURE_BRIEF.md +35 -0
  95. package/specs/quiver-v22-guided-ai-workflow/slices/slice-00-spec-foundation/EXECUTION_BRIEF.md +61 -0
  96. package/specs/quiver-v22-guided-ai-workflow/slices/slice-00-spec-foundation/slice.json +51 -0
  97. package/specs/quiver-v22-guided-ai-workflow/slices/slice-01-docs-source-of-truth-sync/CLOSURE_BRIEF.md +31 -0
  98. package/specs/quiver-v22-guided-ai-workflow/slices/slice-01-docs-source-of-truth-sync/EXECUTION_BRIEF.md +58 -0
  99. package/specs/quiver-v22-guided-ai-workflow/slices/slice-01-docs-source-of-truth-sync/slice.json +55 -0
  100. package/specs/quiver-v22-guided-ai-workflow/slices/slice-02-prepare-command-diagnostics/CLOSURE_BRIEF.md +30 -0
  101. package/specs/quiver-v22-guided-ai-workflow/slices/slice-02-prepare-command-diagnostics/EXECUTION_BRIEF.md +57 -0
  102. package/specs/quiver-v22-guided-ai-workflow/slices/slice-02-prepare-command-diagnostics/slice.json +57 -0
  103. package/specs/quiver-v22-guided-ai-workflow/slices/slice-03-context-doc-refresh/CLOSURE_BRIEF.md +32 -0
  104. package/specs/quiver-v22-guided-ai-workflow/slices/slice-03-context-doc-refresh/EXECUTION_BRIEF.md +56 -0
  105. package/specs/quiver-v22-guided-ai-workflow/slices/slice-03-context-doc-refresh/slice.json +56 -0
  106. package/specs/quiver-v22-guided-ai-workflow/slices/slice-04-planner-approval-state/CLOSURE_BRIEF.md +33 -0
  107. package/specs/quiver-v22-guided-ai-workflow/slices/slice-04-planner-approval-state/EXECUTION_BRIEF.md +56 -0
  108. package/specs/quiver-v22-guided-ai-workflow/slices/slice-04-planner-approval-state/slice.json +58 -0
  109. package/specs/quiver-v22-guided-ai-workflow/slices/slice-05-spec-worktree-lifecycle/CLOSURE_BRIEF.md +32 -0
  110. package/specs/quiver-v22-guided-ai-workflow/slices/slice-05-spec-worktree-lifecycle/EXECUTION_BRIEF.md +56 -0
  111. package/specs/quiver-v22-guided-ai-workflow/slices/slice-05-spec-worktree-lifecycle/slice.json +54 -0
  112. package/specs/quiver-v22-guided-ai-workflow/slices/slice-06-executor-commit-recovery/CLOSURE_BRIEF.md +32 -0
  113. package/specs/quiver-v22-guided-ai-workflow/slices/slice-06-executor-commit-recovery/EXECUTION_BRIEF.md +58 -0
  114. package/specs/quiver-v22-guided-ai-workflow/slices/slice-06-executor-commit-recovery/slice.json +57 -0
  115. package/specs/quiver-v22-guided-ai-workflow/slices/slice-07-execution-waves-delegation/CLOSURE_BRIEF.md +32 -0
  116. package/specs/quiver-v22-guided-ai-workflow/slices/slice-07-execution-waves-delegation/EXECUTION_BRIEF.md +58 -0
  117. package/specs/quiver-v22-guided-ai-workflow/slices/slice-07-execution-waves-delegation/slice.json +55 -0
  118. package/specs/quiver-v22-guided-ai-workflow/slices/slice-08-pr-create-gh-ssh/CLOSURE_BRIEF.md +32 -0
  119. package/specs/quiver-v22-guided-ai-workflow/slices/slice-08-pr-create-gh-ssh/EXECUTION_BRIEF.md +58 -0
  120. package/specs/quiver-v22-guided-ai-workflow/slices/slice-08-pr-create-gh-ssh/slice.json +53 -0
  121. package/specs/quiver-v22-guided-ai-workflow/slices/slice-09-post-merge-cleanup-release-safety/CLOSURE_BRIEF.md +33 -0
  122. package/specs/quiver-v22-guided-ai-workflow/slices/slice-09-post-merge-cleanup-release-safety/EXECUTION_BRIEF.md +59 -0
  123. package/specs/quiver-v22-guided-ai-workflow/slices/slice-09-post-merge-cleanup-release-safety/slice.json +59 -0
  124. package/specs/quiver-v22-guided-ai-workflow/slices/slice-10-docs-smokes-release-readiness/CLOSURE_BRIEF.md +34 -0
  125. package/specs/quiver-v22-guided-ai-workflow/slices/slice-10-docs-smokes-release-readiness/EXECUTION_BRIEF.md +58 -0
  126. package/specs/quiver-v22-guided-ai-workflow/slices/slice-10-docs-smokes-release-readiness/slice.json +60 -0
  127. package/specs/quiver-v23-guided-flow-productization/EVIDENCE_REPORT.md +80 -0
  128. package/specs/quiver-v23-guided-flow-productization/EXECUTION_PLAN.md +80 -0
  129. package/specs/quiver-v23-guided-flow-productization/SPEC.md +203 -0
  130. package/specs/quiver-v23-guided-flow-productization/STATUS.md +39 -0
  131. package/specs/quiver-v23-guided-flow-productization/pr.md +119 -0
  132. package/specs/quiver-v23-guided-flow-productization/slices/slice-00-spec-foundation/CLOSURE_BRIEF.md +30 -0
  133. package/specs/quiver-v23-guided-flow-productization/slices/slice-00-spec-foundation/EXECUTION_BRIEF.md +61 -0
  134. package/specs/quiver-v23-guided-flow-productization/slices/slice-00-spec-foundation/slice.json +51 -0
  135. package/specs/quiver-v23-guided-flow-productization/slices/slice-01-short-command-and-flow-entrypoint/CLOSURE_BRIEF.md +33 -0
  136. package/specs/quiver-v23-guided-flow-productization/slices/slice-01-short-command-and-flow-entrypoint/EXECUTION_BRIEF.md +35 -0
  137. package/specs/quiver-v23-guided-flow-productization/slices/slice-01-short-command-and-flow-entrypoint/slice.json +56 -0
  138. package/specs/quiver-v23-guided-flow-productization/slices/slice-02-flow-status-wizard/CLOSURE_BRIEF.md +31 -0
  139. package/specs/quiver-v23-guided-flow-productization/slices/slice-02-flow-status-wizard/EXECUTION_BRIEF.md +29 -0
  140. package/specs/quiver-v23-guided-flow-productization/slices/slice-02-flow-status-wizard/slice.json +55 -0
  141. package/specs/quiver-v23-guided-flow-productization/slices/slice-03-agent-profiles/CLOSURE_BRIEF.md +33 -0
  142. package/specs/quiver-v23-guided-flow-productization/slices/slice-03-agent-profiles/EXECUTION_BRIEF.md +29 -0
  143. package/specs/quiver-v23-guided-flow-productization/slices/slice-03-agent-profiles/slice.json +54 -0
  144. package/specs/quiver-v23-guided-flow-productization/slices/slice-04-context-preparation-onboarding/CLOSURE_BRIEF.md +32 -0
  145. package/specs/quiver-v23-guided-flow-productization/slices/slice-04-context-preparation-onboarding/EXECUTION_BRIEF.md +30 -0
  146. package/specs/quiver-v23-guided-flow-productization/slices/slice-04-context-preparation-onboarding/slice.json +59 -0
  147. package/specs/quiver-v23-guided-flow-productization/slices/slice-05-planner-iteration-history/CLOSURE_BRIEF.md +31 -0
  148. package/specs/quiver-v23-guided-flow-productization/slices/slice-05-planner-iteration-history/EXECUTION_BRIEF.md +29 -0
  149. package/specs/quiver-v23-guided-flow-productization/slices/slice-05-planner-iteration-history/slice.json +53 -0
  150. package/specs/quiver-v23-guided-flow-productization/slices/slice-06-production-plan-review/CLOSURE_BRIEF.md +33 -0
  151. package/specs/quiver-v23-guided-flow-productization/slices/slice-06-production-plan-review/EXECUTION_BRIEF.md +30 -0
  152. package/specs/quiver-v23-guided-flow-productization/slices/slice-06-production-plan-review/slice.json +54 -0
  153. package/specs/quiver-v23-guided-flow-productization/slices/slice-07-spec-create-experience/CLOSURE_BRIEF.md +33 -0
  154. package/specs/quiver-v23-guided-flow-productization/slices/slice-07-spec-create-experience/EXECUTION_BRIEF.md +30 -0
  155. package/specs/quiver-v23-guided-flow-productization/slices/slice-07-spec-create-experience/slice.json +55 -0
  156. package/specs/quiver-v23-guided-flow-productization/slices/slice-08-executor-prompt-generation/CLOSURE_BRIEF.md +32 -0
  157. package/specs/quiver-v23-guided-flow-productization/slices/slice-08-executor-prompt-generation/EXECUTION_BRIEF.md +30 -0
  158. package/specs/quiver-v23-guided-flow-productization/slices/slice-08-executor-prompt-generation/slice.json +55 -0
  159. package/specs/quiver-v23-guided-flow-productization/slices/slice-09-delegated-slice-execution/CLOSURE_BRIEF.md +33 -0
  160. package/specs/quiver-v23-guided-flow-productization/slices/slice-09-delegated-slice-execution/EXECUTION_BRIEF.md +34 -0
  161. package/specs/quiver-v23-guided-flow-productization/slices/slice-09-delegated-slice-execution/slice.json +57 -0
  162. package/specs/quiver-v23-guided-flow-productization/slices/slice-10-docs-smokes-release-readiness/CLOSURE_BRIEF.md +33 -0
  163. package/specs/quiver-v23-guided-flow-productization/slices/slice-10-docs-smokes-release-readiness/EXECUTION_BRIEF.md +32 -0
  164. package/specs/quiver-v23-guided-flow-productization/slices/slice-10-docs-smokes-release-readiness/slice.json +63 -0
  165. package/specs/quiver-v24-dx-onboarding-hardening/EVIDENCE_REPORT.md +55 -0
  166. package/specs/quiver-v24-dx-onboarding-hardening/EXECUTION_PLAN.md +43 -0
  167. package/specs/quiver-v24-dx-onboarding-hardening/SPEC.md +149 -0
  168. package/specs/quiver-v24-dx-onboarding-hardening/STATUS.md +31 -0
  169. package/specs/quiver-v24-dx-onboarding-hardening/pr.md +76 -0
  170. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-00-spec-foundation/CLOSURE_BRIEF.md +31 -0
  171. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-00-spec-foundation/EXECUTION_BRIEF.md +52 -0
  172. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-00-spec-foundation/slice.json +51 -0
  173. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-01-init-template-hygiene/CLOSURE_BRIEF.md +38 -0
  174. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-01-init-template-hygiene/EXECUTION_BRIEF.md +53 -0
  175. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-01-init-template-hygiene/slice.json +55 -0
  176. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-02-cli-command-routing-version-errors/CLOSURE_BRIEF.md +33 -0
  177. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-02-cli-command-routing-version-errors/EXECUTION_BRIEF.md +50 -0
  178. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-02-cli-command-routing-version-errors/slice.json +52 -0
  179. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-03-doctor-fix-doc-link-checks/CLOSURE_BRIEF.md +33 -0
  180. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-03-doctor-fix-doc-link-checks/EXECUTION_BRIEF.md +50 -0
  181. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-03-doctor-fix-doc-link-checks/slice.json +53 -0
  182. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-04-prepare-output-ai-context-drafts/CLOSURE_BRIEF.md +33 -0
  183. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-04-prepare-output-ai-context-drafts/EXECUTION_BRIEF.md +50 -0
  184. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-04-prepare-output-ai-context-drafts/slice.json +70 -0
  185. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-05-local-slice-validation-base-guidance/CLOSURE_BRIEF.md +36 -0
  186. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-05-local-slice-validation-base-guidance/EXECUTION_BRIEF.md +49 -0
  187. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-05-local-slice-validation-base-guidance/slice.json +52 -0
  188. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-06-plan-graph-next-history-views/CLOSURE_BRIEF.md +43 -0
  189. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-06-plan-graph-next-history-views/EXECUTION_BRIEF.md +53 -0
  190. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-06-plan-graph-next-history-views/slice.json +60 -0
  191. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-07-analyzer-command-map-hardening/CLOSURE_BRIEF.md +32 -0
  192. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-07-analyzer-command-map-hardening/EXECUTION_BRIEF.md +50 -0
  193. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-07-analyzer-command-map-hardening/slice.json +51 -0
  194. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-08-evidence-run-command/CLOSURE_BRIEF.md +34 -0
  195. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-08-evidence-run-command/EXECUTION_BRIEF.md +52 -0
  196. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-08-evidence-run-command/slice.json +54 -0
  197. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-09-spec-viewer-demo-scaffolding/CLOSURE_BRIEF.md +34 -0
  198. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-09-spec-viewer-demo-scaffolding/EXECUTION_BRIEF.md +51 -0
  199. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-09-spec-viewer-demo-scaffolding/slice.json +59 -0
  200. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-10-docs-smokes-release-readiness/CLOSURE_BRIEF.md +33 -0
  201. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-10-docs-smokes-release-readiness/EXECUTION_BRIEF.md +54 -0
  202. package/specs/quiver-v24-dx-onboarding-hardening/slices/slice-10-docs-smokes-release-readiness/slice.json +76 -0
  203. package/src/create-quiver/commands/ai.js +915 -0
  204. package/src/create-quiver/commands/demo.js +22 -0
  205. package/src/create-quiver/commands/evidence.js +37 -0
  206. package/src/create-quiver/commands/flow.js +561 -0
  207. package/src/create-quiver/commands/graph.js +14 -1
  208. package/src/create-quiver/commands/next.js +28 -0
  209. package/src/create-quiver/commands/plan.js +6 -3
  210. package/src/create-quiver/commands/prepare.js +236 -0
  211. package/src/create-quiver/commands/spec.js +133 -0
  212. package/src/create-quiver/index.js +1096 -96
  213. package/src/create-quiver/lib/agent-profiles.js +148 -0
  214. package/src/create-quiver/lib/ai/context-packs.js +170 -0
  215. package/src/create-quiver/lib/ai/execution-plan.js +614 -0
  216. package/src/create-quiver/lib/ai/executor.js +682 -0
  217. package/src/create-quiver/lib/ai/github.js +525 -0
  218. package/src/create-quiver/lib/ai/onboarding-template.js +365 -0
  219. package/src/create-quiver/lib/ai/phase-gates.js +72 -0
  220. package/src/create-quiver/lib/ai/plan-review.js +283 -0
  221. package/src/create-quiver/lib/ai/preflight.js +58 -0
  222. package/src/create-quiver/lib/ai/prompt-transport.js +81 -0
  223. package/src/create-quiver/lib/ai/prompts.js +39 -0
  224. package/src/create-quiver/lib/ai/providers.js +315 -0
  225. package/src/create-quiver/lib/ai/safety.js +156 -0
  226. package/src/create-quiver/lib/ai/spec-generator.js +314 -0
  227. package/src/create-quiver/lib/ai/spec-templates.js +715 -0
  228. package/src/create-quiver/lib/approvals.js +350 -0
  229. package/src/create-quiver/lib/demo.js +657 -0
  230. package/src/create-quiver/lib/doctor.js +348 -0
  231. package/src/create-quiver/lib/evidence.js +115 -0
  232. package/src/create-quiver/lib/git.js +21 -0
  233. package/src/create-quiver/lib/init-docs.js +545 -23
  234. package/src/create-quiver/lib/init-layout.js +451 -0
  235. package/src/create-quiver/lib/lifecycle.js +8 -2
  236. package/src/create-quiver/lib/package-safety.js +117 -0
  237. package/src/create-quiver/lib/paths.js +63 -2
  238. package/src/create-quiver/lib/project-scan.js +66 -0
  239. package/src/create-quiver/lib/readiness.js +87 -18
  240. package/src/create-quiver/lib/scope.js +125 -0
  241. package/src/create-quiver/lib/slice-graph.js +7 -0
  242. package/src/create-quiver/lib/slice.js +59 -16
  243. package/src/create-quiver/lib/spec-worktrees.js +349 -0
  244. package/src/create-quiver/lib/state.js +18 -1
  245. package/src/create-quiver/lib/template-resolver.js +74 -0
@@ -0,0 +1,349 @@
1
+ const fs = require('fs');
2
+ const path = require('path');
3
+
4
+ const {
5
+ currentBranch,
6
+ fetchRemote,
7
+ hasLocalBranch,
8
+ hasRemoteBranch,
9
+ isCleanWorktree,
10
+ lsRemoteHeads,
11
+ mergeBaseIsAncestor,
12
+ runGit,
13
+ statusPorcelain,
14
+ worktreeAdd,
15
+ worktreeList,
16
+ worktreePrune,
17
+ worktreeRemove,
18
+ } = require('./git');
19
+ const { parseJsonWithComments } = require('./json');
20
+ const { safeBranchName, worktreesRootForRepo } = require('./slice');
21
+
22
+ function formatError(message) {
23
+ return `create-quiver: ${message}`;
24
+ }
25
+
26
+ function toPosix(relativePath) {
27
+ return relativePath.split(path.sep).join('/');
28
+ }
29
+
30
+ function findSpecDir(repoRoot, specInput) {
31
+ const value = String(specInput || '').trim();
32
+ if (!value || value === '.') {
33
+ throw new Error(formatError('missing spec directory. Use: npx create-quiver spec status specs/<spec-slug>'));
34
+ }
35
+
36
+ const resolved = path.resolve(repoRoot, value);
37
+ if (!fs.existsSync(path.join(resolved, 'SPEC.md'))) {
38
+ throw new Error(formatError(`missing SPEC.md in ${toPosix(path.relative(repoRoot, resolved))}`));
39
+ }
40
+
41
+ return resolved;
42
+ }
43
+
44
+ function listSpecSlices(specDir) {
45
+ const slicesDir = path.join(specDir, 'slices');
46
+ if (!fs.existsSync(slicesDir)) {
47
+ return [];
48
+ }
49
+
50
+ return fs.readdirSync(slicesDir, { withFileTypes: true })
51
+ .filter((entry) => entry.isDirectory())
52
+ .map((entry) => {
53
+ const slicePath = path.join(slicesDir, entry.name, 'slice.json');
54
+ if (!fs.existsSync(slicePath)) {
55
+ return null;
56
+ }
57
+ const json = parseJsonWithComments(fs.readFileSync(slicePath, 'utf8'));
58
+ return {
59
+ id: json.slice_id || entry.name,
60
+ path: slicePath,
61
+ status: String(json.status || 'draft'),
62
+ title: json.title || json.slice_id || entry.name,
63
+ };
64
+ })
65
+ .filter(Boolean)
66
+ .sort((left, right) => left.id.localeCompare(right.id));
67
+ }
68
+
69
+ function resolveSpecIdentity(repoRoot, specDir) {
70
+ const relativeSpecDir = toPosix(path.relative(repoRoot, specDir));
71
+ const specSlug = path.basename(specDir);
72
+ const branchName = `feature/${specSlug}`;
73
+ return {
74
+ branchName,
75
+ relativeSpecDir,
76
+ specSlug,
77
+ worktreePath: path.join(worktreesRootForRepo(repoRoot, branchName), safeBranchName(branchName)),
78
+ };
79
+ }
80
+
81
+ function findExistingWorktree(repoRoot, branchName) {
82
+ for (const entry of worktreeList(repoRoot)) {
83
+ const branchRef = entry.branch || '';
84
+ if (branchRef.replace('refs/heads/', '') === branchName) {
85
+ return entry.worktree;
86
+ }
87
+ }
88
+ return '';
89
+ }
90
+
91
+ function resolveBaseRef(repoRoot, preferred = '') {
92
+ const candidates = [preferred, 'main', 'develop'].filter(Boolean);
93
+ for (const candidate of candidates) {
94
+ if (hasLocalBranch(repoRoot, candidate)) {
95
+ return candidate;
96
+ }
97
+ if (hasRemoteBranch(repoRoot, candidate)) {
98
+ return `origin/${candidate}`;
99
+ }
100
+ if (lsRemoteHeads(repoRoot, candidate)) {
101
+ return `origin/${candidate}`;
102
+ }
103
+ }
104
+ throw new Error(formatError('missing base branch. Expected local or remote main/develop.'));
105
+ }
106
+
107
+ function resolveMergedBaseRef(repoRoot, preferred = '', remote = 'origin') {
108
+ const candidates = [preferred, 'main', 'develop'].filter(Boolean);
109
+ for (const candidate of candidates) {
110
+ if (hasRemoteBranch(repoRoot, candidate, remote)) {
111
+ return {
112
+ baseBranch: candidate,
113
+ baseRef: `${remote}/${candidate}`,
114
+ remote,
115
+ };
116
+ }
117
+ if (hasLocalBranch(repoRoot, candidate)) {
118
+ return {
119
+ baseBranch: candidate,
120
+ baseRef: candidate,
121
+ remote: '',
122
+ };
123
+ }
124
+ }
125
+ throw new Error(formatError('missing merge base branch. Expected local or remote main/develop.'));
126
+ }
127
+
128
+ function buildSpecStatus(repoRoot, specInput) {
129
+ const specDir = findSpecDir(repoRoot, specInput);
130
+ const identity = resolveSpecIdentity(repoRoot, specDir);
131
+ const slices = listSpecSlices(specDir);
132
+ const slice00 = slices.find((slice) => slice.id.startsWith('slice-00')) || null;
133
+ const pendingSlices = slices.filter((slice) => slice.status !== 'completed');
134
+ const laterSlicesBlocked = !slice00 || slice00.status !== 'completed';
135
+ const existingWorktree = findExistingWorktree(repoRoot, identity.branchName);
136
+ const worktreeDirty = existingWorktree ? !isCleanWorktree(existingWorktree) : false;
137
+
138
+ return {
139
+ ...identity,
140
+ existingWorktree,
141
+ laterSlicesBlocked,
142
+ pendingSlices,
143
+ slice00,
144
+ slices,
145
+ specDir,
146
+ worktreeDirty,
147
+ };
148
+ }
149
+
150
+ function formatSpecStatus(status) {
151
+ const lines = [
152
+ 'Spec worktree status',
153
+ `Spec: ${status.relativeSpecDir}`,
154
+ `Branch: ${status.branchName}`,
155
+ `Worktree: ${status.existingWorktree || status.worktreePath}`,
156
+ `Worktree dirty: ${status.worktreeDirty ? 'yes' : 'no'}`,
157
+ `slice-00: ${status.slice00 ? status.slice00.status : 'missing'}`,
158
+ `Later slices blocked: ${status.laterSlicesBlocked ? 'yes' : 'no'}`,
159
+ 'Pending slices:',
160
+ ];
161
+
162
+ if (status.pendingSlices.length === 0) {
163
+ lines.push('- none');
164
+ } else {
165
+ for (const slice of status.pendingSlices) {
166
+ lines.push(`- ${slice.id}: ${slice.status}`);
167
+ }
168
+ }
169
+
170
+ return `${lines.join('\n')}\n`;
171
+ }
172
+
173
+ function startSpecWorktree(repoRoot, specInput, options = {}) {
174
+ const specDir = findSpecDir(repoRoot, specInput);
175
+ const identity = resolveSpecIdentity(repoRoot, specDir);
176
+ const existingWorktree = findExistingWorktree(repoRoot, identity.branchName);
177
+ const slices = listSpecSlices(specDir);
178
+ const slice00 = slices.find((slice) => slice.id.startsWith('slice-00')) || null;
179
+ const baseRef = resolveBaseRef(repoRoot, options.baseBranch);
180
+
181
+ if (existingWorktree) {
182
+ if (!isCleanWorktree(existingWorktree)) {
183
+ throw new Error(formatError(`existing spec worktree is dirty: ${existingWorktree}`));
184
+ }
185
+ return {
186
+ ...identity,
187
+ baseRef,
188
+ reused: true,
189
+ slice00,
190
+ worktreePath: existingWorktree,
191
+ };
192
+ }
193
+
194
+ if (fs.existsSync(identity.worktreePath)) {
195
+ throw new Error(formatError(`worktree path already exists and is not registered for ${identity.branchName}: ${identity.worktreePath}`));
196
+ }
197
+
198
+ if (!isCleanWorktree(repoRoot)) {
199
+ throw new Error(formatError('current checkout is not clean. Commit or stash before starting a spec worktree.'));
200
+ }
201
+
202
+ worktreePrune(repoRoot);
203
+ fs.mkdirSync(path.dirname(identity.worktreePath), { recursive: true });
204
+
205
+ if (hasLocalBranch(repoRoot, identity.branchName)) {
206
+ worktreeAdd(repoRoot, identity.worktreePath, identity.branchName);
207
+ } else {
208
+ worktreeAdd(repoRoot, identity.worktreePath, baseRef, { branch: identity.branchName });
209
+ }
210
+
211
+ return {
212
+ ...identity,
213
+ baseRef,
214
+ currentBranch: currentBranch(repoRoot),
215
+ reused: false,
216
+ slice00,
217
+ };
218
+ }
219
+
220
+ function formatSpecStartResult(result) {
221
+ return `${[
222
+ 'Spec worktree ready',
223
+ `Branch: ${result.branchName}`,
224
+ `Base: ${result.baseRef}`,
225
+ `Worktree: ${result.worktreePath}`,
226
+ `Reused: ${result.reused ? 'yes' : 'no'}`,
227
+ `slice-00: ${result.slice00 ? result.slice00.status : 'missing'}`,
228
+ ].join('\n')}\n`;
229
+ }
230
+
231
+ function closeSpecWorktree(repoRoot, specInput, options = {}) {
232
+ const specDir = findSpecDir(repoRoot, specInput);
233
+ const identity = resolveSpecIdentity(repoRoot, specDir);
234
+ const existingWorktree = findExistingWorktree(repoRoot, identity.branchName);
235
+ const discard = options.discard === true;
236
+ const dryRun = options.dryRun === true;
237
+ const force = options.force === true;
238
+ const remote = options.remote || 'origin';
239
+ const base = resolveMergedBaseRef(repoRoot, options.baseBranch, remote);
240
+
241
+ if (!existingWorktree) {
242
+ throw new Error(formatError(`missing spec worktree for branch ${identity.branchName}.`));
243
+ }
244
+
245
+ if (!discard && !isCleanWorktree(existingWorktree)) {
246
+ throw new Error(formatError(`spec worktree is dirty: ${existingWorktree}. Commit or stash before closing, or pass --discard intentionally.`));
247
+ }
248
+
249
+ if (!discard) {
250
+ const branch = currentBranch(repoRoot);
251
+ if (branch !== base.baseBranch) {
252
+ throw new Error(formatError(`spec close must run from ${base.baseBranch}. Current branch: ${branch || '(detached)'}.`));
253
+ }
254
+ if (statusPorcelain(repoRoot) !== '') {
255
+ throw new Error(formatError('main checkout is dirty. Commit or stash before closing the spec worktree.'));
256
+ }
257
+ if (base.remote) {
258
+ try {
259
+ fetchRemote(repoRoot, base.remote, [base.baseBranch]);
260
+ } catch {
261
+ // Local-only test repos and offline environments can still validate against the current remote ref.
262
+ }
263
+ }
264
+ if (hasLocalBranch(repoRoot, identity.branchName) && !mergeBaseIsAncestor(repoRoot, identity.branchName, base.baseRef)) {
265
+ throw new Error(formatError(`spec branch ${identity.branchName} is not merged into ${base.baseRef}. Merge the PR before cleanup, or pass --discard intentionally.`));
266
+ }
267
+ }
268
+
269
+ if (dryRun) {
270
+ return {
271
+ ...identity,
272
+ baseBranch: base.baseBranch,
273
+ baseRef: base.baseRef,
274
+ discarded: discard,
275
+ dryRun: true,
276
+ pulled: false,
277
+ remote: base.remote,
278
+ removed: false,
279
+ worktreePath: existingWorktree,
280
+ };
281
+ }
282
+
283
+ worktreeRemove(repoRoot, existingWorktree, force || discard);
284
+ if (!discard && base.remote) {
285
+ runGit(['pull', '--ff-only', remote, base.baseBranch], repoRoot);
286
+ }
287
+
288
+ return {
289
+ ...identity,
290
+ baseBranch: base.baseBranch,
291
+ baseRef: base.baseRef,
292
+ discarded: discard,
293
+ dryRun: false,
294
+ pulled: !discard && Boolean(base.remote),
295
+ remote: base.remote,
296
+ removed: true,
297
+ worktreePath: existingWorktree,
298
+ };
299
+ }
300
+
301
+ function formatSpecCloseResult(result) {
302
+ const lines = [
303
+ result.dryRun ? 'Spec close dry-run' : 'Spec worktree closed',
304
+ `Spec: ${result.relativeSpecDir}`,
305
+ `Branch: ${result.branchName}`,
306
+ `Base: ${result.baseRef}`,
307
+ `Worktree: ${result.worktreePath}`,
308
+ `Discard: ${result.discarded ? 'yes' : 'no'}`,
309
+ ];
310
+
311
+ if (result.dryRun) {
312
+ lines.push(`Would remove worktree: ${result.worktreePath}`);
313
+ if (!result.discarded && result.remote) {
314
+ lines.push(`Would pull: git pull --ff-only ${result.remote} ${result.baseBranch}`);
315
+ }
316
+ } else {
317
+ lines.push(`Removed worktree: ${result.removed ? 'yes' : 'no'}`);
318
+ lines.push(`Pulled main checkout: ${result.pulled ? 'yes' : 'no'}`);
319
+ }
320
+
321
+ return `${lines.join('\n')}\n`;
322
+ }
323
+
324
+ function ensureSpecSliceZeroComplete(repoRoot, specInput) {
325
+ const status = buildSpecStatus(repoRoot, specInput);
326
+ if (!status.slice00) {
327
+ throw new Error(formatError(`spec ${status.relativeSpecDir} requires slice-00 completed before starting later slices; slice-00 is missing.`));
328
+ }
329
+ if (status.slice00.status !== 'completed') {
330
+ throw new Error(formatError(`spec ${status.relativeSpecDir} requires slice-00 completed before starting later slices; current status: ${status.slice00.status}.`));
331
+ }
332
+ return status.slice00;
333
+ }
334
+
335
+ module.exports = {
336
+ buildSpecStatus,
337
+ closeSpecWorktree,
338
+ ensureSpecSliceZeroComplete,
339
+ findSpecDir,
340
+ findExistingWorktree,
341
+ formatSpecCloseResult,
342
+ formatSpecStartResult,
343
+ formatSpecStatus,
344
+ listSpecSlices,
345
+ resolveBaseRef,
346
+ resolveMergedBaseRef,
347
+ resolveSpecIdentity,
348
+ startSpecWorktree,
349
+ };
@@ -1,8 +1,9 @@
1
1
  const fs = require('fs');
2
2
  const path = require('path');
3
+ const { quiverInternalPaths } = require('./init-layout');
3
4
 
4
5
  function statePath(projectRoot) {
5
- return path.join(projectRoot, '.quiver', 'state.json');
6
+ return quiverInternalPaths(projectRoot).statePath;
6
7
  }
7
8
 
8
9
  function ensureDir(dirPath) {
@@ -60,6 +61,21 @@ function hasLegacyQuiverInitializationEvidence(projectRoot) {
60
61
  && hasGeneratedProjectSpec(projectRoot);
61
62
  }
62
63
 
64
+ function inspectLegacyMigrationLayout(projectRoot) {
65
+ const candidates = [
66
+ 'docs-template/',
67
+ 'tools/scripts/',
68
+ 'docs/PROJECT_SCAN.json',
69
+ ];
70
+
71
+ const detected = candidates.filter((relativePath) => fs.existsSync(path.join(projectRoot, relativePath)));
72
+
73
+ return {
74
+ hasLegacyLayout: detected.length > 0,
75
+ legacyPaths: detected,
76
+ };
77
+ }
78
+
63
79
  function hasQuiverInitializationEvidence(projectRoot) {
64
80
  const state = readState(projectRoot);
65
81
  return hasInitializedStateMetadata(state) || hasLegacyQuiverInitializationEvidence(projectRoot);
@@ -129,6 +145,7 @@ module.exports = {
129
145
  hasGeneratedProjectSpec,
130
146
  hasInitializedStateMetadata,
131
147
  hasLegacyQuiverInitializationEvidence,
148
+ inspectLegacyMigrationLayout,
132
149
  hasQuiverInitializationEvidence,
133
150
  readState,
134
151
  statePath,
@@ -0,0 +1,74 @@
1
+ const fs = require('fs');
2
+ const path = require('path');
3
+
4
+ function resolvePackagedTemplateRoot(packageRoot = path.resolve(__dirname, '../../..')) {
5
+ return packageRoot;
6
+ }
7
+
8
+ function resolveExportedTemplateRoot(projectRoot) {
9
+ return path.join(projectRoot, '.quiver', 'templates');
10
+ }
11
+
12
+ function resolveLegacyTemplateRoot(projectRoot) {
13
+ return path.join(projectRoot, 'docs-template');
14
+ }
15
+
16
+ function templateRootExists(templateRoot) {
17
+ return fs.existsSync(path.join(templateRoot, 'docs'))
18
+ && fs.existsSync(path.join(templateRoot, 'specs'))
19
+ && fs.existsSync(path.join(templateRoot, 'package.template.json'));
20
+ }
21
+
22
+ function resolveTemplateRoot(projectRoot, options = {}) {
23
+ const packageRoot = options.packageRoot || resolvePackagedTemplateRoot();
24
+ const candidates = [];
25
+
26
+ if (options.preferExported === true) {
27
+ candidates.push({
28
+ kind: 'exported',
29
+ path: resolveExportedTemplateRoot(projectRoot),
30
+ });
31
+ }
32
+
33
+ candidates.push({
34
+ kind: 'packaged',
35
+ path: resolvePackagedTemplateRoot(packageRoot),
36
+ });
37
+
38
+ candidates.push({
39
+ kind: 'legacy',
40
+ path: resolveLegacyTemplateRoot(projectRoot),
41
+ });
42
+
43
+ for (const candidate of candidates) {
44
+ if (templateRootExists(candidate.path)) {
45
+ return candidate;
46
+ }
47
+ }
48
+
49
+ const searched = candidates.map((candidate) => `${candidate.kind}: ${candidate.path}`).join(', ');
50
+ throw new Error(`create-quiver: missing Quiver templates. Searched ${searched}`);
51
+ }
52
+
53
+ function resolveTemplatePath(projectRoot, relativePath, options = {}) {
54
+ const root = resolveTemplateRoot(projectRoot, options);
55
+ const templatePath = path.join(root.path, relativePath);
56
+
57
+ if (!fs.existsSync(templatePath)) {
58
+ throw new Error(`create-quiver: missing template ${relativePath} in ${root.path}`);
59
+ }
60
+
61
+ return {
62
+ ...root,
63
+ templatePath,
64
+ };
65
+ }
66
+
67
+ module.exports = {
68
+ resolveExportedTemplateRoot,
69
+ resolveLegacyTemplateRoot,
70
+ resolvePackagedTemplateRoot,
71
+ resolveTemplatePath,
72
+ resolveTemplateRoot,
73
+ templateRootExists,
74
+ };