coding-agent-harness 1.0.2 → 1.0.5

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 (219) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/CONTRIBUTING.md +98 -0
  3. package/LICENSE +661 -21
  4. package/LICENSE-EXCEPTION.md +37 -0
  5. package/README.md +244 -87
  6. package/README.zh-CN.md +77 -35
  7. package/SKILL.md +32 -24
  8. package/docs-release/README.md +9 -5
  9. package/docs-release/architecture/overview.md +17 -5
  10. package/docs-release/architecture/overview.zh-CN.md +9 -5
  11. package/docs-release/architecture/system-explainer/01-system-overview.md +217 -0
  12. package/docs-release/architecture/system-explainer/02-module-dependency.md +257 -0
  13. package/docs-release/architecture/system-explainer/03-task-lifecycle.md +304 -0
  14. package/docs-release/architecture/system-explainer/04-check-and-governance.md +239 -0
  15. package/docs-release/architecture/system-explainer/05-data-flow.md +276 -0
  16. package/docs-release/architecture/system-explainer/06-preset-and-migration.md +303 -0
  17. package/docs-release/architecture/system-explainer/README.md +67 -0
  18. package/docs-release/architecture/system-explainer/en-US/01-system-overview.md +226 -0
  19. package/docs-release/architecture/system-explainer/en-US/02-module-dependency.md +263 -0
  20. package/docs-release/architecture/system-explainer/en-US/03-task-lifecycle.md +319 -0
  21. package/docs-release/architecture/system-explainer/en-US/04-check-and-governance.md +250 -0
  22. package/docs-release/architecture/system-explainer/en-US/05-data-flow.md +290 -0
  23. package/docs-release/architecture/system-explainer/en-US/06-preset-and-migration.md +323 -0
  24. package/docs-release/architecture/system-explainer/en-US/README.md +70 -0
  25. package/docs-release/assets/dashboard-overview.png +0 -0
  26. package/docs-release/guides/agent-installation.en-US.md +39 -15
  27. package/docs-release/guides/agent-installation.md +43 -16
  28. package/docs-release/guides/contributing.md +100 -0
  29. package/docs-release/guides/contributing.zh-CN.md +99 -0
  30. package/docs-release/guides/document-audience-and-surfaces.en-US.md +3 -2
  31. package/docs-release/guides/document-audience-and-surfaces.md +3 -2
  32. package/docs-release/guides/full-legacy-migration-subagent-strategy.md +2 -2
  33. package/docs-release/guides/full-legacy-migration-subagent-strategy.zh-CN.md +2 -2
  34. package/docs-release/guides/legacy-migration-agent-prompt.md +0 -11
  35. package/docs-release/guides/legacy-migration-agent-prompt.zh-CN.md +0 -11
  36. package/docs-release/guides/migration-playbook.en-US.md +14 -15
  37. package/docs-release/guides/migration-playbook.md +14 -15
  38. package/docs-release/guides/parent-control-repository-pattern.en-US.md +7 -5
  39. package/docs-release/guides/parent-control-repository-pattern.md +7 -5
  40. package/docs-release/guides/preset-development.md +238 -0
  41. package/docs-release/guides/repository-operating-models.en-US.md +5 -4
  42. package/docs-release/guides/repository-operating-models.md +5 -4
  43. package/docs-release/guides/task-state-machine.en-US.md +224 -0
  44. package/docs-release/guides/task-state-machine.md +231 -0
  45. package/docs-release/intl/en-US.md +1 -1
  46. package/docs-release/intl/zh-CN.md +1 -1
  47. package/examples/minimal-project/docs/09-PLANNING/TASKS/demo-task/INDEX.md +60 -0
  48. package/examples/minimal-project/docs/09-PLANNING/TASKS/demo-task/findings.md +7 -0
  49. package/package.json +10 -4
  50. package/presets/legacy-migration/checks/preset-check.mjs +3 -0
  51. package/presets/legacy-migration/preset.yaml +134 -0
  52. package/presets/legacy-migration/scripts/plan-work-queue.mjs +4 -0
  53. package/presets/legacy-migration/scripts/scaffold-task-contracts.mjs +4 -0
  54. package/presets/legacy-migration/templates/execution_strategy.append.md +18 -0
  55. package/presets/legacy-migration/templates/findings.seed.md +17 -0
  56. package/presets/legacy-migration/templates/review.seed.md +12 -0
  57. package/presets/legacy-migration/templates/task_plan.append.md +9 -0
  58. package/presets/legacy-migration/templates/visual_map.append.md +12 -0
  59. package/presets/legacy-migration/workbench/dashboard-panels.yaml +2 -0
  60. package/presets/legacy-migration/workbench/migration-queue.schema.json +23 -0
  61. package/presets/lesson-sedimentation/preset.yaml +23 -0
  62. package/presets/lesson-sedimentation/templates/prompt.md +23 -0
  63. package/presets/module/preset.yaml +25 -0
  64. package/presets/module/templates/execution_strategy.append.md +8 -0
  65. package/presets/module/templates/task_plan.append.md +17 -0
  66. package/presets/standard-task/preset.yaml +31 -0
  67. package/presets/standard-task/templates/task_plan.append.md +7 -0
  68. package/references/adversarial-review-standard.md +2 -2
  69. package/references/agents-md-pattern.md +2 -2
  70. package/references/delivery-operating-model-standard.md +3 -3
  71. package/references/docs-directory-standard.md +6 -7
  72. package/references/harness-ledger.md +53 -96
  73. package/references/lessons-governance.md +88 -93
  74. package/references/module-parallel-standard.md +14 -14
  75. package/references/planning-loop.md +12 -6
  76. package/references/pull-request-standard.md +118 -0
  77. package/references/repo-governance-standard.md +11 -2
  78. package/references/review-routing-standard.md +7 -1
  79. package/references/ssot-governance.md +67 -59
  80. package/references/taskr-gap-analysis.md +600 -0
  81. package/references/walkthrough-closeout.md +7 -7
  82. package/scripts/check-harness.mjs +40 -301
  83. package/scripts/commands/dashboard-command.mjs +67 -0
  84. package/scripts/commands/migration-command.mjs +126 -0
  85. package/scripts/commands/preset-command.mjs +73 -0
  86. package/scripts/commands/task-command.mjs +328 -0
  87. package/scripts/harness.mjs +59 -260
  88. package/scripts/lib/capability-registry.mjs +82 -28
  89. package/scripts/lib/check-module-parallel.mjs +230 -0
  90. package/scripts/lib/check-profiles.mjs +90 -228
  91. package/scripts/lib/check-task-contracts.mjs +55 -0
  92. package/scripts/lib/core-shared.mjs +65 -2
  93. package/scripts/lib/dashboard-data.mjs +155 -24
  94. package/scripts/lib/dashboard-workbench.mjs +131 -12
  95. package/scripts/lib/dashboard-writer.mjs +20 -4
  96. package/scripts/lib/git-status-summary.mjs +46 -0
  97. package/scripts/lib/governance-index-generator.mjs +174 -0
  98. package/scripts/lib/governance-sync.mjs +611 -0
  99. package/scripts/lib/governance-table-boundary.mjs +175 -0
  100. package/scripts/lib/harness-core.mjs +6 -0
  101. package/scripts/lib/lesson-maintenance.mjs +36 -29
  102. package/scripts/lib/markdown-utils.mjs +33 -0
  103. package/scripts/lib/migration-planner.mjs +4 -6
  104. package/scripts/lib/migration-support.mjs +1 -1
  105. package/scripts/lib/phase-kind.mjs +50 -0
  106. package/scripts/lib/preset-audit-contracts.mjs +37 -0
  107. package/scripts/lib/preset-engine.mjs +494 -0
  108. package/scripts/lib/preset-registry.mjs +776 -0
  109. package/scripts/lib/preset-resource-contracts.mjs +83 -0
  110. package/scripts/lib/review-confirm-git-gate.mjs +248 -0
  111. package/scripts/lib/status-builder.mjs +88 -0
  112. package/scripts/lib/status-dashboard-renderer.mjs +105 -0
  113. package/scripts/lib/subagent-authorization-audit.mjs +196 -0
  114. package/scripts/lib/task-audit-metadata.mjs +385 -0
  115. package/scripts/lib/task-audit-migration.mjs +350 -0
  116. package/scripts/lib/task-completion-consistency.mjs +26 -0
  117. package/scripts/lib/task-index.mjs +93 -0
  118. package/scripts/lib/task-lesson-candidates.mjs +242 -0
  119. package/scripts/lib/task-lesson-sedimentation.mjs +326 -0
  120. package/scripts/lib/task-lifecycle/create-task-helpers.mjs +67 -0
  121. package/scripts/lib/task-lifecycle/phase-sync.mjs +88 -0
  122. package/scripts/lib/task-lifecycle/review-confirm.mjs +112 -0
  123. package/scripts/lib/task-lifecycle/review-gates.mjs +73 -0
  124. package/scripts/lib/task-lifecycle/review-submission.mjs +63 -0
  125. package/scripts/lib/task-lifecycle/scaffold-provenance.mjs +49 -0
  126. package/scripts/lib/task-lifecycle/template-files.mjs +53 -0
  127. package/scripts/lib/task-lifecycle/text-utils.mjs +24 -0
  128. package/scripts/lib/task-lifecycle.mjs +338 -477
  129. package/scripts/lib/task-metadata.mjs +118 -0
  130. package/scripts/lib/task-review-model.mjs +455 -0
  131. package/scripts/lib/task-scanner.mjs +193 -372
  132. package/scripts/lib/task-tombstone-commands.mjs +140 -0
  133. package/scripts/postinstall.mjs +14 -0
  134. package/skills/preset-creator/SKILL.md +179 -0
  135. package/skills/preset-creator/references/complex-task-skeleton/README.md +31 -0
  136. package/skills/preset-creator/references/complex-task-skeleton/artifacts/INDEX.md +12 -0
  137. package/skills/preset-creator/references/complex-task-skeleton/brief.md +43 -0
  138. package/skills/preset-creator/references/complex-task-skeleton/execution_strategy.md +71 -0
  139. package/skills/preset-creator/references/complex-task-skeleton/findings.md +24 -0
  140. package/skills/preset-creator/references/complex-task-skeleton/lesson_candidates.md +70 -0
  141. package/skills/preset-creator/references/complex-task-skeleton/long-running-task-contract.md +76 -0
  142. package/skills/preset-creator/references/complex-task-skeleton/progress.md +33 -0
  143. package/skills/preset-creator/references/complex-task-skeleton/references/INDEX.md +13 -0
  144. package/skills/preset-creator/references/complex-task-skeleton/review.md +107 -0
  145. package/skills/preset-creator/references/complex-task-skeleton/task_plan.md +111 -0
  146. package/skills/preset-creator/references/complex-task-skeleton/visual_map.md +50 -0
  147. package/skills/preset-creator/references/preset-package-skeleton.md +296 -0
  148. package/templates/AGENTS.md.template +24 -18
  149. package/templates/dashboard/assets/app-src/00-state.js +13 -0
  150. package/templates/dashboard/assets/app-src/10-router.js +5 -1
  151. package/templates/dashboard/assets/app-src/20-overview.js +18 -8
  152. package/templates/dashboard/assets/app-src/30-tasks.js +92 -246
  153. package/templates/dashboard/assets/app-src/35-task-detail.js +286 -0
  154. package/templates/dashboard/assets/app-src/45-review.js +241 -22
  155. package/templates/dashboard/assets/app-src/50-migration.js +24 -10
  156. package/templates/dashboard/assets/app-src/55-presets.js +375 -0
  157. package/templates/dashboard/assets/app-src/60-shared.js +3 -1
  158. package/templates/dashboard/assets/app-src/90-bindings.js +302 -29
  159. package/templates/dashboard/assets/app.css +1501 -376
  160. package/templates/dashboard/assets/app.css.manifest.json +10 -0
  161. package/templates/dashboard/assets/app.js +1240 -101
  162. package/templates/dashboard/assets/app.manifest.json +2 -0
  163. package/templates/dashboard/assets/css-src/00-foundation.css +346 -0
  164. package/templates/dashboard/assets/css-src/10-panels-flow.css +236 -0
  165. package/templates/dashboard/assets/css-src/20-briefs-controls.css +398 -0
  166. package/templates/dashboard/assets/css-src/30-task-index.css +739 -0
  167. package/templates/dashboard/assets/css-src/35-review-workspace.css +507 -0
  168. package/templates/dashboard/assets/css-src/40-detail-modules-migration.css +489 -0
  169. package/templates/dashboard/assets/css-src/45-presets.css +516 -0
  170. package/templates/dashboard/assets/css-src/50-responsive-overrides.css +551 -0
  171. package/templates/dashboard/assets/i18n.js +263 -23
  172. package/templates/ledger/Harness-Ledger.md +13 -25
  173. package/templates/lessons/lesson-arch-process-change.md +1 -1
  174. package/templates/lessons/lesson-new-doc.md +1 -1
  175. package/templates/lessons/lesson-ref-change.md +1 -1
  176. package/templates/planning/INDEX.md +87 -0
  177. package/templates/planning/brief.md +1 -1
  178. package/templates/planning/execution_strategy.md +31 -0
  179. package/templates/planning/lesson_candidates.md +18 -6
  180. package/templates/planning/module_session_prompt.md +1 -0
  181. package/templates/planning/optional/artifacts/INDEX.md +3 -3
  182. package/templates/planning/optional/references/INDEX.md +3 -3
  183. package/templates/planning/review.md +41 -0
  184. package/templates/planning/task_plan.md +5 -21
  185. package/templates/planning/visual_map.md +13 -9
  186. package/templates/planning/visual_map.simple.md +52 -0
  187. package/templates/reference/execution-workflow-standard.md +31 -3
  188. package/templates/reference/pull-request-standard.md +80 -0
  189. package/templates/reference/repo-governance-standard.md +7 -6
  190. package/templates/reference/review-routing-standard.md +6 -0
  191. package/templates/reference/walkthrough-standard.md +2 -1
  192. package/templates/verifier/verifier-output.md +1 -1
  193. package/templates-zh-CN/AGENTS.md.template +25 -19
  194. package/templates-zh-CN/ledger/Harness-Ledger.md +17 -40
  195. package/templates-zh-CN/planning/INDEX.md +87 -0
  196. package/templates-zh-CN/planning/brief.md +1 -1
  197. package/templates-zh-CN/planning/execution_strategy.md +30 -0
  198. package/templates-zh-CN/planning/lesson_candidates.md +18 -6
  199. package/templates-zh-CN/planning/module_session_prompt.md +1 -0
  200. package/templates-zh-CN/planning/review.md +41 -1
  201. package/templates-zh-CN/planning/task_plan.md +4 -44
  202. package/templates-zh-CN/planning/visual_map.md +14 -7
  203. package/templates-zh-CN/planning/visual_map.simple.md +48 -0
  204. package/templates-zh-CN/reference/adversarial-review-standard.md +1 -1
  205. package/templates-zh-CN/reference/docs-library-standard.md +1 -1
  206. package/templates-zh-CN/reference/execution-workflow-standard.md +33 -7
  207. package/templates-zh-CN/reference/harness-ledger-standard.md +2 -2
  208. package/templates-zh-CN/reference/pull-request-standard.md +106 -0
  209. package/templates-zh-CN/reference/repo-governance-standard.md +4 -3
  210. package/templates-zh-CN/reference/review-routing-standard.md +8 -1
  211. package/templates-zh-CN/reference/walkthrough-standard.md +3 -2
  212. package/templates-zh-CN/walkthrough/Closeout-SSoT.md +1 -1
  213. package/docs-release/assets/dashboard-overview-en.png +0 -0
  214. package/scripts/smoke-dashboard.mjs +0 -92
  215. package/scripts/test-harness.mjs +0 -1395
  216. package/templates/ssot/Feature-SSoT.md +0 -43
  217. package/templates/ssot/Lessons-SSoT.md +0 -44
  218. package/templates-zh-CN/ssot/Feature-SSoT.md +0 -49
  219. package/templates-zh-CN/ssot/Lessons-SSoT.md +0 -49
