create-harness-vibe-coding 0.8.6 → 0.8.8

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 (93) hide show
  1. package/README-CN.md +157 -105
  2. package/README.md +160 -244
  3. package/bin/create-harness-vibe-coding.js +2 -2
  4. package/docs/images/harness-architecture-light.png +0 -0
  5. package/docs/images/harness-architecture.drawio +164 -0
  6. package/package.json +46 -44
  7. package/src/generator.js +30 -11
  8. package/src/index.js +143 -14
  9. package/src/prompts.js +37 -37
  10. package/templates/common/.claude/agents/architect-manager.md +45 -45
  11. package/templates/common/.claude/agents/context-master.md +75 -75
  12. package/templates/common/.claude/agents/debugger.md +41 -41
  13. package/templates/common/.claude/agents/explore-manager.md +41 -41
  14. package/templates/common/.claude/agents/implement-manager.md +49 -49
  15. package/templates/common/.claude/agents/implementer.md +40 -40
  16. package/templates/common/.claude/agents/memory-master.md +64 -64
  17. package/templates/common/.claude/agents/planner.md +34 -34
  18. package/templates/common/.claude/agents/reflector.md +35 -0
  19. package/templates/common/.claude/agents/researcher.md +41 -41
  20. package/templates/common/.claude/agents/review-manager.md +56 -56
  21. package/templates/common/.claude/agents/verifier.md +34 -32
  22. package/templates/common/.claude/commands/wf-help.md +2 -3
  23. package/templates/common/.claude/rules/ecc/common.md +44 -44
  24. package/templates/common/.claude/skills/subagent-orchestrator/SKILL.md +10 -4
  25. package/templates/common/.claude/skills/wf/SKILL.md +7 -3
  26. package/templates/common/.claude/skills/wf-auto/SKILL.md +61 -107
  27. package/templates/common/.claude/skills/wf-auto-spark/SKILL.md +19 -17
  28. package/templates/common/.claude/skills/wf-max/SKILL.md +40 -21
  29. package/templates/common/.claude/skills/wf-readme/SKILL.md +49 -49
  30. package/templates/common/.claude/skills/wf-remove/SKILL.md +7 -7
  31. package/templates/common/.claude/skills/wf-update/SKILL.md +9 -4
  32. package/templates/common/.codex/config.toml +5 -0
  33. package/templates/common/.harness-version +78 -36
  34. package/templates/common/.opencode/agents/architect-manager.md +52 -0
  35. package/templates/common/.opencode/agents/architect.md +35 -0
  36. package/templates/common/.opencode/agents/context-master.md +81 -0
  37. package/templates/common/.opencode/agents/debugger.md +43 -0
  38. package/templates/common/.opencode/agents/docs-researcher.md +42 -0
  39. package/templates/common/.opencode/agents/explore-manager.md +49 -0
  40. package/templates/common/.opencode/agents/implement-manager.md +56 -0
  41. package/templates/common/.opencode/agents/implementer.md +42 -0
  42. package/templates/common/.opencode/agents/memory-master.md +70 -0
  43. package/templates/common/.opencode/agents/planner.md +38 -0
  44. package/templates/common/.opencode/agents/reflector.md +39 -0
  45. package/templates/common/.opencode/agents/researcher.md +42 -0
  46. package/templates/common/.opencode/agents/review-manager.md +63 -0
  47. package/templates/common/.opencode/agents/reviewer.md +37 -0
  48. package/templates/common/.opencode/agents/tdd-guide.md +83 -0
  49. package/templates/common/.opencode/agents/test-writer.md +54 -0
  50. package/templates/common/.opencode/agents/verifier.md +37 -0
  51. package/templates/common/.opencode/commands/wf-help.md +23 -0
  52. package/templates/common/AGENTS.md +26 -25
  53. package/templates/common/CLAUDE.md +86 -88
  54. package/templates/common/Harness/ACCEPTANCE_PROTOCOL.md +12 -4
  55. package/templates/common/Harness/PROGRESS.md +17 -17
  56. package/templates/common/Harness/README.md +26 -16
  57. package/templates/common/Harness/WF-AUTO-ANGLES.md +170 -0
  58. package/templates/common/Harness/WF-AUTO-SPARK.md +23 -6
  59. package/templates/common/Harness/WF-AUTO.md +508 -493
  60. package/templates/common/Harness/WF-MAX.md +284 -232
  61. package/templates/common/Harness/WF.md +47 -29
  62. package/templates/common/Harness/agent-workflow.md +108 -76
  63. package/templates/common/Harness/architecture.md +124 -124
  64. package/templates/common/Harness/context-loading.md +111 -111
  65. package/templates/common/Harness/dispatch.md +96 -95
  66. package/templates/common/Harness/extension.md +67 -67
  67. package/templates/common/Harness/lifecycle.md +20 -20
  68. package/templates/common/Harness/research/PRD.md +56 -56
  69. package/templates/common/Harness/research/README.md +169 -169
  70. package/templates/common/Harness/research/research-results.md +66 -66
  71. package/templates/common/Harness/subagents.md +192 -170
  72. package/templates/common/Harness/tasks/_template/ARTIFACTS.md +3 -3
  73. package/templates/common/Harness/tasks/_template/NOTES.md +3 -3
  74. package/templates/common/Harness/tasks/_template/PLAN.md +53 -60
  75. package/templates/common/Harness/tasks/_template/PROGRESS.md +26 -29
  76. package/templates/common/MEMORY.md +27 -30
  77. package/templates/common/README.md +36 -36
  78. package/templates/common/SETUP.md +1 -1
  79. package/templates/common/memory/agent-lessons-patterns.md +21 -21
  80. package/templates/common/memory/tool-usage-reflections.md +21 -21
  81. package/templates/common/memory/user-corrections-preferences.md +21 -21
  82. package/templates/common/opencode.json +19 -0
  83. package/templates/common/scripts/scan-clean.mjs +487 -448
  84. package/templates/common/scripts/validate-harness.mjs +245 -146
  85. package/templates/common/scripts/wf-remove.mjs +311 -293
  86. package/templates/common/scripts/wf-update-check.mjs +511 -311
  87. package/templates/optional/catalog.json +41 -33
  88. package/templates/optional/skills/browser-e2e/.claude/skills/wf-browser/SKILL.md +194 -194
  89. package/templates/optional/skills/browser-e2e/Harness/workflows/browser-e2e.md +105 -69
  90. package/templates/optional/skills/github-pr-review/Harness/workflows/github-pr-review.md +28 -28
  91. package/templates/optional/skills/python-backend/Harness/workflows/python-backend.md +34 -34
  92. package/templates/optional/skills/ts-react-frontend/Harness/workflows/ts-react-frontend.md +34 -34
  93. package/templates/optional/skills/ui-ux-review/Harness/workflows/ui-ux-review.md +26 -26
