@mstar-harness/omp 3.6.0-alpha.4

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 (280) hide show
  1. package/README.md +63 -0
  2. package/agents/architect.md +35 -0
  3. package/agents/code-reviewer.md +90 -0
  4. package/agents/frontend-dev.md +33 -0
  5. package/agents/fullstack-dev-2.md +33 -0
  6. package/agents/fullstack-dev.md +33 -0
  7. package/agents/ops-engineer.md +33 -0
  8. package/agents/product-manager.md +35 -0
  9. package/agents/project-manager.md +32 -0
  10. package/agents/prompt-engineer.md +33 -0
  11. package/agents/qa-engineer.md +35 -0
  12. package/agents/qc-specialist-2.md +62 -0
  13. package/agents/qc-specialist-3.md +62 -0
  14. package/agents/qc-specialist.md +62 -0
  15. package/agents/writing-specialist.md +35 -0
  16. package/assets/icon.png +0 -0
  17. package/assets/logo-dark.png +0 -0
  18. package/assets/logo-dark.svg +6 -0
  19. package/assets/logo.png +0 -0
  20. package/assets/logo.svg +6 -0
  21. package/commands/amazing-pr-review.md +31 -0
  22. package/commands/codebase-audit.md +40 -0
  23. package/commands/iteration-drive.md +48 -0
  24. package/commands/iteration-loop.md +99 -0
  25. package/commands/iteration-start.md +122 -0
  26. package/dist/hooks/pre/mstar-gates.js +6579 -0
  27. package/dist/tools/mstar_dispatch_validate/index.js +6291 -0
  28. package/dist/tools/mstar_iteration_gate/index.js +6321 -0
  29. package/dist/tools/mstar_lease_verify/index.js +6343 -0
  30. package/dist/tools/mstar_path_resolve/index.js +6297 -0
  31. package/dist/tools/mstar_status_validate/index.js +6402 -0
  32. package/dist/tools/mstar_worktree_check/index.js +6343 -0
  33. package/harness-agents/architect.md +35 -0
  34. package/harness-agents/code-reviewer.md +90 -0
  35. package/harness-agents/frontend-dev.md +33 -0
  36. package/harness-agents/fullstack-dev-2.md +33 -0
  37. package/harness-agents/fullstack-dev.md +33 -0
  38. package/harness-agents/ops-engineer.md +33 -0
  39. package/harness-agents/product-manager.md +35 -0
  40. package/harness-agents/project-manager.md +32 -0
  41. package/harness-agents/prompt-engineer.md +33 -0
  42. package/harness-agents/qa-engineer.md +35 -0
  43. package/harness-agents/qc-specialist-2.md +62 -0
  44. package/harness-agents/qc-specialist-3.md +62 -0
  45. package/harness-agents/qc-specialist.md +62 -0
  46. package/harness-agents/writing-specialist.md +35 -0
  47. package/harness-commands/amazing-pr-review.md +31 -0
  48. package/harness-commands/codebase-audit.md +40 -0
  49. package/harness-commands/iteration-drive.md +48 -0
  50. package/harness-commands/iteration-loop.md +99 -0
  51. package/harness-commands/iteration-start.md +122 -0
  52. package/harness-skills/grill-me/SKILL.md +10 -0
  53. package/harness-skills/mstar-artifacts/SKILL.md +66 -0
  54. package/harness-skills/mstar-artifacts/references/knowledge-and-designs.md +110 -0
  55. package/harness-skills/mstar-artifacts/references/plan-files-and-reports.md +98 -0
  56. package/harness-skills/mstar-artifacts/references/plan-quality-bar.md +99 -0
  57. package/harness-skills/mstar-artifacts/references/status-and-residuals.md +472 -0
  58. package/harness-skills/mstar-artifacts/templates/README.md +7 -0
  59. package/harness-skills/mstar-artifacts/templates/plan.main.md +54 -0
  60. package/harness-skills/mstar-artifacts/templates/status.empty.json +5 -0
  61. package/harness-skills/mstar-audit/SKILL.md +151 -0
  62. package/harness-skills/mstar-audit/references/audit-playbook.md +175 -0
  63. package/harness-skills/mstar-audit/references/codebase-audit.md +103 -0
  64. package/harness-skills/mstar-audit/references/finding-format.md +69 -0
  65. package/harness-skills/mstar-audit/references/pr-review-seat-evidence.md +28 -0
  66. package/harness-skills/mstar-audit/references/pr-review.md +475 -0
  67. package/harness-skills/mstar-audit/references/security-review.md +219 -0
  68. package/harness-skills/mstar-branch-worktree/SKILL.md +236 -0
  69. package/harness-skills/mstar-branch-worktree/references/parallel-writable-pre-dispatch.md +68 -0
  70. package/harness-skills/mstar-coding-behavior/SKILL.md +167 -0
  71. package/harness-skills/mstar-compound/SKILL.md +109 -0
  72. package/harness-skills/mstar-compound/assets/resolution-template.md +94 -0
  73. package/harness-skills/mstar-compound/references/category-mapping.md +37 -0
  74. package/harness-skills/mstar-compound/references/compound-workflow.md +171 -0
  75. package/harness-skills/mstar-compound/references/concepts-vocabulary.md +44 -0
  76. package/harness-skills/mstar-compound/references/schema.yaml +122 -0
  77. package/harness-skills/mstar-compound-refresh/SKILL.md +154 -0
  78. package/harness-skills/mstar-compound-refresh/references/project-knowledge-bootstrap.md +164 -0
  79. package/harness-skills/mstar-conventions/SKILL.md +215 -0
  80. package/harness-skills/mstar-conventions/references/artifact-storage-paths.md +53 -0
  81. package/harness-skills/mstar-conventions/references/effort-estimation.md +38 -0
  82. package/harness-skills/mstar-conventions/references/harness-bootstrap-and-agents-layering.md +96 -0
  83. package/harness-skills/mstar-design-md/SKILL.md +142 -0
  84. package/harness-skills/mstar-design-md/references/completeness-checklist.md +181 -0
  85. package/harness-skills/mstar-design-md/references/design-md-spec.md +508 -0
  86. package/harness-skills/mstar-design-md/references/vercel-example.md +200 -0
  87. package/harness-skills/mstar-design-md/templates/DESIGN.dark.md.template +354 -0
  88. package/harness-skills/mstar-design-md/templates/DESIGN.md.template +474 -0
  89. package/harness-skills/mstar-dispatch-gates/SKILL.md +134 -0
  90. package/harness-skills/mstar-dispatch-gates/references/leaf-executor-checklist.md +23 -0
  91. package/harness-skills/mstar-engine-legacy/SKILL.md +53 -0
  92. package/harness-skills/mstar-engine-legacy/references/anti-recursion-checklists.md +58 -0
  93. package/harness-skills/mstar-engine-legacy/references/engine-check-boilerplate.md +26 -0
  94. package/harness-skills/mstar-engine-legacy/references/lease-protocol.md +92 -0
  95. package/harness-skills/mstar-engine-legacy/references/qc-seat-n-restatements.md +57 -0
  96. package/harness-skills/mstar-engine-legacy/references/status-field-history.md +186 -0
  97. package/harness-skills/mstar-harness-core/SKILL.md +196 -0
  98. package/harness-skills/mstar-host/SKILL.md +96 -0
  99. package/harness-skills/mstar-host/references/_shared/host-role-binding-core.md +51 -0
  100. package/harness-skills/mstar-host/references/_shared/plan-mode-bridge-core.md +91 -0
  101. package/harness-skills/mstar-host/references/codex.md +61 -0
  102. package/harness-skills/mstar-host/references/cursor-plan-mode-bridge.md +170 -0
  103. package/harness-skills/mstar-host/references/cursor.md +183 -0
  104. package/harness-skills/mstar-host/references/dsh.md +507 -0
  105. package/harness-skills/mstar-host/references/kimi-plan-mode-bridge.md +36 -0
  106. package/harness-skills/mstar-host/references/kimi.md +136 -0
  107. package/harness-skills/mstar-host/references/omp-plan-mode-bridge.md +32 -0
  108. package/harness-skills/mstar-host/references/omp.md +245 -0
  109. package/harness-skills/mstar-host/references/opencode.md +76 -0
  110. package/harness-skills/mstar-host/references/parallel-dispatch.md +68 -0
  111. package/harness-skills/mstar-host/references/zcode-plan-mode-bridge.md +36 -0
  112. package/harness-skills/mstar-host/references/zcode.md +129 -0
  113. package/harness-skills/mstar-iteration/SKILL.md +408 -0
  114. package/harness-skills/mstar-iteration/references/autonomous-direction-lock.md +90 -0
  115. package/harness-skills/mstar-iteration/references/command-shared-invariants.md +62 -0
  116. package/harness-skills/mstar-iteration/references/iteration-artifact-boundaries.md +103 -0
  117. package/harness-skills/mstar-iteration/references/iteration-compass-template.md +142 -0
  118. package/harness-skills/mstar-iteration/references/iteration-corpus-hygiene.md +45 -0
  119. package/harness-skills/mstar-iteration/references/iteration-workspace-readme-template.md +27 -0
  120. package/harness-skills/mstar-iteration/references/phase-2-worktree-lease.md +205 -0
  121. package/harness-skills/mstar-iteration/references/phase-3-iteration-close.md +105 -0
  122. package/harness-skills/mstar-iteration/references/phase-4-5-pr-delivery.md +85 -0
  123. package/harness-skills/mstar-iteration/references/phase5-helper-discovery.md +24 -0
  124. package/harness-skills/mstar-phase-gates/SKILL.md +118 -0
  125. package/harness-skills/mstar-project-governance/SKILL.md +119 -0
  126. package/harness-skills/mstar-review-qc/SKILL.md +76 -0
  127. package/harness-skills/mstar-review-qc/references/review-responsibility-boundaries.md +54 -0
  128. package/harness-skills/mstar-roles/SKILL.md +103 -0
  129. package/harness-skills/mstar-roles/references/_shared/leaf-executor-core.md +65 -0
  130. package/harness-skills/mstar-roles/references/architect.md +109 -0
  131. package/harness-skills/mstar-roles/references/code-reviewer.md +118 -0
  132. package/harness-skills/mstar-roles/references/frontend-dev.md +70 -0
  133. package/harness-skills/mstar-roles/references/fullstack-dev-shared.md +89 -0
  134. package/harness-skills/mstar-roles/references/ops-engineer.md +72 -0
  135. package/harness-skills/mstar-roles/references/product-manager.md +102 -0
  136. package/harness-skills/mstar-roles/references/project-manager/dispatch-and-assignment.md +200 -0
  137. package/harness-skills/mstar-roles/references/project-manager/plan-management.md +59 -0
  138. package/harness-skills/mstar-roles/references/project-manager/qa-trigger-matrix.md +56 -0
  139. package/harness-skills/mstar-roles/references/project-manager/qc-and-residuals.md +99 -0
  140. package/harness-skills/mstar-roles/references/project-manager/routing-and-dev-allocation.md +99 -0
  141. package/harness-skills/mstar-roles/references/project-manager.md +310 -0
  142. package/harness-skills/mstar-roles/references/prompt-engineer.md +65 -0
  143. package/harness-skills/mstar-roles/references/qa-engineer/acceptance-gate.md +62 -0
  144. package/harness-skills/mstar-roles/references/qa-engineer.md +71 -0
  145. package/harness-skills/mstar-roles/references/qc-specialist/deep-review-lenses.md +104 -0
  146. package/harness-skills/mstar-roles/references/qc-specialist/report-template.md +88 -0
  147. package/harness-skills/mstar-roles/references/qc-specialist/reviewer-checklist.md +44 -0
  148. package/harness-skills/mstar-roles/references/qc-specialist/reviewer-workflow.md +57 -0
  149. package/harness-skills/mstar-roles/references/qc-specialist-shared.md +120 -0
  150. package/harness-skills/mstar-roles/references/writing-specialist.md +88 -0
  151. package/harness-skills/mstar-sdd/SKILL.md +137 -0
  152. package/harness-skills/mstar-sdd/references/file-handoffs.md +85 -0
  153. package/harness-skills/mstar-sdd/references/implementer-continuation-prompt.md +44 -0
  154. package/harness-skills/mstar-sdd/references/implementer-prompt.md +56 -0
  155. package/harness-skills/mstar-sdd/references/sticky-implementer-session.md +103 -0
  156. package/harness-skills/mstar-sdd/references/task-reviewer-prompt.md +53 -0
  157. package/harness-skills/mstar-skill-authoring/SKILL.md +182 -0
  158. package/harness-skills/mstar-skill-authoring/references/regression-fixation.md +46 -0
  159. package/harness-skills/mstar-skill-authoring/references/skillsbench-authoring.md +154 -0
  160. package/harness-skills/mstar-strategy/SKILL.md +114 -0
  161. package/harness-skills/pm/SKILL.md +40 -0
  162. package/hooks/pre/mstar-gates.js +6579 -0
  163. package/package.json +45 -0
  164. package/plugin.json +49 -0
  165. package/skills/grill-me/SKILL.md +10 -0
  166. package/skills/mstar-artifacts/SKILL.md +66 -0
  167. package/skills/mstar-artifacts/references/knowledge-and-designs.md +110 -0
  168. package/skills/mstar-artifacts/references/plan-files-and-reports.md +98 -0
  169. package/skills/mstar-artifacts/references/plan-quality-bar.md +99 -0
  170. package/skills/mstar-artifacts/references/status-and-residuals.md +472 -0
  171. package/skills/mstar-artifacts/templates/README.md +7 -0
  172. package/skills/mstar-artifacts/templates/plan.main.md +54 -0
  173. package/skills/mstar-artifacts/templates/status.empty.json +5 -0
  174. package/skills/mstar-audit/SKILL.md +151 -0
  175. package/skills/mstar-audit/references/audit-playbook.md +175 -0
  176. package/skills/mstar-audit/references/codebase-audit.md +103 -0
  177. package/skills/mstar-audit/references/finding-format.md +69 -0
  178. package/skills/mstar-audit/references/pr-review-seat-evidence.md +28 -0
  179. package/skills/mstar-audit/references/pr-review.md +475 -0
  180. package/skills/mstar-audit/references/security-review.md +219 -0
  181. package/skills/mstar-branch-worktree/SKILL.md +236 -0
  182. package/skills/mstar-branch-worktree/references/parallel-writable-pre-dispatch.md +68 -0
  183. package/skills/mstar-coding-behavior/SKILL.md +167 -0
  184. package/skills/mstar-compound/SKILL.md +109 -0
  185. package/skills/mstar-compound/assets/resolution-template.md +94 -0
  186. package/skills/mstar-compound/references/category-mapping.md +37 -0
  187. package/skills/mstar-compound/references/compound-workflow.md +171 -0
  188. package/skills/mstar-compound/references/concepts-vocabulary.md +44 -0
  189. package/skills/mstar-compound/references/schema.yaml +122 -0
  190. package/skills/mstar-compound-refresh/SKILL.md +154 -0
  191. package/skills/mstar-compound-refresh/references/project-knowledge-bootstrap.md +164 -0
  192. package/skills/mstar-conventions/SKILL.md +215 -0
  193. package/skills/mstar-conventions/references/artifact-storage-paths.md +53 -0
  194. package/skills/mstar-conventions/references/effort-estimation.md +38 -0
  195. package/skills/mstar-conventions/references/harness-bootstrap-and-agents-layering.md +96 -0
  196. package/skills/mstar-design-md/SKILL.md +142 -0
  197. package/skills/mstar-design-md/references/completeness-checklist.md +181 -0
  198. package/skills/mstar-design-md/references/design-md-spec.md +508 -0
  199. package/skills/mstar-design-md/references/vercel-example.md +200 -0
  200. package/skills/mstar-design-md/templates/DESIGN.dark.md.template +354 -0
  201. package/skills/mstar-design-md/templates/DESIGN.md.template +474 -0
  202. package/skills/mstar-dispatch-gates/SKILL.md +134 -0
  203. package/skills/mstar-dispatch-gates/references/leaf-executor-checklist.md +23 -0
  204. package/skills/mstar-engine-legacy/SKILL.md +53 -0
  205. package/skills/mstar-engine-legacy/references/anti-recursion-checklists.md +58 -0
  206. package/skills/mstar-engine-legacy/references/engine-check-boilerplate.md +26 -0
  207. package/skills/mstar-engine-legacy/references/lease-protocol.md +92 -0
  208. package/skills/mstar-engine-legacy/references/qc-seat-n-restatements.md +57 -0
  209. package/skills/mstar-engine-legacy/references/status-field-history.md +186 -0
  210. package/skills/mstar-harness-core/SKILL.md +196 -0
  211. package/skills/mstar-host/SKILL.md +96 -0
  212. package/skills/mstar-host/references/_shared/host-role-binding-core.md +51 -0
  213. package/skills/mstar-host/references/_shared/plan-mode-bridge-core.md +91 -0
  214. package/skills/mstar-host/references/codex.md +61 -0
  215. package/skills/mstar-host/references/cursor-plan-mode-bridge.md +170 -0
  216. package/skills/mstar-host/references/cursor.md +183 -0
  217. package/skills/mstar-host/references/dsh.md +507 -0
  218. package/skills/mstar-host/references/kimi-plan-mode-bridge.md +36 -0
  219. package/skills/mstar-host/references/kimi.md +136 -0
  220. package/skills/mstar-host/references/omp-plan-mode-bridge.md +32 -0
  221. package/skills/mstar-host/references/omp.md +245 -0
  222. package/skills/mstar-host/references/opencode.md +76 -0
  223. package/skills/mstar-host/references/parallel-dispatch.md +68 -0
  224. package/skills/mstar-host/references/zcode-plan-mode-bridge.md +36 -0
  225. package/skills/mstar-host/references/zcode.md +129 -0
  226. package/skills/mstar-iteration/SKILL.md +408 -0
  227. package/skills/mstar-iteration/references/autonomous-direction-lock.md +90 -0
  228. package/skills/mstar-iteration/references/command-shared-invariants.md +62 -0
  229. package/skills/mstar-iteration/references/iteration-artifact-boundaries.md +103 -0
  230. package/skills/mstar-iteration/references/iteration-compass-template.md +142 -0
  231. package/skills/mstar-iteration/references/iteration-corpus-hygiene.md +45 -0
  232. package/skills/mstar-iteration/references/iteration-workspace-readme-template.md +27 -0
  233. package/skills/mstar-iteration/references/phase-2-worktree-lease.md +205 -0
  234. package/skills/mstar-iteration/references/phase-3-iteration-close.md +105 -0
  235. package/skills/mstar-iteration/references/phase-4-5-pr-delivery.md +85 -0
  236. package/skills/mstar-iteration/references/phase5-helper-discovery.md +24 -0
  237. package/skills/mstar-phase-gates/SKILL.md +118 -0
  238. package/skills/mstar-project-governance/SKILL.md +119 -0
  239. package/skills/mstar-review-qc/SKILL.md +76 -0
  240. package/skills/mstar-review-qc/references/review-responsibility-boundaries.md +54 -0
  241. package/skills/mstar-roles/SKILL.md +103 -0
  242. package/skills/mstar-roles/references/_shared/leaf-executor-core.md +65 -0
  243. package/skills/mstar-roles/references/architect.md +109 -0
  244. package/skills/mstar-roles/references/code-reviewer.md +118 -0
  245. package/skills/mstar-roles/references/frontend-dev.md +70 -0
  246. package/skills/mstar-roles/references/fullstack-dev-shared.md +89 -0
  247. package/skills/mstar-roles/references/ops-engineer.md +72 -0
  248. package/skills/mstar-roles/references/product-manager.md +102 -0
  249. package/skills/mstar-roles/references/project-manager/dispatch-and-assignment.md +200 -0
  250. package/skills/mstar-roles/references/project-manager/plan-management.md +59 -0
  251. package/skills/mstar-roles/references/project-manager/qa-trigger-matrix.md +56 -0
  252. package/skills/mstar-roles/references/project-manager/qc-and-residuals.md +99 -0
  253. package/skills/mstar-roles/references/project-manager/routing-and-dev-allocation.md +99 -0
  254. package/skills/mstar-roles/references/project-manager.md +310 -0
  255. package/skills/mstar-roles/references/prompt-engineer.md +65 -0
  256. package/skills/mstar-roles/references/qa-engineer/acceptance-gate.md +62 -0
  257. package/skills/mstar-roles/references/qa-engineer.md +71 -0
  258. package/skills/mstar-roles/references/qc-specialist/deep-review-lenses.md +104 -0
  259. package/skills/mstar-roles/references/qc-specialist/report-template.md +88 -0
  260. package/skills/mstar-roles/references/qc-specialist/reviewer-checklist.md +44 -0
  261. package/skills/mstar-roles/references/qc-specialist/reviewer-workflow.md +57 -0
  262. package/skills/mstar-roles/references/qc-specialist-shared.md +120 -0
  263. package/skills/mstar-roles/references/writing-specialist.md +88 -0
  264. package/skills/mstar-sdd/SKILL.md +137 -0
  265. package/skills/mstar-sdd/references/file-handoffs.md +85 -0
  266. package/skills/mstar-sdd/references/implementer-continuation-prompt.md +44 -0
  267. package/skills/mstar-sdd/references/implementer-prompt.md +56 -0
  268. package/skills/mstar-sdd/references/sticky-implementer-session.md +103 -0
  269. package/skills/mstar-sdd/references/task-reviewer-prompt.md +53 -0
  270. package/skills/mstar-skill-authoring/SKILL.md +182 -0
  271. package/skills/mstar-skill-authoring/references/regression-fixation.md +46 -0
  272. package/skills/mstar-skill-authoring/references/skillsbench-authoring.md +154 -0
  273. package/skills/mstar-strategy/SKILL.md +114 -0
  274. package/skills/pm/SKILL.md +40 -0
  275. package/tools/mstar_dispatch_validate.js +6291 -0
  276. package/tools/mstar_iteration_gate.js +6321 -0
  277. package/tools/mstar_lease_verify.js +6343 -0
  278. package/tools/mstar_path_resolve.js +6297 -0
  279. package/tools/mstar_status_validate.js +6402 -0
  280. package/tools/mstar_worktree_check.js +6343 -0