@@ -0,0 +1,37 @@
1
+ # Additional Permission for Generated Harness Materials
2
+
3
+ Copyright (c) 2026 ZeyuLi (FairladyZ)
4
+
5
+ Coding Agent Harness is licensed under the GNU Affero General Public License
6
+ version 3 or any later version (`AGPL-3.0-or-later`). This file grants an
7
+ additional permission under section 7 of the AGPL.
8
+
9
+ ## Generated Harness Materials
10
+
11
+ For the purposes of this permission, "Generated Harness Materials" means files
12
+ created, copied, rendered, scaffolded, or installed into a target project by
13
+ Coding Agent Harness from bundled or user-provided templates, presets, skills,
14
+ reference packs, examples, or documentation skeletons. This includes generated
15
+ or installed project governance files such as `AGENTS.md`, `CLAUDE.md`, task
16
+ plans, review files, ledgers, walkthroughs, generated dashboard data, and other
17
+ target-project harness documents.
18
+
19
+ ## Permission
20
+
21
+ You may use, copy, modify, merge, publish, distribute, sublicense, and/or sell
22
+ Generated Harness Materials under the license terms of the target project or
23
+ under any other terms chosen by that target project's copyright holder.
24
+
25
+ The AGPL does not apply to a target project, to that target project's source
26
+ code, or to Generated Harness Materials solely because Coding Agent Harness was
27
+ used to create, copy, render, scaffold, install, or update those materials.
28
+
29
+ ## Limits
30
+
31
+ This additional permission does not apply to Coding Agent Harness itself,
32
+ including its CLI/runtime source code, dashboard implementation, package source,
33
+ or the bundled templates, presets, skills, reference packs, examples, and
34
+ documentation as distributed in this repository or package.
35
+
36
+ This permission does not grant trademark rights or remove any third-party
37
+ license obligations that may apply independently.
package/README.md CHANGED
@@ -4,115 +4,123 @@
4
4
 