@@ -1,142 +1,142 @@
1
- # Context Loading Protocol
2
-
3
- Use when context is growing, subagents are needed, or an agent is unsure which harness doc applies.
4
-
5
- ## Routing Authority
6
-
7
- `Harness/README.md` is the primary router. This file is a secondary context-splitting protocol for subagents and long tasks.
8
-
9
- If this file and `Harness/README.md` disagree, follow `Harness/README.md`, record the assumption in `Harness/tasks/<task-id>/PROGRESS.md`, and update this file later.
10
-
11
- project files are the only durable communication channel; chat/subagent transcript state is non-authoritative. Important assumptions, decisions, blockers, evidence, and handoffs must be written to `Harness/tasks/<task-id>/PROGRESS.md` and `Harness/tasks/<task-id>/PLAN.md`, the current feature doc, `Harness/MEMORY.md`, or `Harness/memory/*` as appropriate.
12
-
13
- ## Main Context
14
-
15
- Always keep:
16
-
17
- - `CLAUDE.md`
18
- - `Harness/MEMORY.md`
19
- - `Harness/README.md`
20
- - `Harness/PROGRESS.md` when active
21
- - `Harness/tasks/<task-id>/PROGRESS.md` when active
22
- - `Harness/tasks/<task-id>/PLAN.md` when active
23
- - current feature doc when active
24
-
25
- Load other docs only by trigger.
26
-
27
- ## Trigger Matrix
28
-
29
- | Trigger | Load |
30
- | --- | --- |
1
+ # Context Loading Protocol
2
+
3
+ Use when context is growing, subagents are needed, or an agent is unsure which harness doc applies.
4
+
5
+ ## Routing Authority
6
+
7
+ `Harness/README.md` is the primary router. This file is a secondary context-splitting protocol for subagents and long tasks.
8
+
9
+ If this file and `Harness/README.md` disagree, follow `Harness/README.md`, record the assumption in `Harness/tasks/<task-id>/PROGRESS.md`, and update this file later.
10
+
11
+ project files are the only durable communication channel; chat/subagent transcript state is non-authoritative. Important assumptions, decisions, blockers, evidence, and handoffs must be written to `Harness/tasks/<task-id>/PROGRESS.md` and `Harness/tasks/<task-id>/PLAN.md`, the current feature doc, `Harness/MEMORY.md`, or `Harness/memory/*` as appropriate.
12
+
13
+ ## Main Context
14
+
15
+ Always keep:
16
+
17
+ - `CLAUDE.md`
18
+ - `Harness/MEMORY.md`
19
+ - `Harness/README.md`
20
+ - `Harness/PROGRESS.md` when active
21
+ - `Harness/tasks/<task-id>/PROGRESS.md` when active
22
+ - `Harness/tasks/<task-id>/PLAN.md` when active
23
+ - current feature doc when active
24
+
25
+ Load other docs only by trigger.
26
+
27
+ ## Trigger Matrix
28
+
29
+ | Trigger | Load |
30
+ | --- | --- |
31
31
  | idea, scope, MVP | `Harness/lifecycle.md`, `Harness/research/PRD.md`, `Harness/ACCEPTANCE_PROTOCOL.md` |
32
32
  | acceptance, AC, criteria, contract, validation matrix | `Harness/ACCEPTANCE_PROTOCOL.md`, `Harness/AGENT_ISOLATION.md`, `Harness/HARNESS_BRIDGE.md` as needed |
33
33
  | research, competitors, stack choice | `Harness/research/README.md`, `Harness/research/research-results.md` |
