coding-agent-harness 1.0.8 → 1.1.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 (232) hide show
  1. package/CHANGELOG.md +10 -0
  2. package/CONTRIBUTING.md +8 -4
  3. package/README.md +12 -2
  4. package/README.zh-CN.md +10 -2
  5. package/SKILL.md +14 -3
  6. package/dist/build-dist.mjs +19 -6
  7. package/dist/check-dist-observation.mjs +57 -29
  8. package/dist/check-harness.mjs +0 -1
  9. package/dist/check-import-graph.mjs +44 -27
  10. package/dist/check-lite-forbidden-surfaces.mjs +121 -0
  11. package/dist/check-no-ts-nocheck.mjs +7 -7
  12. package/dist/check-runtime-emit.mjs +10 -3
  13. package/dist/check-type-boundaries.mjs +51 -9
  14. package/dist/commands/dashboard-command.mjs +52 -14
  15. package/dist/commands/migration-command.mjs +18 -8
  16. package/dist/commands/module-command.mjs +142 -0
  17. package/dist/commands/preset-command.mjs +51 -12
  18. package/dist/commands/registry.mjs +483 -0
  19. package/dist/commands/task-command.mjs +109 -52
  20. package/dist/harness.mjs +6 -304
  21. package/dist/lib/capability-registry.mjs +229 -53
  22. package/dist/lib/check-module-parallel.mjs +1 -6
  23. package/dist/lib/check-profiles.mjs +39 -46
  24. package/dist/lib/check-task-contracts.mjs +6 -4
  25. package/dist/lib/command-registry.mjs +248 -0
  26. package/dist/lib/core-shared.mjs +78 -3
  27. package/dist/lib/dashboard-data.mjs +203 -22
  28. package/dist/lib/dashboard-workbench.mjs +245 -21
  29. package/dist/lib/dashboard-writer.mjs +4 -1
  30. package/dist/lib/git-status-summary.mjs +0 -1
  31. package/dist/lib/governance-index-generator.mjs +7 -5
  32. package/dist/lib/governance-sync.mjs +46 -121
  33. package/dist/lib/governance-table-boundary.mjs +1 -14
  34. package/dist/lib/harness-core.mjs +4 -1
  35. package/dist/lib/harness-paths.mjs +115 -1
  36. package/dist/lib/impact-classifier.mjs +420 -0
  37. package/dist/lib/lesson-maintenance.mjs +1 -2
  38. package/dist/lib/markdown-utils.mjs +50 -1
  39. package/dist/lib/migration-planner.mjs +31 -16
  40. package/dist/lib/migration-support.mjs +5 -4
  41. package/dist/lib/module-registry.mjs +296 -0
  42. package/dist/lib/preset-audit-contracts.mjs +24 -1
  43. package/dist/lib/preset-engine.mjs +67 -29
  44. package/dist/lib/preset-registry.mjs +361 -71
  45. package/dist/lib/preset-runner.mjs +292 -26
  46. package/dist/lib/review-confirm-git-gate.mjs +73 -19
  47. package/dist/lib/status-builder.mjs +23 -8
  48. package/dist/lib/structure-migration.mjs +6 -4
  49. package/dist/lib/subagent-authorization-audit.mjs +8 -2
  50. package/dist/lib/task-archive-eligibility.mjs +65 -0
  51. package/dist/lib/task-audit-metadata.mjs +25 -11
  52. package/dist/lib/task-audit-migration.mjs +21 -14
  53. package/dist/lib/task-discovery-contract.mjs +32 -0
  54. package/dist/lib/task-index.mjs +3 -2
  55. package/dist/lib/task-lesson-candidates.mjs +1 -2
  56. package/dist/lib/task-lesson-sedimentation.mjs +310 -9
  57. package/dist/lib/task-lifecycle/create-task-helpers.mjs +6 -3
  58. package/dist/lib/task-lifecycle/phase-sync.mjs +0 -1
  59. package/dist/lib/task-lifecycle/preset-interop.mjs +16 -0
  60. package/dist/lib/task-lifecycle/review-confirm.mjs +34 -2
  61. package/dist/lib/task-lifecycle/review-gates.mjs +12 -5
  62. package/dist/lib/task-lifecycle/review-submission.mjs +1 -2
  63. package/dist/lib/task-lifecycle/scaffold-provenance.mjs +0 -1
  64. package/dist/lib/task-lifecycle/template-files.mjs +2 -5
  65. package/dist/lib/task-lifecycle.mjs +116 -160
  66. package/dist/lib/task-metadata.mjs +10 -5
  67. package/dist/lib/task-preset-contract-drift.mjs +45 -0
  68. package/dist/lib/task-repository.mjs +192 -0
  69. package/dist/lib/task-review-model.mjs +36 -17
  70. package/dist/lib/task-scanner.mjs +74 -23
  71. package/dist/lib/task-template-materials.mjs +131 -0
  72. package/dist/lib/task-tombstone-commands.mjs +186 -29
  73. package/dist/lib/types/check-profiles.js +1 -0
  74. package/dist/lib/types/impact.js +1 -0
  75. package/dist/lib/types/preset.js +1 -0
  76. package/dist/lib/types/task-lifecycle.js +1 -0
  77. package/dist/lib/types/task-scanner.js +1 -0
  78. package/dist/postinstall.mjs +2 -2
  79. package/dist/run-built-tests.mjs +10 -3
  80. package/docs-release/README.md +1 -0
  81. package/docs-release/architecture/document-contract-kernel/README.md +150 -0
  82. package/docs-release/architecture/document-contract-kernel/products/full-skill-overlay.md +29 -0
  83. package/docs-release/architecture/document-contract-kernel/products/lite-forbidden-surfaces.txt +26 -0
  84. package/docs-release/architecture/document-contract-kernel/products/lite-skill-overlay.md +37 -0
  85. package/docs-release/architecture/overview.md +2 -2
  86. package/docs-release/architecture/overview.zh-CN.md +2 -2
  87. package/docs-release/architecture/system-explainer/01-system-overview.md +11 -7
  88. package/docs-release/architecture/system-explainer/02-module-dependency.md +4 -4
  89. package/docs-release/architecture/system-explainer/03-task-lifecycle.md +17 -12
  90. package/docs-release/architecture/system-explainer/05-data-flow.md +6 -6
  91. package/docs-release/architecture/system-explainer/06-preset-and-migration.md +2 -2
  92. package/docs-release/architecture/system-explainer/README.md +1 -1
  93. package/docs-release/architecture/system-explainer/en-US/01-system-overview.md +12 -8
  94. package/docs-release/architecture/system-explainer/en-US/02-module-dependency.md +5 -5
  95. package/docs-release/architecture/system-explainer/en-US/03-task-lifecycle.md +19 -11
  96. package/docs-release/architecture/system-explainer/en-US/05-data-flow.md +5 -5
  97. package/docs-release/architecture/system-explainer/en-US/06-preset-and-migration.md +2 -2
  98. package/docs-release/architecture/system-explainer/en-US/README.md +1 -1
  99. package/docs-release/guides/agent-installation.en-US.md +4 -6
  100. package/docs-release/guides/agent-installation.md +11 -8
  101. package/docs-release/guides/contributing.md +10 -3
  102. package/docs-release/guides/contributing.zh-CN.md +10 -3
  103. package/docs-release/guides/legacy-migration-agent-prompt.md +1 -1
  104. package/docs-release/guides/legacy-migration-agent-prompt.zh-CN.md +1 -1
  105. package/docs-release/guides/migration-playbook.en-US.md +9 -6
  106. package/docs-release/guides/migration-playbook.md +9 -6
  107. package/docs-release/guides/preset-development.md +68 -2
  108. package/docs-release/guides/task-state-machine.en-US.md +8 -8
  109. package/docs-release/guides/task-state-machine.md +7 -7
  110. package/docs-release/guides/typescript-runtime-migration-closeout.md +17 -13
  111. package/package.json +16 -12
  112. package/postinstall.mjs +37 -0
  113. package/presets/legacy-migration/preset.yaml +5 -5
  114. package/presets/legacy-migration/templates/execution_strategy.append.md +1 -1
  115. package/presets/lesson-sedimentation/preset.yaml +3 -3
  116. package/presets/module/preset.yaml +2 -2
  117. package/presets/module/templates/execution_strategy.append.md +1 -1
  118. package/presets/module/templates/task_plan.append.md +3 -3
  119. package/presets/release-closeout/checks/check-release-package.mjs +6 -1
  120. package/presets/release-closeout/preset.yaml +9 -9
  121. package/presets/release-closeout/scripts/generate-release-package.mjs +387 -25
  122. package/presets/release-closeout/templates/task_plan.append.md +5 -5
  123. package/presets/standard-task/preset.yaml +2 -2
  124. package/references/agents-md-pattern.md +23 -17
  125. package/references/lessons-governance.md +2 -2
  126. package/references/module-parallel-standard.md +3 -6
  127. package/references/ssot-governance.md +2 -2
  128. package/references/taskr-gap-analysis.md +3 -3
  129. package/run-dist.mjs +34 -0
  130. package/skills/preset-creator/SKILL.md +40 -8
  131. package/skills/preset-creator/references/complex-task-skeleton/brief.md +32 -8
  132. package/skills/preset-creator/references/preset-package-skeleton.md +15 -5
  133. package/skills/preset-creator/references/structure-aware-paths.md +112 -0
  134. package/templates/AGENTS.md.template +28 -26
  135. package/templates/architecture/README.md +2 -2
  136. package/templates/architecture/service-catalog.md +2 -2
  137. package/templates/architecture/services/service-template.md +1 -1
  138. package/templates/dashboard/assets/app-src/00-state.js +5 -1
  139. package/templates/dashboard/assets/app-src/10-router.js +7 -0
  140. package/templates/dashboard/assets/app-src/20-overview.js +8 -8
  141. package/templates/dashboard/assets/app-src/30-tasks.js +132 -40
  142. package/templates/dashboard/assets/app-src/32-task-swimlane.js +314 -0
  143. package/templates/dashboard/assets/app-src/35-task-detail.js +35 -5
  144. package/templates/dashboard/assets/app-src/40-modules.js +257 -41
  145. package/templates/dashboard/assets/app-src/45-review.js +127 -1
  146. package/templates/dashboard/assets/app-src/90-bindings.js +185 -2
  147. package/templates/dashboard/assets/app.css +928 -53
  148. package/templates/dashboard/assets/app.css.manifest.json +2 -0
  149. package/templates/dashboard/assets/app.js +1071 -98
  150. package/templates/dashboard/assets/app.manifest.json +1 -0
  151. package/templates/dashboard/assets/css-src/00-foundation.css +12 -6
  152. package/templates/dashboard/assets/css-src/10-panels-flow.css +2 -2
  153. package/templates/dashboard/assets/css-src/30-task-index.css +21 -13
  154. package/templates/dashboard/assets/css-src/31-archive.css +94 -0
  155. package/templates/dashboard/assets/css-src/32-task-swimlane.css +487 -0
  156. package/templates/dashboard/assets/css-src/35-review-workspace.css +78 -0
  157. package/templates/dashboard/assets/css-src/40-detail-modules-migration.css +191 -14
  158. package/templates/dashboard/assets/css-src/50-responsive-overrides.css +23 -0
  159. package/templates/dashboard/assets/i18n.js +166 -2
  160. package/templates/development/README.md +9 -9
  161. package/templates/development/cross-repo-debugging.md +3 -3
  162. package/templates/development/external-context/service-template.md +1 -1
  163. package/templates/development/external-source-packs/README.md +2 -2
  164. package/templates/integrations/README.md +4 -4
  165. package/templates/integrations/api-contract.md +1 -1
  166. package/templates/integrations/event-contract.md +1 -1
  167. package/templates/integrations/third-party/vendor-template.md +1 -1
  168. package/templates/integrations/webhook-contract.md +1 -1
  169. package/templates/ledger/Harness-Ledger.md +1 -1
  170. package/templates/modules/module_brief.md +50 -0
  171. package/templates/modules/module_plan.md +49 -0
  172. package/templates/modules/registry_view.md +9 -0
  173. package/templates/modules/session_prompt_pack.md +55 -0
  174. package/templates/planning/brief.md +32 -8
  175. package/templates/planning/module_brief.md +28 -3
  176. package/templates/planning/module_plan.md +26 -11
  177. package/templates/planning/module_session_prompt.md +11 -2
  178. package/templates/planning/optional/slices/_slice-template/brief.md +28 -0
  179. package/templates/planning/review.md +1 -1
  180. package/templates/planning/visual_map.md +1 -1
  181. package/templates/reference/docs-library-standard.md +7 -7
  182. package/templates/reference/execution-workflow-standard.md +13 -0
  183. package/templates/reference/external-source-intake-standard.md +10 -10
  184. package/templates/reference/repo-governance-standard.md +1 -1
  185. package/templates/reference/review-routing-standard.md +4 -0
  186. package/templates/ssot/Module-Registry.md +4 -38
  187. package/templates/walkthrough/walkthrough-template.md +1 -1
  188. package/templates-zh-CN/AGENTS.md.template +27 -25
  189. package/templates-zh-CN/CLAUDE.md.template +1 -1
  190. package/templates-zh-CN/architecture/README.md +2 -2
  191. package/templates-zh-CN/architecture/service-catalog.md +2 -2
  192. package/templates-zh-CN/architecture/services/service-template.md +1 -1
  193. package/templates-zh-CN/development/README.md +9 -9
  194. package/templates-zh-CN/development/cross-repo-debugging.md +3 -3
  195. package/templates-zh-CN/development/external-context/service-template.md +1 -1
  196. package/templates-zh-CN/development/external-source-packs/README.md +2 -2
  197. package/templates-zh-CN/integrations/README.md +4 -4
  198. package/templates-zh-CN/integrations/api-contract.md +1 -1
  199. package/templates-zh-CN/integrations/event-contract.md +1 -1
  200. package/templates-zh-CN/integrations/third-party/vendor-template.md +1 -1
  201. package/templates-zh-CN/integrations/webhook-contract.md +1 -1
  202. package/templates-zh-CN/ledger/Harness-Ledger.md +1 -1
  203. package/templates-zh-CN/lessons/lesson-arch-process-change.md +1 -1
  204. package/templates-zh-CN/lessons/lesson-new-doc.md +3 -3
  205. package/templates-zh-CN/lessons/lesson-ref-change.md +4 -4
  206. package/templates-zh-CN/modules/module_brief.md +47 -0
  207. package/templates-zh-CN/modules/module_plan.md +48 -0
  208. package/templates-zh-CN/modules/registry_view.md +9 -0
  209. package/templates-zh-CN/modules/session_prompt_pack.md +50 -0
  210. package/templates-zh-CN/planning/INDEX.md +1 -0
  211. package/templates-zh-CN/planning/brief.md +26 -7
  212. package/templates-zh-CN/planning/module_brief.md +24 -2
  213. package/templates-zh-CN/planning/module_plan.md +35 -29
  214. package/templates-zh-CN/planning/module_session_prompt.md +15 -11
  215. package/templates-zh-CN/planning/optional/slices/_slice-template/brief.md +28 -11
  216. package/templates-zh-CN/planning/review.md +1 -1
  217. package/templates-zh-CN/reference/adversarial-review-standard.md +1 -1
  218. package/templates-zh-CN/reference/delivery-operating-model-standard.md +3 -3
  219. package/templates-zh-CN/reference/docs-library-standard.md +27 -27
  220. package/templates-zh-CN/reference/execution-workflow-standard.md +12 -2
  221. package/templates-zh-CN/reference/external-source-intake-standard.md +10 -10
  222. package/templates-zh-CN/reference/harness-ledger-standard.md +3 -3
  223. package/templates-zh-CN/reference/regression-ssot-governance.md +2 -2
  224. package/templates-zh-CN/reference/repo-governance-standard.md +1 -1
  225. package/templates-zh-CN/reference/review-routing-standard.md +3 -0
  226. package/templates-zh-CN/reference/walkthrough-standard.md +2 -2
  227. package/templates-zh-CN/reference/worktree-standard.md +1 -1
  228. package/templates-zh-CN/regression/Cadence-Ledger.md +2 -2
  229. package/templates-zh-CN/ssot/Delivery-SSoT.md +2 -2
  230. package/templates-zh-CN/ssot/Module-Registry.md +5 -44
  231. package/templates-zh-CN/ssot/Regression-SSoT.md +2 -2
  232. package/templates-zh-CN/walkthrough/walkthrough-template.md +4 -4