5
5
  English | [简体中文](README.zh-CN.md) | [日本語](docs-release/intl/ja-JP.md) | [한국어](docs-release/intl/ko-KR.md) | [Français](docs-release/intl/fr-FR.md) | [Español](docs-release/intl/es-ES.md) | [Deutsch](docs-release/intl/de-DE.md)
6
6
 
7
- Coding agents can write code quickly. The annoying part starts later: one session made a plan, another changed files, and the next agent has to guess what is still risky.
7
+ ![Coding Agent Harness architecture](docs-release/assets/harness-architecture.svg)
8
8
 
9
- Coding Agent Harness keeps that work in the repo: plans, progress, reviews, migration notes, and a dashboard that shows the current state.
9
+ > An open-source, document-native, ready-to-use Agent Harness for keeping Codex, Claude Code, Gemini CLI, and other coding agents clear, transparent, and reviewable during long-running software work.
10
10
 
11
- ![Coding Agent Harness dashboard overview](docs-release/assets/dashboard-overview-en.png)
11
+ ![Coding Agent Harness Dashboard](docs-release/assets/dashboard-overview.png)
12
12
 
13
- ## What It Looks Like
13
+ ## At A Glance
14
14
 
15
- The harness is just files plus a local dashboard.
15
+ Coding Agent Harness is not another collection of chat prompts. It turns the durable facts that coding agents need into repository files: entry agreements, task plans, execution evidence, regression results, dashboards, and closeout records.
16
16
 