34
- | task split, owner, write set | `Harness/tasks/<task-id>/PROGRESS.md`, `Harness/tasks/<task-id>/PLAN.md`, `Harness/agent-workflow.md` |
35
- | parallel agents, dispatch, worktree decision | `Harness/subagents.md`, `Harness/dispatch.md`, `Harness/tasks/<task-id>/PLAN.md` |
36
- | `/wf` mode, long task, multi-file, multi-agent | `Harness/WF.md`, `Harness/subagents.md`, `Harness/dispatch.md`, `Harness/tasks/<task-id>/PLAN.md` |
37
- | `/wf max`, 5+ disjoint files, maximum parallelism | `Harness/WF-MAX.md`, `Harness/subagents.md`, `Harness/dispatch.md`, `Harness/tasks/<task-id>/PLAN.md` |
34
+ | task split, owner, write set | `Harness/tasks/<task-id>/PROGRESS.md`, `Harness/tasks/<task-id>/PLAN.md`, `Harness/agent-workflow.md` |
35
+ | parallel agents, dispatch, worktree decision | `Harness/subagents.md`, `Harness/dispatch.md`, `Harness/tasks/<task-id>/PLAN.md` |
36
+ | `/wf` mode, long task, multi-file, multi-agent | `Harness/WF.md`, `Harness/subagents.md`, `Harness/dispatch.md`, `Harness/tasks/<task-id>/PLAN.md` |
37
+ | `/wf max`, 5+ disjoint files, maximum parallelism | `Harness/WF-MAX.md`, `Harness/subagents.md`, `Harness/dispatch.md`, `Harness/tasks/<task-id>/PLAN.md` |
38
38
  | memory, scenario memory, repeated tool failure, repeated user correction, reusable lesson | `Harness/MEMORY.md`, `Harness/MEMORY_PROTOCOL.md`, the relevant `Harness/memory/*.md` file |
39
39
  | subagent spawn | `Harness/subagents.md`, `Harness/AGENT_ISOLATION.md`, this file plus the role pack below |
40
-
41
- ## ECC Rules Per Role
42
-
43
- Each subagent role loads a specific ECC rule subset. The dispatcher MUST include
44
- `ecc` in the dispatch packet so the subagent knows which rules to read first.
45
-
46
- | Role | Frontend Task | Backend Task | Full-Stack Task |
47
- |------|--------------|-------------|-----------------|
48
- | **Explorer** | `web/patterns.md`, `web/design-quality.md` | `common/patterns.md`, stack patterns | All |
49
- | **Planner** | `common/patterns.md`, `web/patterns.md` | `common/patterns.md`, stack patterns | All |
50
- | **Architect** | `web/patterns.md`, `web/performance.md` | `common/patterns.md`, `python/fastapi.md` or `golang/patterns.md` | All + API contract |
51
- | **Implementer (FE)** | `web/design-quality.md`, `web/patterns.md`, `web/performance.md`, `typescript/patterns.md` | N/A | Frontend subset |
52
- | **Implementer (BE)** | N/A | `common/patterns.md`, `python/fastapi.md` or `golang/patterns.md` | Backend subset |
53
- | **Test Writer** | `web/testing.md`, `typescript/testing.md` | Stack testing rules | Both |
54
- | **Reviewer** | `web/design-quality.md`, `web/security.md`, `web/performance.md` | Stack security + testing rules | All |
40
+
41
+ ## ECC Rules Per Role
42
+
43
+ Each subagent role loads a specific ECC rule subset. The dispatcher MUST include
44
+ `ecc` in the dispatch packet so the subagent knows which rules to read first.
45
+
46
+ | Role | Frontend Task | Backend Task | Full-Stack Task |
47
+ |------|--------------|-------------|-----------------|
48
+ | **Explorer** | `web/patterns.md`, `web/design-quality.md` | `common/patterns.md`, stack patterns | All |
49
+ | **Planner** | `common/patterns.md`, `web/patterns.md` | `common/patterns.md`, stack patterns | All |
50
+ | **Architect** | `web/patterns.md`, `web/performance.md` | `common/patterns.md`, `python/fastapi.md` or `golang/patterns.md` | All + API contract |
51
+ | **Implementer (FE)** | `web/design-quality.md`, `web/patterns.md`, `web/performance.md`, `typescript/patterns.md` | N/A | Frontend subset |
52
+ | **Implementer (BE)** | N/A | `common/patterns.md`, `python/fastapi.md` or `golang/patterns.md` | Backend subset |
53
+ | **Test Writer** | `web/testing.md`, `typescript/testing.md` | Stack testing rules | Both |
54
+ | **Reviewer** | `web/design-quality.md`, `web/security.md`, `web/performance.md` | Stack security + testing rules | All |
55
55
  | **Debugger** | Stack-specific coding-style + patterns | Stack-specific coding-style + patterns | Context-dependent |