@@ -17,8 +17,8 @@ Run these preset entrypoints from the target root. The task scaffold only record
17
17
 
18
18
  | Output | Owner |
19
19
  | --- | --- |
20
- | `coding-agent-harness/governance/releases/{{release}}/INDEX.md` | `presets/release-closeout` |
21
- | `coding-agent-harness/governance/releases/{{release}}/task-aggregate.json` | `presets/release-closeout` |
22
- | `coding-agent-harness/governance/releases/{{release}}/task-archive-plan.md` | `presets/release-closeout` |
23
- | `coding-agent-harness/governance/releases/{{release}}/public-summary.md` | `presets/release-closeout` |
24
- | `coding-agent-harness/governance/releases/{{release}}/public-redaction-report.json` | `presets/release-closeout` |
20
+ | `{{paths.governanceRoot}}/releases/{{release}}/INDEX.md` | `presets/release-closeout` |
21
+ | `{{paths.governanceRoot}}/releases/{{release}}/task-aggregate.json` | `presets/release-closeout` |
22
+ | `{{paths.governanceRoot}}/releases/{{release}}/task-archive-plan.md` | `presets/release-closeout` |
23
+ | `{{paths.governanceRoot}}/releases/{{release}}/public-summary.md` | `presets/release-closeout` |
24
+ | `{{paths.governanceRoot}}/releases/{{release}}/public-redaction-report.json` | `presets/release-closeout` |
@@ -9,7 +9,7 @@ task:
9
9
  entrypoints:
10
10
  newTask:
11
11
  type: template
12
- writes: [coding-agent-harness/planning/tasks/**]
12
+ writes: [{{paths.tasksRoot}}/**]
13
13
  audit: true
14
14
  templates:
15
15
  taskPlanAppend: templates/task_plan.append.md
@@ -27,5 +27,5 @@ audit:
27
27
  evidenceFiles: [preset-audit.json]
28
28
  writeScopes:
29
29
  taskDocs:
30
- path: coding-agent-harness/planning/tasks/**
30
+ path: {{paths.tasksRoot}}/**
31
31
  access: write
@@ -70,23 +70,29 @@ AGENTS.md 只包含两类内容:
70
70
  项目根目录/
71
71
  ├── AGENTS.md ← concise canonical charter + routing index
72
72
  ├── CLAUDE.md ← 轻量 shim,指向 AGENTS.md
73
- └── docs/
74
- ├── Harness-Ledger.md
75
- └── coding-agent-harness/governance/standards/
76
- ├── testing-standard.md
77
- ├── execution-workflow-standard.md
78
- ├── repo-governance-standard.md
79
- ├── ci-cd-standard.md
80
- ├── long-running-task-standard.md
81
- ├── adversarial-review-standard.md
82
- ├── review-routing-standard.md
83
- ├── engineering-standard.md
84
- ├── frontend-standard.md
85
- ├── docs-library-standard.md
86
- ├── harness-ledger-standard.md
87
- ├── regression-ssot-governance.md
88
- ├── walkthrough-standard.md
89
- └── ...(按需扩展)
73
+ └── coding-agent-harness/
74
+ ├── governance/
75
+ │ ├── generated/
76
+ │ │ ├── Harness-Ledger.md
77
+ │ │ └── Closeout-Index.md
78
+ │ └── standards/
79
+ ├── testing-standard.md
80
+ ├── execution-workflow-standard.md
81
+ ├── repo-governance-standard.md
82
+ ├── ci-cd-standard.md
83
+ ├── long-running-task-standard.md
84
+ ├── adversarial-review-standard.md
85
+ ├── review-routing-standard.md
86
+ ├── engineering-standard.md
87
+ ├── frontend-standard.md
88
+ ├── docs-library-standard.md
89
+ │ ├── harness-ledger-standard.md
90
+ │ ├── regression-ssot-governance.md
91
+ │ ├── walkthrough-standard.md
92
+ │ └── ...(按需扩展)
93
+ └── planning/
94
+ ├── tasks/
95
+ └── modules/
90
96
  ```
91
97
 
92
98
  ### 行数控制
@@ -22,7 +22,7 @@ coding-agent-harness/governance/
22
22
  ├── lessons/ ← promoted lesson 详情文档
23
23
  │ ├── L-2026-05-07-001-xxx.md
24
24
  │ └── ...
25
- └── _archive/ ← 已合入或废弃的历史详情归档
25
+ └── archive/ ← 已合入或废弃的历史详情归档
26
26
 
27
27
  coding-agent-harness/planning/tasks/<task-id>/
28
28
  ├── lesson_candidates.md ← 候选索引和人工路由状态
@@ -146,7 +146,7 @@ pending governance integration -> approved -> merged
146
146
 
147
147
  ## 归档机制
148
148
 
149
- 当 `coding-agent-harness/governance/lessons/` 中已合入或废弃的详情文档过多时,可以把 `merged`、`rejected`、`superseded` 的文档移入 `coding-agent-harness/governance/_archive/`。不要归档仍被 Closeout Index 或 Harness Ledger 当前行引用的文档,除非同步更新引用。
149
+ 当 `coding-agent-harness/governance/lessons/` 中已合入或废弃的详情文档过多时,可以把 `merged`、`rejected`、`superseded` 的文档移入 `coding-agent-harness/governance/archive/`。不要归档仍被 Closeout Index 或 Harness Ledger 当前行引用的文档,除非同步更新引用。
150
150
 
151
151
  ## 人的审批工作流
152
152
 
@@ -90,11 +90,8 @@ coding-agent-harness/planning/modules/<key>/
90
90
  │ └── review.md (如需要)
91
91
  └── ...
92
92
 
93
- task-local walkthrough.md/
94
- ├── <module-key>/
95
- │ ├── <PREFIX>-NN-walkthrough.md
96
- │ └── ...
97
- └── _shared/ ← 跨模块基础设施 task 的 walkthrough
93
+ 每个任务的收口记录保存在该任务目录的 `walkthrough.md`。不再维护集中式
94
+ walkthrough 目录树。
98
95
 
99
96
  coding-agent-harness/planning/modules/_shared/tasks/
100
97
  └── YYYY-MM-DD-<name>/ ← 跨模块/基础设施 task
@@ -264,7 +261,7 @@ HARNESS_REQUIRE_GLOBAL_MODULE_SYNC=1 node dist/check-harness.mjs <repo-path>
264
261
 
265
262
  - 模块所有步骤完成后,状态改为 `completed`
266
263
  - 将模块目录移入 `coding-agent-harness/planning/modules/_archive/<key>/`
267
- - 对应的 walkthrough 保留在 `walkthrough.md/`(不归档)
264
+ - 对应的收口记录保留在各任务目录的 `walkthrough.md`(不归档)
268
265
 
269
266
  ### 过期检测
270
267
 
@@ -98,8 +98,8 @@ SSoT(Single Source of Truth,单一事实源)保存当前事实。任务生
98
98
  | Regression SSoT | active gates | gate 废弃或长期不再运行 | `coding-agent-harness/governance/regression/_archive/` |
99
99
  | Cadence Ledger | active cadence checks | cadence 废弃或合并到其他 gate | `coding-agent-harness/governance/regression/_archive/` |
100
100
  | Closeout Index | 当前 closeout 索引 | closed/superseded 超过保留窗口 | `coding-agent-harness/governance/archive/legacy-walkthrough/` |
101
- | Lesson detail docs | pending / approved / superseded 详情文档 | merged/rejected 超过 20 条 | `coding-agent-harness/governance/_archive/` |
102
- | Harness Ledger | 当前生成索引 | 重新生成前 archive 旧快照 | `coding-agent-harness/governance/_archive/` 或迁移会话 archive |
101
+ | Lesson detail docs | pending / approved / superseded 详情文档 | merged/rejected 超过 20 条 | `coding-agent-harness/governance/archive/` |
102
+ | Harness Ledger | 当前生成索引 | 重新生成前 archive 旧快照 | `coding-agent-harness/governance/archive/` 或迁移会话 archive |
103
103
 
104
104
  归档不改变 ID,不删除证据文件;Active 文件必须留下 archive index 或指向归档文件。
105
105
 
@@ -2,7 +2,7 @@
2
2
 
3
3
  > 对比基准:
4
4
  > - **Taskr**: [xerrors/taskr-skill](https://github.com/xerrors/taskr-skill)(SKILL.md + protocol.ts + CLI + Board)
5
- > - **Coding Agent Harness**: 本仓库 `/Users/lizeyu/Projects/coding-agent-harness`(SKILL.md + 12 references + 30+ templates)
5
+ > - **Coding Agent Harness**: 本仓库根目录(SKILL.md + references/ + 30+ templates)
6
6
  >
7
7
  > 分析日期:2026-05-21
8
8
  > 分析人:小宁(Codex Main)
@@ -558,10 +558,10 @@ Footer 格式:`Taskr: <task-id>`(注意不是旧的 `[taskr:<id>]` subject-l
558
558
 
559
559
  ```
560
560
  Before(当前):
561
- SKILL.md → 12 references → 30+ templates → agent 手动读写 md
561
+ SKILL.md → references/ → 30+ templates → agent 手动读写 md
562
562
 
563
563
  After(吸收后):
564
- SKILL.md → 12 references(更新) → 30+ templates(更新,带 frontmatter)
564
+ SKILL.md → references/(更新) → 30+ templates(更新,带 frontmatter)
565
565
  → scripts/validate-tasks.sh ← 新增
566
566
  → scripts/harness-doctor.sh ← 新增
567
567
  → scripts/reconcile-commits.sh ← 新增
package/run-dist.mjs ADDED
@@ -0,0 +1,34 @@
1
+ #!/usr/bin/env node
2
+ import fs from "node:fs";
3
+ import path from "node:path";
4
+ import { spawnSync } from "node:child_process";
5
+ import { fileURLToPath } from "node:url";
6
+
7
+ const [entrypoint, ...args] = process.argv.slice(2);
8
+ if (!entrypoint) {
9
+ console.error("Usage: node run-dist.mjs <dist-entrypoint> [...args]");
10
+ process.exit(1);
11
+ }
12
+
13
+ const root = path.dirname(fileURLToPath(import.meta.url));
14
+ const buildScript = path.join(root, "scripts/build-dist.mts");
15
+ const distEntrypoint = path.join(root, "dist", entrypoint);
16
+
17
+ if (fs.existsSync(buildScript)) {
18
+ const build = spawnSync(process.execPath, [buildScript, "--quiet"], {
19
+ cwd: root,
20
+ stdio: "inherit",
21
+ });
22
+ if (build.status !== 0) process.exit(build.status ?? 1);
23
+ }
24
+
25
+ if (!fs.existsSync(distEntrypoint)) {
26
+ console.error(`Missing dist runtime entrypoint: dist/${entrypoint}`);
27
+ process.exit(1);
28
+ }
29
+
30
+ const result = spawnSync(process.execPath, [distEntrypoint, ...args], {
31
+ cwd: root,
32
+ stdio: "inherit",
33
+ });
34
+ process.exit(result.status ?? 1);
@@ -41,10 +41,19 @@ Before writing files, answer these in the task notes or your response:
41
41
 
42
42
  Use the bundled references before writing files:
43
43
 
44
+ - `references/structure-aware-paths.md`
44
45
  - `references/complex-task-skeleton/`
45
46
  - `references/preset-package-skeleton.md`
46
47
 
47
- The complex task skeleton reference contains the base `brief.md`, `task_plan.md`, `execution_strategy.md`, `visual_map.md`, `findings.md`, `lesson_candidates.md`, `progress.md`, `review.md`, `references/INDEX.md`, and `artifacts/INDEX.md` contracts. The preset package skeleton contains a copyable package tree, a complete `preset.yaml`, starter Markdown resources, and the verification checklist. Keep this `SKILL.md` focused on method and judgment; use the references when the task has moved from design to file creation.
48
+ The structure-aware paths reference is mandatory before writing `preset.yaml`;
49
+ it defines `{{paths.*}}`, safe write scopes, drift audit, and template refresh.
50
+ The complex task skeleton reference contains the base `brief.md`, `task_plan.md`,
51
+ `execution_strategy.md`, `visual_map.md`, `findings.md`,
52
+ `lesson_candidates.md`, `progress.md`, `review.md`, `references/INDEX.md`, and
53
+ `artifacts/INDEX.md` contracts. The preset package skeleton contains a copyable
54
+ package tree, a complete `preset.yaml`, starter Markdown resources, and the
55
+ verification checklist. Keep this `SKILL.md` focused on method and judgment; use
56
+ the references when the task has moved from design to file creation.
48
57
 
49
58
  Use a simple package:
50
59
 
@@ -61,6 +70,19 @@ my-preset/
61
70
  input-packet.md
62
71
  ```
63
72
 
73
+ ## Structure-Aware Paths
74
+
75
+ Preset authors must not hard-code Harness runtime paths such as
76
+ `coding-agent-harness/planning/tasks/**`. Repositories may move the Harness
77
+ folder, so every runtime write/read scope must use the target's resolved
78
+ `{{paths.*}}` context.
79
+
80
+ Before creating or reviewing a preset, read
81
+ `references/structure-aware-paths.md`. For normal task-creating presets, use
82
+ `{{paths.tasksRoot}}/**` in both `entrypoints.newTask.writes` and
83
+ `writeScopes.*.path`. These values must match exactly; do not rely on partial
84
+ overlap.
85
+
64
86
  ## Required Manifest Sections
65
87
 
66
88
  - `id`: lowercase letters, numbers, and hyphens.
@@ -93,6 +115,11 @@ Supported input types are `text`, `flag`, and `json-file`. Resource `index.type`
93
115
 
94
116
  Every value in `entrypoints.newTask.writes` must exactly match one `writeScopes.*.path` entry. Do not rely on partial overlap.
95
117
 
118
+ For runtime paths in manifests or rendered Markdown, use `{{paths.*}}`.
119
+ For ordinary preset values, use `{{valueName}}` from `templateValues`.
120
+ Do not mix the two: `{{paths.*}}` is supplied by Harness from the target
121
+ `harness.yaml`, while `{{valueName}}` is supplied by the preset manifest.
122
+
96
123
  ## Reference Bundle Pattern
97
124
 
98
125
  Use `resources.references` when the preset should preload common context for a group of tasks.
@@ -146,6 +173,7 @@ Do not confuse artifacts with evidence. Artifacts can be input packets or fixtur
146
173
  ## Safety Rules
147
174
 
148
175
  - `writeScopes` must be as narrow as possible.
176
+ - Runtime write/read scopes must use `{{paths.*}}`, usually `{{paths.tasksRoot}}/**`.
149
177
  - Generated files must stay under the created task directory.
150
178
  - A preset must not mutate source code, Git state, or global governance tables during `new-task`.
151
179
  - Do not add JavaScript for `new-task` behavior.
@@ -159,13 +187,15 @@ Do not confuse artifacts with evidence. Artifacts can be input packets or fixtur
159
187
  2. For complex presets, open `references/complex-task-skeleton/README.md` and inspect the base task files the preset will overlay.
160
188
  3. Open `references/preset-package-skeleton.md` and copy only the files the preset actually needs.
161
189
  4. Create the preset directory with `preset.yaml`, templates, and resources.
162
- 5. Keep task creation declarative: manifest inputs, `templateValues`, `metadata`, Markdown templates, `resources`, evidence declarations, and `writeScopes`.
163
- 6. Run `harness preset check <path>`.
164
- 7. Install with `harness preset install <path> --force` in a disposable or user-approved environment.
165
- 8. Smoke test with `harness new-task <id> --budget <budget> --preset <preset-id> ... <target>`.
166
- 9. For reference-bundle presets, create two different tasks from the same preset and verify both contain the same shared references but independent audit/evidence bundles.
167
- 10. Run `harness status --json <target>`, `harness task-index --json <target>`, and `harness check --profile target-project <target>`.
168
- 11. Inspect the generated `task_plan.md`, `references/INDEX.md`, and `artifacts/INDEX.md` manually before declaring success.
190
+ 5. Use `{{paths.tasksRoot}}/**` or another supported `{{paths.*}}` field for every runtime write/read scope; never hard-code `coding-agent-harness/...`.
191
+ 6. Keep task creation declarative: manifest inputs, `templateValues`, `metadata`, Markdown templates, `resources`, evidence declarations, and `writeScopes`.
192
+ 7. Run `harness preset check <path>`.
193
+ 8. Install with `harness preset install <path> --force` in a disposable or user-approved environment.
194
+ 9. Smoke test with `harness new-task <id> --budget <budget> --preset <preset-id> ... <target>`.
195
+ 10. For reference-bundle presets, create two different tasks from the same preset and verify both contain the same shared references but independent audit/evidence bundles.
196
+ 11. Run `harness status --json <target>`, `harness task-index --json <target>`, and `harness check --profile target-project <target>`.
197
+ 12. Run `harness preset audit --json` or `harness preset audit --project --json <target>` before replacing installed presets.
198
+ 13. Inspect the generated `task_plan.md`, `references/INDEX.md`, and `artifacts/INDEX.md` manually before declaring success.
169
199
 
170
200
  ## Quality Checklist
171
201
 
@@ -175,5 +205,7 @@ Do not confuse artifacts with evidence. Artifacts can be input packets or fixtur
175
205
  - Every required read points to a real `REF-*` row.
176
206
  - Every `REF-*` row explains why that reference matters.
177
207
  - Every generated artifact has an `ART-*` row when artifacts are used.
208
+ - No runtime path is hard-coded to `coding-agent-harness/...`; scopes use `{{paths.*}}`.
209
+ - `entrypoints.newTask.writes` and `writeScopes.*.path` match exactly.
178
210
  - The preset passes `preset check`, task creation, `status --json`, `task-index --json`, and target check.
179
211
  - A downstream agent can create a valid preset from this skill without editing Harness source.
@@ -1,7 +1,5 @@
1
1
  # {{TASK_TITLE}}
2
2
 
3
- ## Brief
4
-
5
3
  ## Task ID
6
4
 
7
5
  `{{TASK_ID}}`
@@ -10,26 +8,52 @@
10
8
 
11
9
  {{DATE}}
12
10
 
13
- ## Outcome
11
+ ## Outcome Statement
12
+
13
+ One sentence stating the concrete result this task must produce.
14
+
15
+ ## Outcome Value
16
+
17
+ Write 100-300 words explaining what the user, project, or next agent gets when
18
+ this task is complete. Describe the decision, delivery, verification, or next
19
+ development step this result unlocks. Focus on the usable result rather than the
20
+ implementation process unless the implementation method is itself the
21
+ deliverable.
22
+
23
+ ## Deliverables
14
24
 
15
- State the user-visible or project-visible result this task must deliver.
25
+ - Visible artifact:
26
+ - Modified surface:
27
+ - Verification evidence:
28
+
29
+ ## First Human Read
30
+
31
+ Name the files, evidence, or generated outputs a human should inspect first when
32
+ they open this task.
16
33
 
17
34
  ## Boundaries
18
35
 
19
36
  - In scope: files, behavior, documentation, or verification this task may change.
20
37
  - Out of scope: work that must not be folded into this task.
21
- - Stop conditions: uncertainty, risk, or missing access that requires coordinator or user review.
38
+ - Stop conditions: uncertainty, risk, or missing access that requires coordinator
39
+ or user review.
40
+
41
+ ## Completion Judgment
42
+
43
+ List 3-5 concrete conditions that prove the outcome has been reached. Keep the
44
+ full execution plan in `task_plan.md`.
22
45
 
23
46
  ## Execution Contract
24
47
 
25
48
  - Owner: coordinator
26
49
  - Lifecycle state: not_started
27
- - Required files: `task_plan.md`, `execution_strategy.md`, `visual_map.md`, `progress.md`, `findings.md`, `review.md`
50
+ - Required files: `task_plan.md`, `execution_strategy.md`, `visual_map.md`,
51
+ `progress.md`, `findings.md`, `review.md`
28
52
  - Required closeout: verification evidence recorded in `progress.md`
29
53
 
30
- ## First Next Step
54
+ ## Current Next Step
31
55
 
32
- Replace this line with the first concrete action before implementation starts.
56
+ State the first concrete action before implementation starts.
33
57
 
34
58
  ## Scaffold Provenance
35
59
 
@@ -33,7 +33,7 @@ task:
33
33
  entrypoints:
34
34
  newTask:
35
35
  type: template
36
- writes: [docs/coding-agent-harness/planning/tasks/**]
36
+ writes: [{{paths.tasksRoot}}/**]
37
37
  audit: true
38
38
  templates:
39
39
  taskPlanAppend: templates/task_plan.append.md
@@ -90,7 +90,7 @@ audit:
90
90
  evidenceFiles: [preset-audit.json, preset-manifest.json, write-scope.json]
91
91
  writeScopes:
92
92
  taskDocs:
93
- path: docs/coding-agent-harness/planning/tasks/**
93
+ path: {{paths.tasksRoot}}/**
94
94
  access: write
95
95
  ```
96
96
 
@@ -173,7 +173,7 @@ task:
173
173
  entrypoints:
174
174
  newTask:
175
175
  type: template
176
- writes: [docs/coding-agent-harness/planning/tasks/**]
176
+ writes: [{{paths.tasksRoot}}/**]
177
177
  audit: true
178
178
  templates:
179
179
  taskPlanAppend: templates/task_plan.append.md
@@ -196,7 +196,7 @@ audit:
196
196
  evidenceFiles: [preset-audit.json, preset-manifest.json, write-scope.json]
197
197
  writeScopes:
198
198
  taskDocs:
199
- path: docs/coding-agent-harness/planning/tasks/**
199
+ path: {{paths.tasksRoot}}/**
200
200
  access: write
201
201
  ```
202
202
 
@@ -205,6 +205,16 @@ writeScopes:
205
205
  - `id` uses lowercase letters, numbers, and hyphens only.
206
206
  - Supported `inputs.*.type` values are `text`, `flag`, and `json-file`.
207
207
  - `entrypoints.newTask.writes` entries must exactly match declared `writeScopes.*.path` entries.
208
+ - Use `actions` only for task-level post-creation commands exposed through
209
+ `harness preset action <preset> <action>`.
210
+ - `actions.*.command` must be a package-local `.mjs` file. Non-bundled script
211
+ actions require explicit `--allow-scripts` trust during install or run.
212
+ - `actions.*.inputs` supports the same schema-only input types as preset
213
+ inputs: `text`, `flag`, and `json-file`.
214
+ - `actions.*.writes` must be task-local. Prefer `{{task.paths.artifacts}}/**`,
215
+ `{{task.paths.artifactsIndex}}`, `{{task.paths.progress}}`, and
216
+ `{{task.paths.visualMap}}`; do not use broad `{{paths.tasksRoot}}/**` for an
217
+ action.
208
218
  - `path` for references must stay under `references/`.
209
219
  - `path` for artifacts must stay under `artifacts/`.
210
220
  - Do not target `references/INDEX.md`, `artifacts/INDEX.md`, `task_plan.md`, or any canonical task contract file.
@@ -267,7 +277,7 @@ Open `references/INDEX.md`, then read these preset-provided references before im
267
277
 
268
278
  | Reference | Path | Why |
269
279
  | --- | --- | --- |
270
- | REF-001 | TARGET:docs/coding-agent-harness/planning/tasks/<task-folder>/references/upstream-contract.md | [rendered summary] |
280
+ | REF-001 | TARGET:docs/{{paths.harnessRoot}}/planning/tasks/<task-folder>/references/upstream-contract.md | [rendered summary] |
271
281
  ```
272
282
 
273
283
  The same `REF-001` and exact `TARGET:` path must also appear in `references/INDEX.md`.
@@ -0,0 +1,112 @@
1
+ # Structure-Aware Preset Paths
2
+
3
+ Use this reference before writing or reviewing any Harness `preset.yaml`.
4
+
5
+ ## Core Rule
6
+
7
+ Do not hard-code Harness runtime paths such as
8
+ `coding-agent-harness/planning/tasks/**`. Repositories may move the Harness
9
+ folder, so runtime write/read scopes must use `{{paths.*}}`, resolved from the
10
+ target repository's `harness.yaml`.
11
+
12
+ For ordinary task-creating presets, use this pair:
13
+
14
+ ```yaml
15
+ entrypoints:
16
+ newTask:
17
+ writes: [{{paths.tasksRoot}}/**]
18
+ writeScopes:
19
+ taskDocs:
20
+ path: {{paths.tasksRoot}}/**
21
+ access: write
22
+ ```
23
+
24
+ The `entrypoints.newTask.writes` entries must exactly match declared
25
+ `writeScopes.*.path` entries.
26
+
27
+ ## Supported Fields
28
+
29
+ | Field | Use |
30
+ | --- | --- |
31
+ | `{{paths.harnessRoot}}` | Harness root for the target repository |
32
+ | `{{paths.planningRoot}}` | Planning root |
33
+ | `{{paths.tasksRoot}}` | Task directory root |
34
+ | `{{paths.modulesRoot}}` | Module planning root |
35
+ | `{{paths.externalRoot}}` | External context root |
36
+ | `{{paths.governanceRoot}}` | Governance root |
37
+ | `{{paths.generatedRoot}}` | Generated governance files |
38
+ | `{{paths.regressionRoot}}` | Regression records |
39
+ | `{{paths.ledgerPath}}` | Harness ledger path |
40
+ | `{{paths.closeoutIndexPath}}` | Closeout index path |
41
+
42
+ ## Minimal Manifest
43
+
44
+ ```yaml
45
+ id: custom-review
46
+ version: 1
47
+ purpose: Create a custom review task
48
+ compatibleBudgets: [standard, complex]
49
+ localeSupport: [en-US]
50
+ task:
51
+ kind: review-task
52
+ defaultTaskId: custom-review-task
53
+ entrypoints:
54
+ newTask:
55
+ type: template
56
+ writes: [{{paths.tasksRoot}}/**]
57
+ audit: true
58
+ templates:
59
+ taskPlanAppend: templates/task_plan.append.md
60
+ inputs:
61
+ subject:
62
+ type: text
63
+ flag: --subject
64
+ required: true
65
+ templateValues:
66
+ subject:
67
+ from: inputs.subject
68
+ metadata:
69
+ ReviewSubject:
70
+ label: Review Subject
71
+ from: inputs.subject
72
+ evidence:
73
+ bundleDir: artifacts/preset
74
+ audit:
75
+ manifestRequired: true
76
+ evidenceFiles: [preset-audit.json, preset-manifest.json, write-scope.json]
77
+ writeScopes:
78
+ taskDocs:
79
+ path: {{paths.tasksRoot}}/**
80
+ access: write
81
+ ```
82
+
83
+ ## Path Boundaries
84
+
85
+ - Use `{{paths.*}}` only for Harness runtime paths.
86
+ - Keep preset package paths package-relative: `templates/task_plan.append.md`,
87
+ `resources/runbook.md`, `references/foo.md`.
88
+ - Keep generated task-local resource destinations task-relative:
89
+ `references/foo.md`, `artifacts/foo.md`.
90
+ - Do not write default-layout examples as runtime instructions. If prose must
91
+ mention `coding-agent-harness/`, label it as the default layout.
92
+ - Do not overwrite user-customized installed presets unless the user explicitly
93
+ approved it.
94
+ - Do not overwrite project-authored files or user-modified template projections.
95
+
96
+ ## Validation Commands
97
+
98
+ ```bash
99
+ harness preset check ./my-preset
100
+ harness new-task --title "Smoke" --preset my-preset /path/to/project
101
+ harness check --profile target-project /path/to/project
102
+ harness preset audit --json
103
+ harness preset audit --project --json /path/to/project
104
+ harness templates audit --json /path/to/project
105
+ harness templates refresh --apply --json /path/to/project
106
+ ```
107
+
108
+ `harness preset check` validates token syntax. Creating or installing against a
109
+ target validates resolved scopes against that target's actual structure.
110
+
111
+ Use `harness preset audit` before replacing installed user/project presets. Use
112
+ `harness templates audit` before refreshing generated project templates.
@@ -2,7 +2,7 @@
2
2
 
3
3
  This file is the operating entry point for agents working in this repository.
4
4
  Keep it as a charter and routing index. Detailed rules belong in
5
- `coding-agent-harness/governance/standards/`, not in this file.
5
+ `{{paths.harnessRoot}}/governance/standards/`, not in this file.
6
6
 
7
7
  ## Project Profile
8
8
 
@@ -14,13 +14,13 @@ Keep it as a charter and routing index. Detailed rules belong in
14
14
 
15
15
  ## Non-Negotiable Rules
16
16
 
17
- 1. Preserve architecture boundaries documented in `coding-agent-harness/governance/standards/engineering-standard.md`.
17
+ 1. Preserve architecture boundaries documented in `{{paths.harnessRoot}}/governance/standards/engineering-standard.md`.
18
18
  2. Do not commit secrets, credentials, private endpoints, or user data.
19
- 3. Start non-trivial work with a Harness CLI-created task directory under `coding-agent-harness/planning/tasks/`.
19
+ 3. Start non-trivial work with a Harness CLI-created task directory under `{{paths.harnessRoot}}/planning/tasks/`.
20
20
  4. Record evidence before claiming completion.
21
21
  5. Protect unrelated working-tree changes; never revert files outside the assigned scope.
22
22
  6. Commit verified, meaningful work slices proactively. Do not leave completed work only as dirty files unless the user explicitly pauses commits, checks fail, dirty ownership is unclear, or a security boundary prevents a clean commit; in those cases record the no-commit reason, owner, and next step in progress, handoff, or closeout notes. Never mix unrelated dirty changes into a task commit.
23
- 7. Before the final response, inspect the current task `visual_map.md` gate phase. If the current `Exit Command` has `Actor: agent`, run it or record the blocker. Never run a `human` gate such as `review-confirm` unless the user has explicitly performed or delegated that human confirmation.
23
+ 7. Before the final response, inspect the current task `visual_map.md` gate phase. If the current `Exit Command` has `Actor: agent`, run it or record the blocker. Never perform a `human` gate; human review confirmation belongs in the local Dashboard workbench.
24
24
 
25
25
  ## Reading Matrix
26
26
 
@@ -28,23 +28,23 @@ Read the smallest context that can answer the task.
28
28
 
29
29
  | Work Type | Read First |
30
30
  | --- | --- |
31
- | Architecture or core module change | `coding-agent-harness/governance/standards/engineering-standard.md` |
32
- | System map, service responsibility, or external system relationship | `coding-agent-harness/context/architecture/README.md`, `coding-agent-harness/context/architecture/service-catalog.md` |
33
- | Local development, mocks, stubs, or cross-repo debugging | `coding-agent-harness/context/development/README.md`, `coding-agent-harness/context/development/codebase-map.md` |
34
- | API, event, webhook, SDK, or third-party contract | `coding-agent-harness/context/integrations/README.md` and the related contract file |
35
- | Tests, smoke, or regression | `coding-agent-harness/governance/standards/testing-standard.md`, `coding-agent-harness/governance/regression/Regression-SSoT.md` |
36
- | Execution, commit, PR, or release work | `coding-agent-harness/governance/standards/execution-workflow-standard.md`, `coding-agent-harness/governance/standards/repo-governance-standard.md`, `coding-agent-harness/governance/standards/pull-request-standard.md`, `coding-agent-harness/governance/standards/ci-cd-standard.md` |
37
- | Creating or advancing a task | Current task directory under `coding-agent-harness/planning/tasks/`; use `harness new-task` / lifecycle commands when this project has the Harness CLI configured |
31
+ | Architecture or core module change | `{{paths.harnessRoot}}/governance/standards/engineering-standard.md` |
32
+ | System map, service responsibility, or external system relationship | `{{paths.harnessRoot}}/context/architecture/README.md`, `{{paths.harnessRoot}}/context/architecture/service-catalog.md` |
33
+ | Local development, mocks, stubs, or cross-repo debugging | `{{paths.harnessRoot}}/context/development/README.md`, `{{paths.harnessRoot}}/context/development/codebase-map.md` |
34
+ | API, event, webhook, SDK, or third-party contract | `{{paths.harnessRoot}}/context/integrations/README.md` and the related contract file |
35
+ | Tests, smoke, or regression | `{{paths.harnessRoot}}/governance/standards/testing-standard.md`, `{{paths.harnessRoot}}/governance/regression/Regression-SSoT.md` |
36
+ | Execution, commit, PR, or release work | `{{paths.harnessRoot}}/governance/standards/execution-workflow-standard.md`, `{{paths.harnessRoot}}/governance/standards/repo-governance-standard.md`, `{{paths.harnessRoot}}/governance/standards/pull-request-standard.md`, `{{paths.harnessRoot}}/governance/standards/ci-cd-standard.md` |
37
+ | Creating or advancing a task | Current task directory under `{{paths.harnessRoot}}/planning/tasks/`; use `harness new-task` / lifecycle commands when this project has the Harness CLI configured |
38
38
  | Brief, Execution Strategy, or Visual Map | Current task `brief.md`, `execution_strategy.md`, and `visual_map.md` |
39
39
  | Long-running task | Current task `long-running-task-contract.md` when present |
40
- | Reviewer, subagent, or adversarial review | Current task `review.md`, `coding-agent-harness/governance/standards/review-routing-standard.md` |
41
- | Team, multi-repo, or staged delivery | `coding-agent-harness/governance/standards/delivery-operating-model-standard.md`, `coding-agent-harness/planning/Delivery-SSoT.md` |
42
- | Module-parallel work | `coding-agent-harness/planning/modules/Module-Registry.md` and the related module plan |
43
- | Documentation governance or Harness update | `coding-agent-harness/governance/standards/docs-library-standard.md`, `coding-agent-harness/harness.yaml` |
44
- | External source material intake | `coding-agent-harness/governance/standards/external-source-intake-standard.md` |
45
- | Regression SSoT maintenance | `coding-agent-harness/governance/standards/regression-ssot-governance.md` |
46
- | Walkthrough, closeout, or lessons | `coding-agent-harness/governance/standards/walkthrough-standard.md`, current task `walkthrough.md`, current task `lesson_candidates.md`, `coding-agent-harness/governance/lessons/` |
47
- | Worktree operations | `coding-agent-harness/governance/standards/worktree-standard.md` |
40
+ | Reviewer, subagent, or adversarial review | Current task `review.md`, `{{paths.harnessRoot}}/governance/standards/review-routing-standard.md` |
41
+ | Team, multi-repo, or staged delivery | `{{paths.harnessRoot}}/governance/standards/delivery-operating-model-standard.md`, `{{paths.harnessRoot}}/planning/Delivery-SSoT.md` |
42
+ | Module-parallel work | `{{paths.harnessRoot}}/harness.yaml`, generated `{{paths.harnessRoot}}/planning/modules/Module-Registry.md`, the module `brief.md`, and the related `module_plan.md` |
43
+ | Documentation governance or Harness update | `{{paths.harnessRoot}}/governance/standards/docs-library-standard.md`, `{{paths.harnessRoot}}/harness.yaml` |
44
+ | External source material intake | `{{paths.harnessRoot}}/governance/standards/external-source-intake-standard.md` |
45
+ | Regression SSoT maintenance | `{{paths.harnessRoot}}/governance/standards/regression-ssot-governance.md` |
46
+ | Walkthrough, closeout, or lessons | `{{paths.harnessRoot}}/governance/standards/walkthrough-standard.md`, current task `walkthrough.md`, current task `lesson_candidates.md`, `{{paths.harnessRoot}}/governance/lessons/` |
47
+ | Worktree operations | `{{paths.harnessRoot}}/governance/standards/worktree-standard.md` |
48
48
 
49
49
  ## Standard Execution Flow
50
50
 
@@ -70,17 +70,19 @@ Read the smallest context that can answer the task.
70
70
  - Worker subagents require one user authorization recorded in `execution_strategy.md`; after that, reuse is allowed only within the same task, scope, and worktree/branch.
71
71
  - Shared ledgers, registries, and SSoT files are coordinator-owned unless a lock is explicitly assigned.
72
72
  - Worker handoff must include branch or worktree, changed files, checks, evidence, and residual risks.
73
+ - Modules are registered in `{{paths.harnessRoot}}/harness.yaml` under `modules.items`. `Module-Registry.md` is generated; do not hand-edit it as the source of truth.
74
+ - Module roots own only `brief.md` and `module_plan.md` by default. Task execution contracts such as `execution_strategy.md`, `visual_map.md`, `review.md`, and `walkthrough.md` belong under concrete task directories, including `{{paths.harnessRoot}}/planning/modules/<key>/tasks/<task-id>/`.
73
75
 
74
76
  ## Single Sources Of Truth
75
77
 
76
- - Delivery SSoT: `coding-agent-harness/planning/Delivery-SSoT.md`
77
- - Module Registry: `coding-agent-harness/planning/modules/Module-Registry.md`
78
- - Regression SSoT: `coding-agent-harness/governance/regression/Regression-SSoT.md`
79
- - Cadence Ledger: `coding-agent-harness/governance/regression/Cadence-Ledger.md`
78
+ - Delivery SSoT: `{{paths.harnessRoot}}/planning/Delivery-SSoT.md`
79
+ - Module Registry: `{{paths.harnessRoot}}/harness.yaml` `modules.items`; generated view at `{{paths.harnessRoot}}/planning/modules/Module-Registry.md`
80
+ - Regression SSoT: `{{paths.harnessRoot}}/governance/regression/Regression-SSoT.md`
81
+ - Cadence Ledger: `{{paths.harnessRoot}}/governance/regression/Cadence-Ledger.md`
80
82
  - Lesson Candidates: current task `lesson_candidates.md`
81
- - Lesson Detail Docs: `coding-agent-harness/governance/lessons/`
82
- - Generated Closeout Index: `coding-agent-harness/governance/generated/Closeout-Index.md`
83
- - Harness Ledger: `coding-agent-harness/governance/generated/Harness-Ledger.md`
83
+ - Lesson Detail Docs: `{{paths.harnessRoot}}/governance/lessons/`
84
+ - Generated Closeout Index: `{{paths.harnessRoot}}/governance/generated/Closeout-Index.md`
85
+ - Harness Ledger: `{{paths.harnessRoot}}/governance/generated/Harness-Ledger.md`
84
86
 
85
87
  ## Local Commands
86
88
 
@@ -22,8 +22,8 @@ This folder is the system-structure source of truth. It explains what the curren
22
22
  ## Boundary
23
23
 
24
24
  - Put system structure, service responsibility, ownership, and critical flows here.
25
- - Put payload bodies, endpoint parameters, event schemas, and SDK details in `coding-agent-harness/context/integrations/`.
26
- - Put local setup, mocks, stubs, and cross-repo debugging notes in `coding-agent-harness/context/development/`.
25
+ - Put payload bodies, endpoint parameters, event schemas, and SDK details in `{{paths.harnessRoot}}/context/integrations/`.
26
+ - Put local setup, mocks, stubs, and cross-repo debugging notes in `{{paths.harnessRoot}}/context/development/`.
27
27
 
28
28
  ## Structure Contract
29
29