17
- - `AGENTS.md` tells the next agent how this repo works.
18
- - `task_plan.md`, `progress.md`, and `review.md` keep the task from turning into chat history.
19
- - Checks and migration reports say what is safe, what is stale, and what still needs a human decision.
20
- - `harness dev` opens the dashboard for everyday review.
17
+ The smallest loop is:
21
18
 
22
- ## The Loop
19
+ - A human states the goal, and the agent reads the repository Harness first.
20
+ - The agent follows Diagnose → Decide → Scaffold → Configure → Verify → Deliver.
21
+ - The CLI and Dashboard expose status, risk, migration plans, and review evidence.
22
+ - The next agent resumes from repository facts instead of previous chat memory.
23
23
 
24
- | Step | Human Experience | Agent / CLI Surface |
25
- | --- | --- | --- |
26
- | Install | Give the agent one entrypoint. | `npx skills add FairladyZ625/coding-agent-harness --skill coding-agent-harness` |
27
- | Start | The agent scans first, then proposes an init or migration plan. | `npx --yes coding-agent-harness init ...` or `migrate-plan` |
28
- | Review | Open the dashboard and check the task state. | `npx --yes coding-agent-harness dev .` |
29
- | Verify | Run checks before handoff. | `npx --yes coding-agent-harness check --profile target-project .` |
24
+ ![Harness workflow](docs-release/assets/harness-workflow.svg)
30
25
 