56
- | **Verifier** | `web/testing.md` | Stack testing rules | Both |
57
-
58
- ## Subagent Packs
59
-
60
- Each pack now includes `ecc` — the ECC rule files this role MUST load first.
61
-
62
- Explorer Pass:
63
- - ecc: `common/patterns.md` + stack-specific patterns (see ECC Rules Per Role)
64
- - inject: question, read boundary, relevant docs
65
- - forbid: writes
66
- - return: files found, facts, risks, suggested tests
67
-
56
+ | **Verifier** | `web/testing.md` | Stack testing rules | Both |
57
+
58
+ ## Subagent Packs
59
+
60
+ Each pack now includes `ecc` — the ECC rule files this role MUST load first.
61
+
62
+ Explorer Pass:
63
+ - ecc: `common/patterns.md` + stack-specific patterns (see ECC Rules Per Role)
64
+ - inject: question, read boundary, relevant docs
65
+ - forbid: writes
66
+ - return: files found, facts, risks, suggested tests
67
+
68
68
  Planner:
69
69
  - ecc: `common/patterns.md` + `common/development-workflow.md`
70
70
  - inject: user goal, lifecycle phase, PRD or PLAN section, acceptance gate status, dispatch constraints
71
71
  - forbid: production code
72
72
  - return: tasks, dependencies, read/write sets, dispatch table, gates, open questions
73
-
74
- Researcher:
75
- - ecc: none (uses WebSearch/WebFetch, not code rules)
76
- - inject: question, decision needed, source boundaries, tool options
77
- - forbid: production code
78
- - return: sources, adopted/rejected/watch decisions, risks, research-results.md patch
79
-
80
- Docs Researcher:
81
- - ecc: none (uses official docs, not code rules)
82
- - inject: library/API/config, implementation question, version/date constraints
83
- - forbid: production code
84
- - return: official links, constraints, errors, examples, affected docs
85
-
86
- Architect:
87
- - ecc: `common/patterns.md` + stack-specific (web/patterns.md for FE, python/fastapi.md for BE)
88
- - inject: PRD, current architecture, ports
89
- - forbid: implementation
90
- - return: boundary decision, affected docs, risks
91
-
73
+
74
+ Researcher:
75
+ - ecc: none (uses WebSearch/WebFetch, not code rules)
76
+ - inject: question, decision needed, source boundaries, tool options
77
+ - forbid: production code
78
+ - return: sources, adopted/rejected/watch decisions, risks, research-results.md patch
79
+
80
+ Docs Researcher:
81
+ - ecc: none (uses official docs, not code rules)
82
+ - inject: library/API/config, implementation question, version/date constraints
83
+ - forbid: production code
84
+ - return: official links, constraints, errors, examples, affected docs
85
+
86
+ Architect:
87
+ - ecc: `common/patterns.md` + stack-specific (web/patterns.md for FE, python/fastapi.md for BE)
88
+ - inject: PRD, current architecture, ports
89
+ - forbid: implementation
90
+ - return: boundary decision, affected docs, risks
91
+
92
92
  Test Writer:
93
93
  - ecc: `common/testing.md` + stack-specific testing rules
94
94
  - inject: acceptance criteria, UI/API contracts, feature doc, test write set
95
95
  - forbid: production code
96
96
  - return: failing tests, AC ID mapping, and test intent
97
-
98
- Implementer (Frontend):
99
- - ecc: `web/design-quality.md`, `web/patterns.md`, `web/performance.md`, `typescript/patterns.md`
100
- - inject: task, tests, allowed write set, forbidden scope
101
- - forbid: unrelated refactor and test loosening
102
- - return: changed files and implementation notes
103
-
104
- Implementer (Backend):
105
- - ecc: `common/patterns.md`, stack-specific patterns (`python/fastapi.md` or `golang/patterns.md`)
106
- - inject: task, tests, allowed write set, forbidden scope
107
- - forbid: unrelated refactor and test loosening
108
- - return: changed files and implementation notes
109
-
97
+
98
+ Implementer (Frontend):
99
+ - ecc: `web/design-quality.md`, `web/patterns.md`, `web/performance.md`, `typescript/patterns.md`
100
+ - inject: task, tests, allowed write set, forbidden scope
101
+ - forbid: unrelated refactor and test loosening
102
+ - return: changed files and implementation notes
103
+
104
+ Implementer (Backend):
105
+ - ecc: `common/patterns.md`, stack-specific patterns (`python/fastapi.md` or `golang/patterns.md`)
106
+ - inject: task, tests, allowed write set, forbidden scope
107
+ - forbid: unrelated refactor and test loosening
108
+ - return: changed files and implementation notes
109
+
110
110
  Reviewer:
111
111
  - ecc: `web/design-quality.md` (FE), `web/security.md` (FE), `common/security.md`, stack security
112
112
  - inject: PRD, acceptance criteria, UI/API contracts, diff, test/validation evidence, architecture docs
113
113
  - forbid: writes
114
114
  - return: findings by severity, AC traceability, missing tests, boundary issues
115
-
115
+
116
116
  Debugger:
117
117
  - ecc: stack-specific coding-style + patterns
118
118
  - inject: failed AC ID, failing command, error output, trace/screenshot/network evidence, related files
119
119
  - forbid: broad rewrites
120
120
  - return: failure layer, root cause, fix, proof
121
-
121
+
122
122
  Verifier:
123
123
  - ecc: stack-specific testing rules
124
124
  - inject: verification commands, acceptance criteria, UI/API contracts, running app/API endpoint
125
125
  - forbid: code changes
126
126
  - return: commands run, AC-by-AC validation matrix, evidence paths, residual risk