@@ -0,0 +1,98 @@
1
+ # Plan 文件与 Review Bundle 留档(Morning Star)
2
+
3
+ > **Load order(与其它 `mstar-*` skill 一致)**:依赖本 reference 排 review bundle / QC 波次前,须已 Read **`mstar-harness-core`** skill(SKILL.md;多 worktree 与 QC 单一 `HEAD` 见 **`mstar-branch-worktree`**)。冲突以 **`mstar-harness-core`** 为准。
4
+
5
+ ## Plan 文件(`{PLAN_DIR}/<name>.md`)
6
+
7
+ 每个 plan 的详细内容(任务清单、决策、Sign-off)。
8
+
9
+ **命名(推荐)**:`<plan-id>-<plan-name>.md`(例:`01-data-infrastructure.md`)。snapshot plan 行的 `file` 字段填相对仓库根或 `{PLAN_DIR}` 下的实际路径。
10
+
11
+ ## Review bundle(`{SDD_DIR}/review/`)
12
+
13
+ QC/QA 原始过程报告默认是 **ephemeral review bundle**,置于 `{SDD_DIR}/review/`(即 `{HARNESS_DIR}/sdd/<plan-id>/review/`)。该目录随 `{SDD_DIR}` gitignored,不作为长期 git 审计链。
14
+
15
+ **QC basename rule**:`{SDD_DIR}` 已含 `<plan-id>` — **do not** repeat it in report filenames. Put `plan_id` in YAML frontmatter only.
16
+
17
+ | 类型 | 文件名(相对 `{SDD_DIR}/review/`) |
18
+ |------|--------|
19
+ | QC 三审报告(**SDD 默认** `Execution mode: sdd`) | `qc1.md`、`qc2.md`、`qc3.md` |
20
+ | QC 单席报告(**`inline` / hotfix 例外**) | `qc.md` |
21
+ | QC 汇总结论(tri 模式) | `qc-consolidated.md` |
22
+ | QA 验收报告(`QA gate: mandatory`) | `qa.md`(或 Assignment 指定的同目录 basename) |
23
+
24
+
25
+ ## SDD 运行时(不入 reports)
26
+
27
+ Per-task briefs, implementer reports, review diffs, branch review packages, and QC/QA bundle files live under **`{SDD_DIR}`** (`mstar-conventions`). Gitignored. Main plan may index `{SDD_DIR}` / `{SDD_DIR}/review/` paths only — do not paste SDD bodies or raw QC/QA reports into plan markdown.
28
+
29
+ Plan template with Global Constraints / Interfaces → **`templates/plan.main.md`**.
30
+
31
+ ## QC 模式(L3 plan 级)
32
+
33
+ 职责分层 L1–L4 → **`mstar-review-qc/references/review-responsibility-boundaries.md`**。bundle basename 见上表;触发时机与 re-review 波次见下节 **§ QC 三审触发时机**。
34
+
35
+ ## Durable summaries(主 plan / status)
36
+
37
+ Raw bundle files may disappear after the working context is gone. Before Done, PM must preserve the durable decision surface:
38
+
39
+ - Main plan `## Review Gate Summary`:
40
+ - `Decision`: `Approve` | `Approve with residuals` | `Request Changes` | `Needs Discussion`
41
+ - `Review range / Diff basis`
42
+ - `Review bundle`: `{SDD_DIR}/review/`
43
+ - `QC inputs`: `qc1.md` / `qc2.md` / `qc3.md` or `qc.md`
44
+ - `Blocking result`: fixed / none / deferred with reason
45
+ - `Residual findings`: R# ids + short titles + owner/target
46
+ - Main plan `## QA Gate Summary` when QA applies:
47
+ - `QA gate` / `QA mode`
48
+ - evidence reused vs newly run checks
49
+ - related R# closure recommendations
50
+ - `{PROJECT_DIR}/<id>/residuals.json` (default `{HARNESS_DIR}/projects/<id>/`): open R# machine SSOT — `entries[<plan-id>]`.
51
+
52
+ The durable summary is not a paste of raw reports. It is a small gate record sufficient for handoff after `{SDD_DIR}` is unavailable.
53
+
54
+ ## Residual findings(R#):权威在哪、和主 plan 谁先谁后?
55
+
56
+ - **Open 条目的单一事实来源(SSOT)**是 **`{PROJECT_DIR}/<id>/residuals.json`**(默认 `{HARNESS_DIR}/projects/<id>/`;无项目流程用 `_default`)的 **`entries[<plan-id>]`**(canonical 见 `mstar-artifacts` **SKILL.md** 开篇;字段见 `mstar-artifacts/references/status-and-residuals.md`)。**同一工作副本内**的会话 handoff、关闭流程**以该数组为准**(本地 SSOT,默认 gitignored);**跨 clone** 须持久的 residual 须提升入 tracked `{KNOWLEDGE_DIR}/` / `{SPECS_DIR}/` 等(见 `mstar-conventions`「Git 跟踪策略」)。
57
+ - **推荐操作顺序**(避免 plan 与 JSON 两套 ID 漂移):
58
+ 1. `project-manager` 读完 review bundle 并完成「QC 三审轻量汇总」:对 finding **去重合并**,为每条待跟踪项分配**稳定 `id`**(如 `R1`、`R2`,全 plan 内唯一)。
59
+ 2. **立即**将上述条目写入 register **`entries[<plan-id>]`**(含 `source` 指向 reviewer seat + bundle basename + finding id + review range,便于回溯;`source_plan` = plan id,`registered_at` = 当日);v1 根级 `residual_findings` 仅 legacy 只读,**勿**双写。
60
+ 3. **可选**:在主 plan 中增加 **「Residual findings(索引)」** 小节,**仅复述** `id` + 短标题 + 决策摘要,并写明「**权威列表见** `projects/<id>/residuals.json` `entries[<plan-id>]`(见 `mstar-conventions` **SKILL.md** 开篇)」。**不要**只在主 plan 里「发明」R# 而不写回 SSOT。
61
+ - **不要**反过来把主 plan 当作唯一登记处:若仅更新 plan、register 未同步,下一任 agent **无法**依赖 SSOT 继承债务状态。
62
+
63
+ ## QC 三审触发时机(单 plan · 多 batch)
64
+
65
+ - **默认(SDD)**:同一 **`plan_id`** 下,**plan QC tri-review**(`qc-specialist` ×3 → `{SDD_DIR}/review/qc1.md`…`qc3.md` + `qc-consolidated.md`)**仅在** dev team 按该 plan 约定范围全部交付、且 **L2 task reviewers** 均已通过后执行 **一次**。**不要**在每个中间 batch 跑完整三审。
66
+ - **单席例外**:`Execution mode: inline` / hotfix → 交付完成后 **一次** `qc.md`(`QC mode: single`)。
67
+ - **batch 之间**:依赖实现方按 **`mstar-coding-behavior`** 提供完成证据、主 plan 任务勾选与 PM 协调;需要书面中间意见时,用对话、主 plan 批注或**非三审**的定向检查(如单审、架构 review),**不**默认等同「又一轮完整三审」。
68
+ - **After `Request Changes` (default — targeted re-review)**:PM maps each **blocking** finding to the QC seat that raised it (`source` on R#, consolidated table, or the originating `qcN.md` / `F-###`). Dispatch **only** those reviewers (`QC re-review: targeted — reviewers: qc-specialist, qc-specialist-2, …`). Each re-reviewing QC **updates the same** bundle file (`qc1.md` / `qc2.md` / `qc3.md`) in place (add `## Revalidation`, refresh verdict / `generated_at`); **do not** add `qc1-rev2.md` siblings for targeted re-review. PM **updates the same** `qc-consolidated.md` and durable plan summary.
69
+ - **Full tri re-review (exception)**:Only when Assignment states **`QC re-review: full tri-review`**. Run **three** parallel reviews again; use **new bundle basenames** (`qc1-rev2.md` … `qc3-rev2.md`, `qc-consolidated-rev2.md`) so wave-1 files stay distinct; PM states **active wave** in consolidated decision and durable plan summary. See `mstar-review-qc` · `mstar-dispatch-gates`.
70
+ - **显式例外**:仅当用户与 PM 书面同意**中间门禁**时,在 Assignment 写清 **`QC gate: incremental — <scope>`**(或等价),并仍须保证该次三审的 **`plan_id` + `Review range` / `Diff basis`** 三份一致;**优先**用 `{SDD_DIR}/review/<scope>/` 子目录,避免与终局 `qc1..3.md` 混名。
71
+ - **同仓多 worktree 并行 dev**:**推荐**在排各 batch / 各轨 worktree 前确立 **plan 集成分支** 与各轨 topic 线及 **merge 靶**(见 `mstar-branch-worktree` **「推荐默认编排:先建 plan 集成分支,再挂各 worktree」**)。**多 `plan_id` 同属一条 `primary_spec`(Spec 文档)时**:该「集成分支」在计划语义上即 **Spec 集成分支**;各 Plan 的 topic 分支 **merge 回 Spec 集成分支**,**全部 Plans 完成后** 向显式 `target_branch` **走 PR**,见 `mstar-conventions` SKILL.md **「Spec 驱动的分支模型」**。终局(或增量)三审派单前,PM 仍须满足 **单一待审 `Working branch` / `HEAD`** 或已按上条 **拆 scope**;**不得**假设「整 plan 一次三审」可只靠某一个开发 worktree 路径覆盖未合并的其他并行轨。
72
+
73
+ ### 多 `plan_id` 同时 `InReview`(PM 编排)
74
+
75
+ - **流程**:实现完成 → 该 **`plan_id`** 进入 **`InReview`** → **QC 三审(仅针对该 plan 的 `Review range`)** → PM consolidated → **QA** → **`Done`**。**禁止**在多个 `plan_id` 已 `InReview` 的情况下,只推进新实现、不派 QC,或把多个 plan 的变更**伪装成**一套三审字段(单一 `plan_id` / 单一 diff 范围覆盖多 plan)。
76
+ - **并行 vs 串行**:不同 `plan_id` **相互独立**时,可 **并行**派发多组三审(每组各自的 Assignment 与 `{SDD_DIR}/review/`);若 PM 选择串行,须在 Status Update 写明顺序——**每组仍须完整三审 + QA**,不是「一个大 QC」混审。
77
+ - **读 skill**:书写或派发 QC 相关 Assignment 前,PM **必须** Read **`mstar-review-qc`**(编排与 residual);leaf `qc-specialist*` → **`mstar-roles/references/qc-specialist/`**。见 `mstar-conventions` SKILL.md **QC pre-dispatch gate**。
78
+
79
+ **QC 落盘与宿主权限**:`qc-specialist` / `qc-specialist-2` / `qc-specialist-3` 在支持路径白名单的宿主上(如 OpenCode 的 **`permission.edit`**),默认 **仅可** Write/Edit Assignment 指定的 **`{SDD_DIR}/review/`** 下 **`.md`**。全局 agent 提示词应允许 `.mstar/sdd/**`、`.agents/sdd/**` 及 `.worktrees/**`。报告文件**必须**以 YAML **frontmatter** 开头(键见各 QC agent 提示词)。
80
+
81
+ **QC 报告与 Git**:默认 raw QC/QA bundle **不**执行 `git add` / `git commit`。PM 将 durable gate summary 写入主 plan(本地会话 SSOT;默认 gitignored)并在当轮更新 project register 的 open residuals(本地 SSOT,默认 gitignored)。**跨 clone 须持久的** residual 或决策须提升入 tracked `{KNOWLEDGE_DIR}/` / `{SPECS_DIR}/` 或 `{HARNESS_DIR}/AGENTS.md`(见 `mstar-conventions`「Git 跟踪策略」)— **勿**默认 `git add` `status.json` / `workflows/` / `projects/` / `plans/`。若项目显式 opt-in 跟踪审计报告,在 Assignment 写 `Review archive mode: tracked reports` 并使用项目 allow rules。
82
+
83
+ ## 主 plan 内任务清单(Markdown checkbox)
84
+
85
+ - **谁应更新**:`fullstack-dev` / `frontend-dev` / `fullstack-dev-2`、`qa-engineer`、`ops-engineer`、`architect`、`product-manager` 在**完成本人 Assignment 范围内的工作后**,须在主 plan(`<plan-id>-<plan-name>.md`)中把**对应条目**的 Markdown 任务标记为已完成(常见:`- [ ]` → `- [x]`;若项目用其它清单记号,保持同文件内一致)。与 Completion Report **并列**,作为跨会话可核对的**落盘痕迹**。
86
+ - **范围**:**只勾选与当前任务直接对应、且已由本角色交付证据支撑的条目**;不得代为勾选他人负责或未完工项。若正文用分段、Owner 或角色标签区分任务,以 Assignment 与文内约定为准。
87
+ - **与 snapshot / frontmatter 的关系**:勾选任务**不**等于整条计划收口。snapshot `plans[].status` 及主 plan frontmatter 的 **`Done`** 仍**仅** `project-manager` / `qa-engineer`(见「状态更新权限」)。`architect` / `product-manager` **不得**擅自将整条计划标为 `Done`;是否将 snapshot 推进为 `InReview` 等仍按下文「状态更新权限」与 Assignment。
88
+ - **`qc-specialist*`**:**不得**修改主 plan(宿主仅允许 Assignment 指定的 review bundle `.md`);审查结论落在 `{SDD_DIR}/review/` 内。若主 plan 需新增或勾选与审查相关的条目,由 `project-manager` 或 Assignment 明确授权的角色据报告回写。
89
+ - **只读角色**:不直接改主 plan;将建议交给 `project-manager` 代为更新清单。
90
+
91
+ Plan 正文与 snapshot 行必须保持一致;不一致时以 snapshot `plans[].status` 为准并尽快纠正正文或登记 notes(`workflows/<id>/notes.jsonl`)。
92
+
93
+ ## Done 标记方式
94
+
95
+ 1. **Frontmatter**(首选):添加 `status: Done` 和可选的 `done_at: YYYY-MM-DD`。
96
+ 2. **文件名**(备选):重命名为 `DONE__<name>.md` 或 `<name>.done.md`。
97
+
98
+ 同时更新 snapshot 对应 plan 行(`workflows/<id>/snapshot.json` → `plans[]`)与根 `status.json` `workflows[]` 登记。
@@ -0,0 +1,99 @@
1
+ # Plan Quality Bar
2
+
3
+ The standard every implementation plan must meet before it is locked and dispatched. Applies to `{PLAN_DIR}` main plans, SDD task-briefs derived from them, and audit-generated plans. Extends the Plan 质量门 in **`mstar-phase-gates`** and the `plan.main.md` template.
4
+
5
+ ## Core principle: write for a zero-context executor
6
+
7
+ SDD implementers start with a fresh session — they have not seen the Prepare conversation, the spec, or other tasks. Audit plans may be executed sessions or days later by a different model. If a plan references "the pattern discussed above" or "as agreed in clarify", it is broken.
8
+
9
+ The plan is the spec. Everything the executor needs must be in the file or reachable from a file path it names.
10
+
11
+ ## Quality checklist
12
+
13
+ Before a plan is locked, verify every item:
14
+
15
+ ### 1. Self-contained context
16
+
17
+ - Every task names **exact file paths** (create / modify / test), not "the relevant module".
18
+ - **Current-state excerpts** — when a task modifies existing code, include the code as it exists today (short, with `file:line` markers), enough that the executor can confirm it is looking at the right thing.
19
+ - **Conventions to follow** — name the repo pattern (error handling, naming, layering) and point to one exemplar file: "Error handling follows the Result pattern — see `src/lib/result.ts` and its use in `src/users/api.ts:40-60`. Match it."
20
+ - **Interfaces** — consumed and produced signatures are listed verbatim, not paraphrased.
21
+
22
+ ### 2. Verification gates
23
+
24
+ Every step ends with a **command and its expected result**, not a judgment call.
25
+
26
+ | Pattern | Weak (do not use) | Strong (required) |
27
+ |---------|-------------------|-------------------|
28
+ | Test step | "run the tests" | `pnpm test -- orders` → all pass, including 2 new tests |
29
+ | Typecheck | "make sure it compiles" | `pnpm typecheck` → exit 0, no errors |
30
+ | Removal | "clean up the old code" | `grep -rn "oldPattern" src/` → no matches |
31
+
32
+ The executor should never have to *judge* whether a step succeeded — it runs a command and compares output.
33
+
34
+ ### 3. Hard boundaries
35
+
36
+ Each task lists:
37
+
38
+ - **In scope** — the only files the executor should modify.
39
+ - **Out of scope** — files that look related but must not be touched, with a one-line reason ("deprecated path, scheduled for deletion").
40
+
41
+ ### 4. STOP conditions
42
+
43
+ Plan-specific escape hatches — not boilerplate. Name the risks particular to this work:
44
+
45
+ - "If `config.ts` no longer exports `getDb`, STOP — the migration in plan 003 may have landed first."
46
+ - "If the test in step 2 fails for a reason other than the missing import, STOP — the assumption that `User.email` is non-nullable may be false."
47
+
48
+ The executor stops and reports instead of improvising. This is what lets a weaker model execute safely.
49
+
50
+ ### 5. Drift check
51
+
52
+ Stamp the commit the plan was written against. Before execution, the executor (or PM) runs:
53
+
54
+ ```
55
+ git diff --stat <planned-at-sha>..HEAD -- <in-scope-paths>
56
+ ```
57
+
58
+ If any in-scope file changed, the executor compares the plan's "current state" excerpts against live code before proceeding. On mismatch → STOP condition.
59
+
60
+ In SDD, this maps to the `BASE_SHA` recorded before Task 1.
61
+
62
+ ### 6. Done criteria (machine-checkable)
63
+
64
+ ALL must hold — commands and expected results, not prose:
65
+
66
+ ```markdown
67
+ ## Done criteria
68
+
69
+ - [ ] `pnpm typecheck` exits 0
70
+ - [ ] `pnpm test` exits 0; new tests for <X> exist and pass
71
+ - [ ] `grep -rn "<old-pattern>" src/` returns no matches
72
+ - [ ] No files outside the in-scope list are modified (`git status`)
73
+ ```
74
+
75
+ "Works correctly" is not a done criterion.
76
+
77
+ ## Relationship to existing plan elements
78
+
79
+ | This quality bar | Existing mstar element |
80
+ |------------------|----------------------|
81
+ | Self-contained context | `plan.main.md` Global Constraints + per-task Files/Interfaces |
82
+ | Verification gates | `plan.main.md` per-step "Run: `cmd`" lines |
83
+ | Hard boundaries | `plan.main.md` per-task Files (Create/Modify) — extended with explicit Out-of-scope |
84
+ | STOP conditions | New — not previously formalized |
85
+ | Drift check | SDD `BASE_SHA` — generalized to all plans |
86
+ | Done criteria | `plan.main.md` per-step checkboxes — elevated to machine-checkable |
87
+
88
+ ## When to apply
89
+
90
+ | Plan source | Applies |
91
+ |-------------|---------|
92
+ | PM/architect Prepare | Full bar before `plan(locked)` |
93
+ | SDD task-brief (extracted from plan) | Inherits from plan; `mstar sdd task-brief` carries excerpts forward |
94
+ | Audit-generated plan (`mstar-audit`) | Full bar — audit plans are the most context-isolated |
95
+ | Hotfix (`inline`) | Relaxed — see `mstar-phase-gates` hotfix exception |
96
+
97
+ ## Attribution
98
+
99
+ The self-containment, verification-gate, STOP-condition, and drift-check concepts are adapted from the [improve](https://github.com/shadcn/improve) skill (MIT, © shadcn), integrated into Morning Star's plan-artifact conventions.