31
- ## Try It In A Project
26
+ ## What It Is
32
27
 
33
- Use `npx` first. It does not add the CLI to your project dependencies.
28
+ Coding Agent Harness is a project engineering framework for AI coding agents.
34
29
 
35
- ```bash
36
- npx --yes coding-agent-harness init --locale en-US --capabilities core,dashboard .
37
- npx --yes coding-agent-harness dev .
38
- npx --yes coding-agent-harness check --profile target-project .
39
- ```
30
+ It adds working agreements, document structure, task lifecycle, regression evidence, and review loops directly into your repository so agents can read, execute, update, and verify the project from durable local facts.
40
31
 
41
- For Chinese templates:
32
+ ## Why It Exists
42
33
 
43
- ```bash
44
- npx --yes coding-agent-harness init --locale zh-CN --capabilities core,dashboard .
45
- ```
34
+ Generating a few thousand lines of code with AI is not the hard part. The hard part is keeping the agent oriented after days of work, preventing parallel agents from overwriting each other, and letting a new agent continue from repository facts instead of chat memory.
46
35
 
47
- If you want a static evidence snapshot instead of the live local workbench:
36
+ Coding Agent Harness turns those facts into part of the project.
48
37
 
49
- ```bash
50
- npx --yes coding-agent-harness dashboard --out-dir tmp/harness-dashboard .
51
- open tmp/harness-dashboard/index.html
52
- ```
38
+ ## Core Strengths
53
39
 
54
- ## What The Agent Reads
40
+ ### Open Source, Simple, Ready To Use
55
41
 
56
- Harness is ordinary repository content. There is no database to run.
42
+ Harness runs as ordinary project files: Markdown, templates, check scripts, static dashboard snapshots, and an optional local dynamic Workbench. The core package has no third-party runtime dependencies and does not require a background service or database. When a human needs web actions, `harness dev` starts a temporary localhost-only workbench.
57
43
 
58
- ```text
59
- AGENTS.md
60
- docs/
61
- 03-ARCHITECTURE/
62
- 04-DEVELOPMENT/
63
- 05-TEST-QA/
64
- 09-PLANNING/TASKS/
65
- 10-WALKTHROUGH/
66
- 11-REFERENCE/
67
- ```
44
+ Give the installation prompt to your agent, and it can initialize, scan, migrate, and verify the target project.
68
45
 
69
- Typical task files:
46
+ ### Compatible With Coding Agents
70
47
 
71
- ```text
72
- task_plan.md
73
- execution_strategy.md
74
- visual_map.md
75
- progress.md
76
- review.md
77
- lesson_candidates.md
78
- ```
48
+ Any agent that can read files, write files, and run commands can use this Harness. It works with Codex, Claude Code, Gemini CLI, Cursor-style agents, OpenClaw, and similar coding agents.
49
+
50
+ ### Document-Native And Transparent
51
+
52
+ Important project state stays visible in the repository:
53
+
54
+ - what the current task is
55
+ - why it matters
56
+ - how it should be executed
57
+ - where the evidence is
58
+ - whether regression passed
59
+ - what residual risks remain
60
+ - which tasks are complete and which still need work
61
+
62
+ Humans can read briefs, dashboards, and migration reports. Agents can read structured docs, task contracts, and check results.
63
+
64
+ ### Built For Long-Running Work
65
+
66
+ Harness covers the continuity layer of real development: task lifecycle, Brief, Execution Strategy, Visual Map, Progress Log, Review, Regression Evidence, Closeout, and Lessons.
79
67
 
80
- Humans scan the dashboard. Agents read the files. That is the whole trick.
68
+ It gives each agent step context, evidence, and a finish condition.
81
69
 
82
- ## Language Support
70
+ ### Reusable Presets For Task Families
83
71
 
84
- | Language | Public intro | README / guides | Executable templates |
85
- | --- | --- | --- | --- |
86
- | English | Full | Full | Full |
87
- | Simplified Chinese | Full | Full | Full |
88
- | Japanese | Intro | Routing only | Use English templates |
89
- | Korean | Intro | Routing only | Use English templates |
90
- | French | Intro | Routing only | Use English templates |
91
- | Spanish | Intro | Routing only | Use English templates |
92
- | German | Intro | Routing only | Use English templates |
72
+ A preset is a versioned, declarative task method package. It does not install a
73
+ new agent and it does not replace the Harness. It tells `harness new-task` how
74
+ to create a task for a repeatable work type: what task kind to set, which inputs
75
+ to ask for, which shared references or artifacts to copy into the task, which
76
+ files the agent must read first, and what audit/evidence files should prove the
77
+ task was created correctly.
93
78
 