127
-
128
- Memory Master:
129
- - inject: trigger reason, current failure/user-correction/closeout context, task PROGRESS.md section
130
- - forbid: source code, unrelated Harness docs
131
- - return: memory action summary, files written, cross-project flag
132
-
133
- Context Master:
134
- - inject: trigger reason (threshold % or closeout), current task PROGRESS.md, task phase
135
- - forbid: source code, memory files, MEMORY.md writes
136
- - return: context usage %, stale blocks, compressible blocks, durable knowledge candidates, compression suggestion
137
-
138
- ## Handoff Rule
139
-
140
- Only the subagent summary enters main context. If details are needed, load the named files directly instead of replaying the subagent conversation.
141
-
142
- Use the handoff format in [dispatch.md](dispatch.md) for every dispatched agent.
127
+
128
+ Memory Master:
129
+ - inject: trigger reason, current failure/user-correction/closeout context, task PROGRESS.md section
130
+ - forbid: source code, unrelated Harness docs
131
+ - return: memory action summary, files written, cross-project flag
132
+
133
+ Context Master:
134
+ - inject: trigger reason (threshold % or closeout), current task PROGRESS.md, task phase
135
+ - forbid: source code, memory files, MEMORY.md writes
136
+ - return: context usage %, stale blocks, compressible blocks, durable knowledge candidates, compression suggestion
137
+
138
+ ## Handoff Rule
139
+
140
+ Only the subagent summary enters main context. If details are needed, load the named files directly instead of replaying the subagent conversation.
141
+
142
+ Use the handoff format in [dispatch.md](dispatch.md) for every dispatched agent.
@@ -1,105 +1,106 @@
1
- # Dispatch Protocol
2
-
3
- Purpose: coordinate a small set of subagents without building a scheduler.
4
-
5
- Use [subagents.md](subagents.md) for orchestration strategy. Use this file for the dispatch table, handoff format, and status protocol.
6
-
7
- Use when work needs parallel reading, independent review, cross-layer analysis, or more than one bounded implementation pass.
8
-
9
- ## Principles
10
-
11
- - Main agent owns the final decision, integration, and verification.
12
- - project files are the only durable communication channel; chat/subagent transcript state is non-authoritative.
1
+ # Dispatch Protocol
2
+
3
+ Purpose: coordinate a small set of subagents without building a scheduler.
4
+
5
+ Use [subagents.md](subagents.md) for orchestration strategy. Use this file for the dispatch table, handoff format, and status protocol.
6
+
7
+ Use when work needs parallel reading, independent review, cross-layer analysis, or more than one bounded implementation pass.
8
+
9
+ ## Principles
10
+
11
+ - Main agent owns the final decision, integration, and verification.
12
+ - project files are the only durable communication channel; chat/subagent transcript state is non-authoritative.
13
13
  - Important assumptions, decisions, blockers, evidence, and handoffs must be written to `Harness/tasks/<task-id>/PROGRESS.md` and `Harness/tasks/<task-id>/PLAN.md`, the current feature doc, `Harness/MEMORY.md`, or `Harness/memory/*` as appropriate.
14
14
  - PRD-derived Acceptance Criteria are the source of truth. Dispatch packets must carry the relevant AC IDs and contracts.
15
- - Agent count: default (non-WF) 3 active agents; `/wf` requires ≥3 distinct subagents from `.claude/agents/` before second plan; `/wf max` removes the cap entirely (governed by span formula in WF-MAX.md). See [WF.md](WF.md) and [WF-MAX.md](WF-MAX.md) for the authoritative rules.
16
- - Read-only agents may run in parallel.
17
- - Writing agents run serially unless write sets are disjoint.
18
- - Use a worktree when two agents may touch overlapping files or long-running branches.
19
- - Only summaries enter main context. Load named files directly when details are needed.
20
- - Subagents read task files, return findings and PLAN patch suggestions. Only the main agent commits changes to PROGRESS.md and PLAN.md.
21
-
22
- ## Scope
23
-
24
- `agent-workflow.md` owns the build/review loop. `subagents.md` owns orchestration strategy and agent roster. This file owns the dispatch input and subagent handoff formats.
25
-
26
- ## Agent Roster
27
-
28
- | Agent | Mode | Purpose |
29
- | --- | --- | --- |
30
- | `planner` | Read | split goal into tasks, dependencies, write sets |
31
- | `researcher` | Read | product, market, ecosystem, dependency research |
32
- | `docs-researcher` | Read | official docs, API, SDK, version, limits |
33
- | `architect` | Read | layer boundaries, ports, data flow, state impact |
34
- | `test-writer` | Write | failing test or manual verification plan |
35
- | `implementer` | Write | minimal change inside declared write set |
36
- | `debugger` | Write | smallest fix for a reproduced failure |
37
- | `reviewer` | Read | diff review, risks, missing tests |
38
- | `verifier` | Read | run checks and record evidence |
39
- | `memory-master` | Write | write/consolidate memory entries |
40
- | `context-master` | Read | analyze context, recommend compression |
41
- | `explore-manager` | Read | WF-MAX W0: spawn researchers, synthesize |
42
- | `architect-manager` | Read | WF-MAX W1: spawn architects, synthesize |
43
- | `implement-manager` | Write | WF-MAX W2: spawn implementers |
44
- | `review-manager` | Read | WF-MAX W2R: spawn reviewers, deduplicate |
45
-
46
- ## Dispatch Rules
47
-
48
- - Every dispatch row needs task, agent, mode, read set, write set, dependency, output, and status.
49
- - A write set of `none` means read-only.
50
- - If two write sets overlap, do not run those agents in parallel.
51
- - If an agent returns uncertainty, mark the row `Blocked` or add a follow-up row.
52
- - If docs, tests, and code disagree, stop implementation and record the conflict in `Harness/tasks/<task-id>/PROGRESS.md`.
53
- - In /wf max, file claims must respect WF-MAX.md leaf condition: no split below 50 avgLines, no split when files ≤ span×2.
54
-
55
- ## Dispatch Input (Controller → Subagent)
56
-
57
- The controller MUST include these fields in the subagent's dispatch packet.
58
- Without them, the subagent has no way to know which rules or contracts to load.
59
-
60
- ```text
61
- Role: <installed agent name or bounded role, e.g. planner, implementer-fe, reviewer, memory-master>
62
- Task: <one-sentence goal>
63
- ECC: <which ECC rules to load, e.g. web/design-quality.md, python/fastapi.md. See context-loading.md#ecc-rules-per-role>
15
+ - Agent count: default (non-WF) <=3 active agents; `/wf` requires the complete role chain by default; `/wf max` inherits that chain and removes the Harness default cap through the span formula. Real concurrency is still bounded by runtime thread budget, config, billing, and local resources. Use current runtime subagents first, close completed agents, then cross-CLI overflow. Generated Codex config defaults to `agents.max_threads = 12` and `agents.max_depth = 1`; ask the user before raising `agents.max_threads` above that default. See [WF.md](WF.md) and [WF-MAX.md](WF-MAX.md).
16
+ - Read-only agents may run in parallel.
17
+ - Writing agents run serially unless write sets are disjoint.
18
+ - Use a worktree when two agents may touch overlapping files or long-running branches.
19
+ - Only summaries enter main context. Load named files directly when details are needed.
20
+ - Subagents read task files, return findings and PLAN patch suggestions. Only the main agent commits changes to PROGRESS.md and PLAN.md.
21
+
22
+ ## Scope
23
+
24
+ `agent-workflow.md` owns the build/review loop. `subagents.md` owns orchestration strategy and agent roster. This file owns the dispatch input and subagent handoff formats.
25
+
26
+ ## Agent Roster
27
+
28
+ | Agent | Mode | Purpose |
29
+ | --- | --- | --- |
30
+ | `planner` | Read | split goal into tasks, dependencies, write sets |
31
+ | `researcher` | Read | product, market, ecosystem, dependency research |
32
+ | `docs-researcher` | Read | official docs, API, SDK, version, limits |
33
+ | `architect` | Read | layer boundaries, ports, data flow, state impact |
34
+ | `test-writer` | Write | failing test or manual verification plan |
35
+ | `implementer` | Write | minimal change inside declared write set |
36
+ | `debugger` | Write | smallest fix for a reproduced failure |
37
+ | `reviewer` | Read | diff review, risks, missing tests |
38
+ | `verifier` | Read | run checks and record evidence |
39
+ | `reflector` | Read | synthesize review/evidence and decide acceptance readiness |
40
+ | `memory-master` | Write | write/consolidate memory entries |
41
+ | `context-master` | Read | analyze context, recommend compression |
42
+ | `explore-manager` | Read | WF-MAX W0: spawn researchers, synthesize |
43
+ | `architect-manager` | Read | WF-MAX W1: spawn architects, synthesize |
44
+ | `implement-manager` | Write | WF-MAX W2: spawn implementers |
45
+ | `review-manager` | Read | WF-MAX W2R: spawn reviewers, deduplicate |
46
+
47
+ ## Dispatch Rules
48
+
49
+ - Every dispatch row needs task, agent, mode, read set, write set, dependency, output, and status.
50
+ - A write set of `none` means read-only.
51
+ - If two write sets overlap, do not run those agents in parallel.
52
+ - If an agent returns uncertainty, mark the row `Blocked` or add a follow-up row.
53
+ - If docs, tests, and code disagree, stop implementation and record the conflict in `Harness/tasks/<task-id>/PROGRESS.md`.
54
+ - In /wf max, file claims must respect WF-MAX.md leaf condition: no split below 50 avgLines, no split when files <= span*2.
55
+
56
+ ## Dispatch Input (Controller -> Subagent)
57
+
58
+ The controller MUST include these fields in the subagent's dispatch packet.
59
+ Without them, the subagent has no way to know which rules or contracts to load.
60
+
61
+ ```text
62
+ Role: <installed agent name or bounded role, e.g. planner, implementer-fe, reviewer, memory-master>
63
+ Task: <one-sentence goal>
64
+ ECC: <which ECC rules to load, e.g. web/design-quality.md, python/fastapi.md. See context-loading.md#ecc-rules-per-role>
64
65
  Skills: <which skills to activate, e.g. react-review, tdd-guide>
65
66
  PRD: <path or task PLAN section containing Mini PRD>
66
67
  Acceptance IDs: <AC-001, AC-002, or "none" for non-behavioral work>