94
- Intro-only pages are deliberately small. Agent-executable templates stay in English and Simplified Chinese first, because stale translated instructions are worse than no translation.
79
+ Use presets when a group of tasks share the same setup. For example, several
80
+ interface tasks may all depend on the same upstream microservice contract,
81
+ fixture packet, runbook, and verification checklist. Instead of repeating that
82
+ context in every prompt, put it in a preset and create each task with
83
+ `harness new-task --preset <preset-id> ...`.
84
+
85
+ Harness ships bundled presets, `harness init` seeds them into the target project,
86
+ and teams can add project-local presets under `.coding-agent-harness/presets/`.
87
+ The `preset-creator` Skill is for authoring these preset packages; the Harness
88
+ CLI is what checks, installs, lists, and applies them.
89
+
90
+ ### Safe Migration For Existing Projects
91
+
92
+ Legacy project migration starts with a scan, a migration plan, a recommended migration mode, and user confirmation. Only then should the agent write files. Final status is proven with a dashboard and checks.
95
93
 
96
94
  ## Good Fit
97
95
 
98
- This is useful when:
96
+ Coding Agent Harness is useful for:
99
97
 
100
- - agents work on real repositories for days or weeks;
101
- - multiple agents or developers share the same project;
102
- - task state, review evidence, and regression results need to survive across sessions;
103
- - an existing project has old plans, migration notes, or scattered agent instructions;
104
- - the important parts of AI work should not live only in chat logs.
98
+ - teams using coding agents on real software projects;
99
+ - projects that run for days, weeks, or many iterations;
100
+ - work involving multiple agents or multiple developers;
101
+ - repositories with historical task docs, regression records, or migration notes;
102
+ - teams that want AI development to be visible, reviewable, and reusable.
105
103
 
106
- ## Install The Skill
104
+ ## Quick Start
107
105
 
108
- If your agent supports Skills:
106
+ ### Install The Skills
107
+
108
+ If your agent supports Skills, inspect this repository's Skill entries with `npx`.
109
+ Because the repository has a root Skill plus nested Skills, use `--full-depth`
110
+ when you want to see or install `preset-creator`:
109
111
 
110
112
  ```bash
111
- npx skills add FairladyZ625/coding-agent-harness --list
113
+ npx skills add FairladyZ625/coding-agent-harness --list --full-depth
112
114
  npx skills add FairladyZ625/coding-agent-harness --skill coding-agent-harness
115
+ npx skills add FairladyZ625/coding-agent-harness --skill preset-creator --full-depth
113
116
  ```
114
117
 
115
- Install into the global Codex skill directory:
118
+ Use the Skills separately:
119
+
120
+ - `coding-agent-harness`: for installing, migrating, operating, and reviewing a Harness inside a target project.
121
+ - `preset-creator`: for authoring reusable Harness preset packages when a family of tasks shares a method, external references, artifacts, evidence requirements, or complex-task skeleton overlays. This Skill includes its own Complex Task skeleton reference, so an agent can build a correct preset without already knowing Harness internals.
122
+
123
+ Install a Skill into the global Codex skill directory:
116
124
 
117
125
  ```bash
118
126
  npx skills add FairladyZ625/coding-agent-harness \
@@ -122,40 +130,183 @@ npx skills add FairladyZ625/coding-agent-harness \
122
130
  -y
123
131
  ```
124
132
 
125
- Agents should not silently run a global npm install. If a long-lived `harness` command is desired, ask the human first:
133
+ For the Preset Creator Skill:
134
+
135
+ ```bash
136
+ npx skills add FairladyZ625/coding-agent-harness \
137
+ --skill preset-creator \
138
+ --full-depth \
139
+ --agent codex \
140
+ --global \
141
+ -y
142
+ ```
143
+
144
+ The CLI is not automatically added to the target project's dependencies. Use `npx` when you need to run Harness commands. The first run downloads the package into the local npm cache; it does not write to the target project:
145
+
146
+ ```bash
147
+ npx --yes coding-agent-harness init --locale zh-CN --capabilities core,dashboard .
148
+ npx --yes coding-agent-harness dev .
149
+ npx --yes coding-agent-harness check --profile target-project .
150
+ ```
151
+
152
+ If you want to use `harness` as a long-lived system command, install it globally:
126
153
 
127
154
  ```bash
128
155
  npm install -g coding-agent-harness
129
156
  harness --help
130
157
  ```
131
158
 
132
- ## Agent Prompt
159
+ The npm install seeds bundled presets into `~/.coding-agent-harness/presets/`.
160
+ `harness init` also seeds those presets into the target project at
161
+ `.coding-agent-harness/presets/`, so agents can discover stable task methods
162
+ with `harness preset list --json`.
163
+
164
+ Agents must not silently run a global install. They may run `npm install -g coding-agent-harness` only after the user explicitly approves changing the global npm environment. Without that approval, keep using `npx --yes coding-agent-harness ...`.
165
+
166
+ ### Commands For Humans
167
+
168
+ Initialize a Chinese Harness:
169
+
170
+ ```bash
171
+ npx --yes coding-agent-harness init --locale zh-CN --capabilities core,dashboard .
172
+ ```
173
+
174
+ Start the local dynamic Workbench:
175
+
176
+ ```bash
177
+ npx --yes coding-agent-harness dev .
178
+ ```
133
179
 
134
- Send this to an agent inside your target project:
180
+ The Workbench includes a Presets view for checking, installing, seeding, and
181
+ uninstalling project or user presets. Static dashboards show the same preset
182
+ catalog as read-only evidence.
183
+
184
+ Generate a static Dashboard that can be opened offline:
185
+
186
+ ```bash
187
+ npx --yes coding-agent-harness dashboard --out-dir tmp/harness-dashboard .
188
+ open tmp/harness-dashboard/index.html
189
+ ```
190
+
191
+ Run target-project checks:
192
+
193
+ ```bash
194
+ npx --yes coding-agent-harness check --profile target-project .
195
+ ```
196
+
197
+ ### Prompt For Agents
198
+
199
+ Send this to the agent inside your target project:
135
200
 
136
201
  ```text
137
202
  Install and read Coding Agent Harness first:
138
203
 
139
204
  npx skills add FairladyZ625/coding-agent-harness --skill coding-agent-harness
140
205
 
141
- First diagnose the project structure, then give me an initialization or migration plan.
206
+ First check whether this environment has the harness command.
207
+
208
+ If it does not, do not silently install globally. Ask me first:
209
+ "This environment does not have the harness command. May I run npm install -g coding-agent-harness?
210
+ This changes the global npm environment and then lets you use harness directly.
211
+ If you do not approve, I will use npx --yes coding-agent-harness ... temporarily and will not write to project dependencies."
212
+
213
+ Only after I explicitly approve, run:
214
+ npm install -g coding-agent-harness
215
+ harness preset list --json
216
+
217
+ If I do not approve or do not respond, run CLI commands with:
218
+ npx --yes coding-agent-harness <command>
219
+
220
+ Set up Coding Agent Harness in the current project.
221
+ Use Chinese templates by default. If the project is clearly an English team or English documentation project, ask me before switching to English.
222
+
223
+ First diagnose the project structure, then give me an initialization plan.
224
+ If this is a microservice, multi-repo, split frontend/backend, or externally integrated project, proactively ask me whether I have external architecture docs, API docs, diagrams, meeting notes, links, source paths, or exported packets.
225
+ If the external material is large, create an external-source-packs index and digests first, then project stable conclusions into 03-ARCHITECTURE / 04-DEVELOPMENT / 06-INTEGRATIONS.
226
+ After confirmation, execute Diagnose → Decide → Scaffold → Configure → Verify → Deliver.
227
+ When initializing, run:
228
+ npx --yes coding-agent-harness init --locale zh-CN --capabilities core,dashboard .
229
+ npx --yes coding-agent-harness preset list --json .
230
+
231
+ After initialization, use the dynamic web UI for daily viewing and human confirmations:
232
+ npx --yes coding-agent-harness dev .
233
+
234
+ If you only need an offline evidence snapshot, generate a static dashboard:
235
+ npx --yes coding-agent-harness dashboard --out-dir tmp/harness-dashboard .
236
+
142
237
  Do not overwrite existing business docs, historical tasks, regression records, or user changes.
238
+ When finished, report created files, check results, and recommended next steps.
239
+ ```
143
240
 