67
68
  UI contract: <path to UI_CONTRACT.md or task PLAN section, if UI task>
68
- API contract: <path to api/openapi.yaml, if frontendbackend task. Omit if N/A>
69
- Read set: <files and directories the subagent may read>
70
- Write set: <files the subagent may modify. "none" = read-only>
71
- Forbidden: <commands, paths, or patterns the subagent must not touch>
72
- Verification: <commands to run after implementation, e.g. npm test>
73
- ```
74
-
75
- ## Handoff Format (Subagent Controller)
76
-
77
- Subagents return summaries in this shape:
78
-
79
- ```text
80
- Agent:
81
- Task:
82
- Mode:
83
- ECC loaded: <which ECC rule files were actually loaded. Should match dispatch ECC field.>
84
- Skills active: <which skills were active. Should match dispatch Skills field.>
85
- API contract: <path to contract file used, if applicable>
69
+ API contract: <path to api/openapi.yaml, if frontend<->backend task. Omit if N/A>
70
+ Read set: <files and directories the subagent may read>
71
+ Write set: <files the subagent may modify. "none" = read-only>
72
+ Forbidden: <commands, paths, or patterns the subagent must not touch>
73
+ Verification: <commands to run after implementation, e.g. npm test>
74
+ ```
75
+
76
+ ## Handoff Format (Subagent -> Controller)
77
+
78
+ Subagents return summaries in this shape:
79
+
80
+ ```text
81
+ Agent:
82
+ Task:
83
+ Mode:
84
+ ECC loaded: <which ECC rule files were actually loaded. Should match dispatch ECC field.>
85
+ Skills active: <which skills were active. Should match dispatch Skills field.>
86
+ API contract: <path to api/openapi.yaml, if frontend<->backend task. Omit if N/A>
86
87
  Acceptance IDs: <AC IDs handled or validated>
87
88
  Files read:
88
- Files changed:
89
- Findings:
90
- Evidence:
91
- Risks:
92
- Next:
89
+ Files changed:
90
+ Findings:
91
+ Evidence:
92
+ Risks:
93
+ Next:
93
94
  PLAN patch:
94
95
  Validation matrix: <AC-by-AC pass/fail/block evidence, for validators>
95
- Concurrency group: <wave number 0=exploration, 1,2,3,...=implementation waves. Optional; only used in /wf max.>
96
- File claim: <list of exact file paths this agent exclusively owns. Optional; only used in /wf max.>
97
- Granularity floor: <50 avgLines do NOT spawn. Apply leaf condition from WF-MAX.md.>
98
- ```
99
-
100
- Use `Files changed: none` for read-only agents. Use `PLAN patch: none` when no state update is needed.
101
- If a handoff matters after context loss, write it to `Harness/tasks/<task-id>/PROGRESS.md`, `Harness/tasks/<task-id>/PLAN.md`, the current feature doc, or `Harness/memory/*`; do not rely on chat transcript state.
102
-
103
- ## Statuses
104
-
105
- Allowed dispatch statuses: Pending / In Progress / Returned / Integrated / Blocked / Verified.
96
+ Concurrency group: <wave number - 0=exploration, 1,2,3,...=implementation waves. Optional; only used in /wf max.>
97
+ File claim: <list of exact file paths this agent exclusively owns. Optional; only used in /wf max.>
98
+ Granularity floor: <50 avgLines -> do NOT spawn. Apply leaf condition from WF-MAX.md.>
99
+ ```
100
+
101
+ Use `Files changed: none` for read-only agents. Use `PLAN patch: none` when no state update is needed.
102
+ If a handoff matters after context loss, write it to `Harness/tasks/<task-id>/PROGRESS.md`, `Harness/tasks/<task-id>/PLAN.md`, the current feature doc, or `Harness/memory/*`; do not rely on chat transcript state.
103
+
104
+ ## Statuses
105
+
106
+ Allowed dispatch statuses: Pending / In Progress / Returned / Integrated / Blocked / Verified.
@@ -1,70 +1,70 @@
1
- # Extension Contract
2
-
1
+ # Extension Contract
2
+
3
3
  Purpose: keep stack-specific agents, skills, and rules compatible with this harness.
4
-
5
- Use during setup whenever adding assets from ECC, SuperClaude, toolboxes, or local project conventions.
6
-
7
- ## Non-Invasive Extension Rules
8
-
9
- Extensions must preserve project and harness ownership boundaries.
10
-
4
+
5
+ Use during setup whenever adding assets from ECC, SuperClaude, toolboxes, or local project conventions.
6
+
7
+ ## Non-Invasive Extension Rules
8
+
9
+ Extensions must preserve project and harness ownership boundaries.
10
+
11
11
  - Preserve existing `.claude/`, `CLAUDE.md`, `AGENTS.md`, `.gitignore`, `Harness/README.md`, `Harness/workflows/*.md`, settings, and local rules unless the user explicitly requests an overwrite.
12
- - Treat existing project config as project fact. Read it before adding assets, then adapt new assets to the project instead of replacing the project.
12
+ - Treat existing project config as project fact. Read it before adding assets, then adapt new assets to the project instead of replacing the project.
13
13
  - Register added agents, skills, workflows, and rules in `Harness/MEMORY.md` and this docs router where applicable.
14
- - Added assets may extend `.claude/skills/`, `.claude/agents/`, `.claude/rules/`, or `Harness/workflows/`, but they must not replace core harness docs.
15
- - Core harness docs are `Harness/README.md`, `Harness/PROGRESS.md`, `Harness/subagents.md`, `Harness/context-loading.md`, `Harness/dispatch.md`, `Harness/agent-workflow.md`, and this file.
16
- - If an optional workflow needs a new command or tool, document the command and fallback in `Harness/workflows/<name>.md` instead of changing core harness behavior.
17
-
18
- ## Agent Contract
19
-
20
- Every added agent must have frontmatter:
21
-
22
- ```yaml
23
- ---
24
- name: stack-agent-name
25
- description: Use when ...
26
- tools: Read, Grep, Glob
27
- model: sonnet
28
- ---
29
- ```
30
-
31
- Agent body must state:
32
-
33
- - load first
34
- - inputs required
35
- - allowed write set or read-only
36
- - forbidden scope
37
- - verification or evidence
38
- - return format from [subagents.md](subagents.md) and [dispatch.md](dispatch.md)
39
-
40
- ## Skill Contract
41
-
42
- Every added skill must state:
43
-
44
- - when to use
45
- - docs to load
46
- - required inputs
47
- - allowed writes
48
- - output format
49
- - whether to update `Harness/PROGRESS.md` and task files
50
- - whether to use [subagents.md](subagents.md) and [dispatch.md](dispatch.md)
51
-
52
- Skills should extend the harness. They should not replace `Harness/README.md`, `Harness/PROGRESS.md`, `subagents.md`, `context-loading.md`, `dispatch.md`, or `agent-workflow.md`.
53
-
54
- ## Rules
55
-
56
- - Do not add broad agents that can write anywhere.
57
- - Do not add agents whose role overlaps an existing common agent without naming the difference.
58
- - Do not add tools that bypass project permissions or user approval.
59
- - Do not run stack-specific writing agents in parallel unless write sets are disjoint.
60
- - If an added asset conflicts with this harness, adapt the asset instead of changing the core contract.
61
-
62
- ## Registration
63
-
64
- After adding assets:
65
-
66
- - list agents in `Harness/MEMORY.md#Agents`
67
- - list skills in `Harness/MEMORY.md#Skills`
68
- - list workflows by path in `Harness/MEMORY.md` or `Harness/README.md`
69
- - update `Harness/PROGRESS.md` and `Harness/tasks/<task-id>/PROGRESS.md` when the asset affects current work
70
- - run `node Harness/scripts/validate-harness.mjs`
14
+ - Added assets may extend `.claude/skills/`, `.claude/agents/`, `.claude/rules/`, or `Harness/workflows/`, but they must not replace core harness docs.
15
+ - Core harness docs are `Harness/README.md`, `Harness/PROGRESS.md`, `Harness/subagents.md`, `Harness/context-loading.md`, `Harness/dispatch.md`, `Harness/agent-workflow.md`, and this file.
16
+ - If an optional workflow needs a new command or tool, document the command and fallback in `Harness/workflows/<name>.md` instead of changing core harness behavior.
17
+
18
+ ## Agent Contract
19
+
20
+ Every added agent must have frontmatter:
21
+
22
+ ```yaml
23
+ ---
24
+ name: stack-agent-name
25
+ description: Use when ...
26
+ tools: Read, Grep, Glob
27
+ model: sonnet
28
+ ---
29
+ ```
30
+
31
+ Agent body must state:
32
+
33
+ - load first
34
+ - inputs required
35
+ - allowed write set or read-only
36
+ - forbidden scope
37
+ - verification or evidence
38
+ - return format from [subagents.md](subagents.md) and [dispatch.md](dispatch.md)
39
+
40
+ ## Skill Contract
41
+
42
+ Every added skill must state:
43
+
44
+ - when to use
45
+ - docs to load
46
+ - required inputs
47
+ - allowed writes
48
+ - output format
49
+ - whether to update `Harness/PROGRESS.md` and task files
50
+ - whether to use [subagents.md](subagents.md) and [dispatch.md](dispatch.md)
51
+
52
+ Skills should extend the harness. They should not replace `Harness/README.md`, `Harness/PROGRESS.md`, `subagents.md`, `context-loading.md`, `dispatch.md`, or `agent-workflow.md`.
53
+
54
+ ## Rules
55
+
56
+ - Do not add broad agents that can write anywhere.
57
+ - Do not add agents whose role overlaps an existing common agent without naming the difference.
58
+ - Do not add tools that bypass project permissions or user approval.
59
+ - Do not run stack-specific writing agents in parallel unless write sets are disjoint.
60
+ - If an added asset conflicts with this harness, adapt the asset instead of changing the core contract.
61
+
62
+ ## Registration
63
+
64
+ After adding assets:
65
+
66
+ - list agents in `Harness/MEMORY.md#Agents`
67
+ - list skills in `Harness/MEMORY.md#Skills`
68
+ - list workflows by path in `Harness/MEMORY.md` or `Harness/README.md`
69
+ - update `Harness/PROGRESS.md` and `Harness/tasks/<task-id>/PROGRESS.md` when the asset affects current work
70
+ - run `node Harness/scripts/validate-harness.mjs`