144
- Use npx unless I explicitly approve a global npm install:
241
+ If the target already has an older Harness, use this:
242
+
243
+ ```text
244
+ Install and read Coding Agent Harness first:
245
+
246
+ npx skills add FairladyZ625/coding-agent-harness --skill coding-agent-harness
247
+
248
+ First check whether this environment has the harness command.
249
+
250
+ If it does not, do not silently install globally. Ask me first:
251
+ "This environment does not have the harness command. May I run npm install -g coding-agent-harness?
252
+ This changes the global npm environment and then lets you use harness directly.
253
+ If you do not approve, I will use npx --yes coding-agent-harness ... temporarily and will not write to project dependencies."
254
+
255
+ Only after I explicitly approve, run:
256
+ npm install -g coding-agent-harness
257
+ harness preset list --json
258
+
259
+ If I do not approve or do not respond, run CLI commands with:
145
260
  npx --yes coding-agent-harness <command>
146
261
 
147
- After confirmation, execute Diagnose -> Decide -> Scaffold -> Configure -> Verify -> Deliver.
148
- When finished, report created files, check results, Dashboard URL or HTML path, and recommended next steps.
262
+ This project already has an older Harness. Do not edit files yet.
263
+
264
+ First run a detailed scan and give me a migration plan:
265
+ 1. Check git status, Harness status, task count, brief coverage, visual_map coverage, warnings/actions/residuals, strict status, and dashboard usability.
266
+ 2. If this is a microservice, multi-repo, split frontend/backend, or externally integrated project, proactively ask me for external source material; when the material is large, create an external-source-packs index and digests before projecting facts into 03/04/06.
267
+ 3. Recommend the migration mode from project evidence:
268
+ - baseline-preserve: safe adoption first; only add necessary structure and visibility.
269
+ - status-aware-rewrite: rewrite current or reopened tasks from SSoT, Ledger, progress, review, and git evidence.
270
+ - full-semantic-rewrite: rewrite task briefs / execution_strategy / visual_map so the old project becomes v1.0-readable.
271
+ 4. Report the recommended mode, rationale, expected write scope, estimated token/time cost, risks, and whether subagents are needed.
272
+ 5. Ask me the confirmation questions you need, then wait for my confirmation before writing files.
273
+
274
+ During the scan phase, run at least:
275
+ npx --yes coding-agent-harness status --json .
276
+ npx --yes coding-agent-harness migrate-plan --json --limit 1000 .
277
+
278
+ When the migration is complete, report the dynamic workbench URL or static dashboard HTML, session.json, normal/strict checks, migrate-plan summary, and whether full-cutover verification passes. If human review confirmation is required, expose that action in the local web workbench; static dashboards are read-only evidence snapshots.
279
+ ```
280
+
281
+ ## Contributing
282
+
283
+ External contributors should start with [`CONTRIBUTING.md`](CONTRIBUTING.md). It covers repository layout, pull request expectations, root package checks, Dashboard smoke tests, npm package dry runs, and GUI submodule validation. The detailed public workflow also lives in [`docs-release/guides/contributing.md`](docs-release/guides/contributing.md).
284
+
285
+ If you want your coding agent to make a contribution, send it this prompt:
286
+
287
+ ```text
288
+ I want to contribute a focused change to FairladyZ625/coding-agent-harness.
289
+
290
+ Start from the latest main branch and create a new feature branch. Read README.md and CONTRIBUTING.md first. Before editing files, inspect the relevant code/docs and give me a short plan.
291
+
292
+ Keep the change scoped. Use only public repository files and do not rely on maintainer-local state, hidden workflows, credentials, generated dashboards, temporary files, or ignored local-only files.
293
+
294
+ Run the checks that match the change. For docs-only changes, run git diff --check. For root package changes, run npm install, npm test, npm run smoke:dashboard, npm run check, node scripts/harness.mjs check --profile target-project examples/minimal-project, npm run pack:dry-run, and git diff --check as relevant. If the change touches harness-gui, also run cd harness-gui && npm ci && npm run typecheck && npm test && npm run build.
295
+
296
+ When done, summarize what changed, list verification results, call out any skipped checks with reasons, and prepare the PR using the repository template.
149
297
  ```
150
298
 
151
299
  ## Learn More
152
300
 
153
- - Docs release index: [`docs-release/README.md`](docs-release/README.md)
301
+ - Contributor guide: [`CONTRIBUTING.md`](CONTRIBUTING.md)
302
+ - Detailed contributor guide: [`docs-release/guides/contributing.md`](docs-release/guides/contributing.md)
154
303
  - Agent installation guide: [`docs-release/guides/agent-installation.en-US.md`](docs-release/guides/agent-installation.en-US.md)
155
- - Architecture overview: [`docs-release/architecture/overview.md`](docs-release/architecture/overview.md)
156
- - Migration playbook: [`docs-release/guides/migration-playbook.en-US.md`](docs-release/guides/migration-playbook.en-US.md)
157
- - Operating models: [`docs-release/guides/repository-operating-models.en-US.md`](docs-release/guides/repository-operating-models.en-US.md)
158
304
  - Minimal project example: [`examples/minimal-project/`](examples/minimal-project/)
305
+ - Legacy migration playbook: [`docs-release/guides/migration-playbook.en-US.md`](docs-release/guides/migration-playbook.en-US.md)
306
+ - Full legacy migration strategy: [`docs-release/guides/full-legacy-migration-subagent-strategy.md`](docs-release/guides/full-legacy-migration-subagent-strategy.md)
307
+ - Architecture overview: [`docs-release/architecture/overview.md`](docs-release/architecture/overview.md)
308
+ - Deep architecture explainer (zh-CN): [`docs-release/architecture/system-explainer/`](docs-release/architecture/system-explainer/) — system design, module dependencies, task lifecycle, check system, data flow, and preset/migration engine with design rationale
309
+ - Deep architecture explainer (en-US): [`docs-release/architecture/system-explainer/en-US/`](docs-release/architecture/system-explainer/en-US/)
159
310
 
160
311
  ## Star History
161
312
 
@@ -163,4 +314,10 @@ When finished, report created files, check results, Dashboard URL or HTML path,
163
314
 
164
315
  ## License
165
316
 
166
- MIT
317
+ AGPL-3.0-or-later with an additional permission for Generated Harness
318
+ Materials.
319
+
320
+ See [`LICENSE`](LICENSE) and [`LICENSE-EXCEPTION.md`](LICENSE-EXCEPTION.md).
321
+ The additional permission keeps files generated or installed into a target
322
+ project from becoming AGPL-covered solely because Coding Agent Harness created
323
+ or updated them.