create-harness-vibe-coding 0.8.6 → 0.8.7
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.
- package/package.json +1 -1
- package/src/generator.js +30 -11
- package/src/index.js +129 -5
- package/templates/common/.claude/agents/reflector.md +35 -0
- package/templates/common/.claude/agents/verifier.md +5 -3
- package/templates/common/.claude/commands/wf-help.md +1 -2
- package/templates/common/.claude/skills/subagent-orchestrator/SKILL.md +10 -4
- package/templates/common/.claude/skills/wf/SKILL.md +7 -3
- package/templates/common/.claude/skills/wf-auto/SKILL.md +59 -107
- package/templates/common/.claude/skills/wf-auto-spark/SKILL.md +19 -17
- package/templates/common/.claude/skills/wf-max/SKILL.md +40 -21
- package/templates/common/.claude/skills/wf-update/SKILL.md +9 -4
- package/templates/common/.codex/config.toml +5 -0
- package/templates/common/.harness-version +36 -34
- package/templates/common/AGENTS.md +26 -25
- package/templates/common/CLAUDE.md +10 -9
- package/templates/common/Harness/ACCEPTANCE_PROTOCOL.md +12 -4
- package/templates/common/Harness/README.md +10 -11
- package/templates/common/Harness/WF-AUTO-SPARK.md +18 -1
- package/templates/common/Harness/WF-AUTO.md +518 -492
- package/templates/common/Harness/WF-MAX.md +284 -232
- package/templates/common/Harness/WF.md +47 -29
- package/templates/common/Harness/agent-workflow.md +108 -76
- package/templates/common/Harness/dispatch.md +96 -95
- package/templates/common/Harness/extension.md +1 -1
- package/templates/common/Harness/subagents.md +78 -56
- package/templates/common/Harness/tasks/_template/ARTIFACTS.md +1 -1
- package/templates/common/Harness/tasks/_template/NOTES.md +1 -1
- package/templates/common/Harness/tasks/_template/PLAN.md +53 -60
- package/templates/common/Harness/tasks/_template/PROGRESS.md +26 -29
- package/templates/common/MEMORY.md +26 -29
- package/templates/common/SETUP.md +1 -1
- package/templates/common/scripts/scan-clean.mjs +80 -41
- package/templates/common/scripts/validate-harness.mjs +101 -31
- package/templates/common/scripts/wf-remove.mjs +279 -278
- package/templates/common/scripts/wf-update-check.mjs +395 -195
- package/templates/optional/skills/browser-e2e/.claude/skills/wf-browser/SKILL.md +1 -1
- package/templates/optional/skills/browser-e2e/Harness/workflows/browser-e2e.md +57 -21
|
@@ -34,41 +34,51 @@ Two distinct trigger classes; do not conflate them:
|
|
|
34
34
|
- Explicit invocation (`/wf`, `$wf`, `wf mode`, `workflow mode`, `wk mode`,
|
|
35
35
|
`/wf-max`, `$wf-max`): role fan-out is mandatory and unconditional. File
|
|
36
36
|
count, task size, and subsystem count are irrelevant. A one-file task invoked
|
|
37
|
-
with WF still
|
|
37
|
+
with WF still schedules the complete role chain before closeout.
|
|
38
38
|
- Auto-triggering decides whether the harness enters WF mode on its own. It can
|
|
39
39
|
only escalate into WF, never downgrade an explicit command out of WF.
|
|
40
40
|
|
|
41
|
-
##
|
|
42
|
-
|
|
43
|
-
WF mode requires
|
|
44
|
-
|
|
45
|
-
Normative rule: Explicit `/wf`, `$wf`, `wf mode`, `workflow mode`, or `wk mode` MUST
|
|
46
|
-
|
|
47
|
-
- Explicit `/wf`, `$wf`, `wf mode`, `workflow mode`, or `wk mode` MUST
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
41
|
+
## Complete Role Chain Requirement
|
|
42
|
+
|
|
43
|
+
WF mode requires the complete role chain by default.
|
|
44
|
+
|
|
45
|
+
Normative rule: Explicit `/wf`, `$wf`, `wf mode`, `workflow mode`, or `wk mode` MUST cover every mandatory role class before closeout: Plan, Research, Architecture, Test, Implement, Independent Validation, Cross-Review, Reflect, and Final Acceptance.
|
|
46
|
+
|
|
47
|
+
- Explicit `/wf`, `$wf`, `wf mode`, `workflow mode`, or `wk mode` MUST schedule
|
|
48
|
+
the complete role chain at intake. Use real subagents when the runtime
|
|
49
|
+
supports them; otherwise emulate those roles as bounded passes and record the
|
|
50
|
+
fallback.
|
|
51
|
+
- Mandatory role classes:
|
|
52
|
+
- Plan: `planner`
|
|
53
|
+
- Research: `researcher` or `docs-researcher`; use both when local and external/current facts matter
|
|
54
|
+
- Architecture: `architect`
|
|
55
|
+
- Test: `test-writer`
|
|
56
|
+
- Implement: `implementer` and `debugger` when needed
|
|
57
|
+
- Independent Validation: `verifier` records AC-mapped evidence before cross-review
|
|
58
|
+
- Cross-Review: at least two independent review lenses after implementation
|
|
59
|
+
- Reflect: `reflector`
|
|
60
|
+
- Final Acceptance: controller accepts only after cross-review passes and `reflector` returns PASS
|
|
51
61
|
- Runtime mapping:
|
|
52
62
|
- Claude Code: prefer subagents from `.claude/agents/`.
|
|
53
63
|
- Codex: prefer the available Codex subagent surface; if unavailable, use
|
|
54
64
|
bounded passes with the same roles and evidence contract.
|
|
55
65
|
- Collaboration decision tree (replaces the old "7:3" heuristic with concrete
|
|
56
66
|
conditions):
|
|
57
|
-
- Explicit WF/WK mode ->
|
|
58
|
-
- 3+ files changed ->
|
|
59
|
-
- Cross-layer change ->
|
|
60
|
-
- Uncertain scope or approach ->
|
|
67
|
+
- Explicit WF/WK mode -> complete role chain, no exceptions.
|
|
68
|
+
- 3+ files changed -> complete role chain.
|
|
69
|
+
- Cross-layer change -> complete role chain plus separate architecture review.
|
|
70
|
+
- Uncertain scope or approach -> complete role chain with both researcher and architect passes.
|
|
61
71
|
- 1-2 files, well-understood, not in WF mode -> solo is acceptable.
|
|
62
72
|
- Repeated failure on the same task -> stop solo and switch to multi-role.
|
|
63
|
-
- Default
|
|
64
|
-
|
|
65
|
-
the phase needs them.
|
|
73
|
+
- Default `/wf` startup records the full chain in the task plan. Dependency-bound
|
|
74
|
+
roles run when their phase is ready; they are not optional.
|
|
66
75
|
|
|
67
76
|
## Exploration Gate
|
|
68
77
|
|
|
69
78
|
- [ ] Controller has not read source files directly; only Harness docs, root
|
|
70
79
|
agent entries, and subagent or bounded-pass returns.
|
|
71
|
-
- [ ]
|
|
80
|
+
- [ ] Complete role chain is scheduled in the task plan.
|
|
81
|
+
- [ ] Plan, Research, and Architecture role passes each have one specific question before second planning.
|
|
72
82
|
- [ ] Role passes were dispatched together when the runtime supports parallel
|
|
73
83
|
dispatch.
|
|
74
84
|
- [ ] Agent count is at least `max(3, ceil(estimated_dirs / 2))`; estimate from
|
|
@@ -93,8 +103,9 @@ Intake
|
|
|
93
103
|
-> test-writer
|
|
94
104
|
-> implementer
|
|
95
105
|
-> independent validator
|
|
96
|
-
->
|
|
97
|
-
->
|
|
106
|
+
-> cross-review: spec/AC reviewer + code/architecture/test reviewer
|
|
107
|
+
-> reflector
|
|
108
|
+
-> if failed: debugger -> verifier -> cross-review -> reflector -> loop
|
|
98
109
|
-> memory closeout with evidence
|
|
99
110
|
```
|
|
100
111
|
|
|
@@ -166,9 +177,12 @@ The second plan must pass:
|
|
|
166
177
|
|
|
167
178
|
1. `test-writer` defines failing tests or written manual checks from AC IDs and contracts first.
|
|
168
179
|
2. `implementer` changes only the declared write set and may not edit truth files without Change Request.
|
|
169
|
-
3. `verifier` or independent validator runs AC-mapped checks against running behavior and records an
|
|
170
|
-
4.
|
|
171
|
-
|
|
180
|
+
3. `verifier` or independent validator runs AC-mapped checks against running behavior and records an evidence matrix before cross-review.
|
|
181
|
+
4. Cross-review is mandatory: at least two independent review lenses must pass before acceptance.
|
|
182
|
+
- Spec/AC review checks request, scope, contracts, and non-goals.
|
|
183
|
+
- Code/architecture/test review checks implementation risk, maintainability, security, and verification adequacy.
|
|
184
|
+
5. `reflector` reads verifier evidence and reviewer findings, resolves contradictions with the controller, and returns PASS before final acceptance.
|
|
185
|
+
6. For cross-layer or risky work, run separate reviewers for spec/AC compliance, architecture, security, and test adequacy.
|
|
172
186
|
|
|
173
187
|
## Browser And API Evidence
|
|
174
188
|
|
|
@@ -197,9 +211,10 @@ If verification fails:
|
|
|
197
211
|
2. Dispatch `debugger` with the failed AC ID, failing command, error output,
|
|
198
212
|
trace/screenshot/network evidence, and smallest relevant files.
|
|
199
213
|
3. Classify the failure layer using [DEBUG_PROTOCOL.md](DEBUG_PROTOCOL.md), then fix the smallest reproduced failure.
|
|
200
|
-
4. Run
|
|
201
|
-
5. Run
|
|
202
|
-
6.
|
|
214
|
+
4. Run verifier again and record fresh AC-mapped evidence.
|
|
215
|
+
5. Run cross-review again.
|
|
216
|
+
6. Run reflector again.
|
|
217
|
+
7. Repeat until verified or blocked by missing user input/external state.
|
|
203
218
|
|
|
204
219
|
Before asking the user after repeated failures, run the context-master then
|
|
205
220
|
memory-master learning cycle or use `wf-learn`.
|
|
@@ -207,6 +222,8 @@ memory-master learning cycle or use `wf-learn`.
|
|
|
207
222
|
## Heartbeat Protocol
|
|
208
223
|
|
|
209
224
|
Heartbeat is a lightweight recovery protocol, not a background daemon.
|
|
225
|
+
Keep heartbeat entries to one or two lines: phase, blocker/failure, next action,
|
|
226
|
+
and evidence pointer. Do not paste command logs or subagent transcripts.
|
|
210
227
|
|
|
211
228
|
Update `Harness/tasks/<task-id>/PROGRESS.md#Heartbeat`:
|
|
212
229
|
|
|
@@ -224,9 +241,10 @@ equivalent bounded pass to append a compression suggestion to the task heartbeat
|
|
|
224
241
|
|
|
225
242
|
Close only when:
|
|
226
243
|
|
|
227
|
-
- PRD-GATE, AC-GATE, CONTRACT-GATE, TEST-GATE, VALIDATION-GATE, and
|
|
244
|
+
- PRD-GATE, AC-GATE, CONTRACT-GATE, TEST-GATE, VALIDATION-GATE, REVIEW-GATE, and REFLECT-GATE are satisfied
|
|
228
245
|
- acceptance criteria are satisfied and reported by AC ID
|
|
229
|
-
-
|
|
246
|
+
- cross-review has passed with no unresolved critical/high findings
|
|
247
|
+
- reflector verdict is PASS
|
|
230
248
|
- test/API/browser evidence is recorded
|
|
231
249
|
- affected Harness docs are synced
|
|
232
250
|
- context-master has analyzed the session and extracted durable knowledge
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
# Agent Workflow
|
|
2
|
-
|
|
1
|
+
# Agent Workflow
|
|
2
|
+
|
|
3
3
|
Use when implementing, reviewing, debugging, or coordinating subagents.
|
|
4
4
|
|
|
5
5
|
This workflow is acceptance-driven. PRD-derived Acceptance Criteria are the
|
|
@@ -8,33 +8,47 @@ must trace to AC IDs. Load [ACCEPTANCE_PROTOCOL.md](ACCEPTANCE_PROTOCOL.md) for
|
|
|
8
8
|
gate rules, [TDD-GUIDE.md](TDD-GUIDE.md) for AC-linked RED tests,
|
|
9
9
|
[HARNESS_BRIDGE.md](HARNESS_BRIDGE.md) for UI/API/browser evidence, and
|
|
10
10
|
[AGENT_ISOLATION.md](AGENT_ISOLATION.md) before role splits.
|
|
11
|
-
|
|
12
|
-
## ReAct Loop
|
|
13
|
-
|
|
14
|
-
```text
|
|
15
|
-
Observe -> Load minimal context -> Plan -> Act -> Verify -> Update Harness/tasks/<task-id>/PROGRESS.md
|
|
16
|
-
```
|
|
17
|
-
|
|
18
|
-
If context grows, load [context-loading.md](context-loading.md) and split the
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
task
|
|
36
|
-
|
|
37
|
-
|
|
11
|
+
|
|
12
|
+
## ReAct Loop
|
|
13
|
+
|
|
14
|
+
```text
|
|
15
|
+
Observe -> Load minimal context -> Plan -> Act -> Verify -> Update Harness/tasks/<task-id>/PROGRESS.md
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
If context grows, load [context-loading.md](context-loading.md) and split the
|
|
19
|
+
work. If more than one agent is useful, load [subagents.md](subagents.md) and
|
|
20
|
+
[dispatch.md](dispatch.md).
|
|
21
|
+
|
|
22
|
+
## Feature Packet
|
|
23
|
+
|
|
24
|
+
Every PRD scope item must be covered by AC IDs and a task plan at
|
|
25
|
+
`Harness/tasks/<task-id>/PLAN.md` created from
|
|
26
|
+
`Harness/tasks/_template/PLAN.md` (the primary work tracking system).
|
|
27
|
+
|
|
28
|
+
**Cohesion rule**: if multiple PRD scope items share the same write set, the
|
|
29
|
+
same test/verification path, and the same review boundary, group them into a
|
|
30
|
+
single feature doc. The PRD owns scope decomposition; the feature doc owns the
|
|
31
|
+
implementation unit.
|
|
32
|
+
|
|
33
|
+
**Minimum bar**: a task plan is required when the implementation touches more
|
|
34
|
+
than one file or changes user-visible behavior. Record the plan in
|
|
35
|
+
`Harness/tasks/<task-id>/PLAN.md`. For single-file fixes with no behavior
|
|
36
|
+
change, a brief note in `PROGRESS.md` is enough.
|
|
37
|
+
|
|
38
|
+
Use the compact task template by default. `PLAN.md` owns goal, decisions,
|
|
39
|
+
scope/write set, agents, verification intent, and risks. `PROGRESS.md` owns
|
|
40
|
+
status/next/blocker, completed tasks, changed files, verification evidence, and
|
|
41
|
+
notes. Expand sections only when they change an implementation or review
|
|
42
|
+
decision.
|
|
43
|
+
|
|
44
|
+
**AC record size**: default to 1-3 concise ACs. Use full UI/API contracts and an
|
|
45
|
+
AC-by-AC validation matrix only for browser-visible, API/integration,
|
|
46
|
+
security/data-loss, cross-module, or other high-risk behavior.
|
|
47
|
+
|
|
48
|
+
**New vs iterate**: if a PRD scope item overlaps with an existing task, reopen
|
|
49
|
+
the existing task capsule and append to its `PROGRESS.md`. Only create a new
|
|
50
|
+
task capsule when the scope is substantially different. When unsure, ask.
|
|
51
|
+
|
|
38
52
|
## Acceptance-Driven Build Loop
|
|
39
53
|
|
|
40
54
|
```text
|
|
@@ -45,7 +59,9 @@ Mini PRD
|
|
|
45
59
|
-> failing test or manual check
|
|
46
60
|
-> minimal implementation
|
|
47
61
|
-> independent validation
|
|
48
|
-
-> review
|
|
62
|
+
-> cross-review (spec/AC + code/architecture/test)
|
|
63
|
+
-> reflector PASS
|
|
64
|
+
-> final acceptance
|
|
49
65
|
-> debug if needed
|
|
50
66
|
-> docs sync
|
|
51
67
|
-> memory
|
|
@@ -61,27 +77,31 @@ Rules:
|
|
|
61
77
|
- Frontend-backend behavior must include network/API assertions against the contract.
|
|
62
78
|
- Implementer cannot modify PRD, acceptance criteria, UI/API contracts, test plan, or validation report unless a Change Request is recorded.
|
|
63
79
|
- Validator must be independent from implementer and must produce an AC-by-AC result matrix.
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
-
|
|
76
|
-
-
|
|
77
|
-
-
|
|
78
|
-
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
-
|
|
83
|
-
|
|
84
|
-
|
|
80
|
+
- Cross-review and reflector PASS are required before final acceptance.
|
|
81
|
+
|
|
82
|
+
## Subagent Use
|
|
83
|
+
|
|
84
|
+
Use subagents when a task needs broad reading, parallel work, cross-layer
|
|
85
|
+
changes, independent review, or isolated debugging. Follow
|
|
86
|
+
[subagents.md](subagents.md) for controller-led orchestration and
|
|
87
|
+
[dispatch.md](dispatch.md) for the dispatch table.
|
|
88
|
+
|
|
89
|
+
Before spawn, define:
|
|
90
|
+
|
|
91
|
+
- role
|
|
92
|
+
- task
|
|
93
|
+
- mode
|
|
94
|
+
- read boundary
|
|
95
|
+
- write boundary
|
|
96
|
+
- dependency
|
|
97
|
+
- injected docs from [context-loading.md](context-loading.md)
|
|
98
|
+
- return format
|
|
99
|
+
|
|
100
|
+
Rules:
|
|
101
|
+
|
|
102
|
+
- Explorer Pass, Reviewer, Verifier, and Reflector are read-only.
|
|
103
|
+
- Researcher and Docs Researcher are read-only unless explicitly asked to return a docs patch.
|
|
104
|
+
- Planner and Architect are read-only unless explicitly asked to return a docs patch.
|
|
85
105
|
- Test Writer writes tests before Implementer writes production code.
|
|
86
106
|
- Implementer only writes inside its declared write set.
|
|
87
107
|
- Implementer forbidden set includes PRD, acceptance criteria, UI/API contracts, test plan, and validation report by default.
|
|
@@ -89,31 +109,43 @@ Rules:
|
|
|
89
109
|
- Debugger fixes the smallest failing path, not adjacent design.
|
|
90
110
|
- Debugger receives failed AC IDs, evidence, and failing layer hypothesis before editing.
|
|
91
111
|
- Main agent integrates summaries, resolves conflicts, and runs final verification.
|
|
92
|
-
|
|
93
|
-
## Parallel Dispatch
|
|
94
|
-
|
|
95
|
-
Use [subagents.md](subagents.md) and [dispatch.md](dispatch.md) for multi-agent work.
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
##
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
+
|
|
113
|
+
## Parallel Dispatch
|
|
114
|
+
|
|
115
|
+
Use [subagents.md](subagents.md) and [dispatch.md](dispatch.md) for multi-agent work.
|
|
116
|
+
|
|
117
|
+
**Agent count by mode:**
|
|
118
|
+
| Mode | Agent Count Rule | Source |
|
|
119
|
+
|------|-----------------|--------|
|
|
120
|
+
| Default (non-WF) | up to 3 active agents by default | This file |
|
|
121
|
+
| `/wf` | complete role chain mandatory before closeout | [WF.md](WF.md) |
|
|
122
|
+
| `/wf max` | complete WF role chain plus maximum useful fan-out | [WF-MAX.md](WF-MAX.md) |
|
|
123
|
+
|
|
124
|
+
Prefer parallel read-only work first, then serial writes.
|
|
125
|
+
|
|
126
|
+
Every dispatched agent returns the handoff format defined in [dispatch.md](dispatch.md).
|
|
127
|
+
|
|
128
|
+
## Conflict Rule
|
|
129
|
+
|
|
130
|
+
If PRD, acceptance criteria, UI/API contracts, task PLAN.md, architecture,
|
|
131
|
+
ports, tests, or code disagree:
|
|
132
|
+
|
|
133
|
+
1. stop implementation
|
|
134
|
+
2. record the conflict in `Harness/tasks/<task-id>/PROGRESS.md` or the feature doc
|
|
135
|
+
3. choose the smallest reversible decision
|
|
136
|
+
4. ask the maintainer when user-visible behavior or security is affected
|
|
137
|
+
|
|
138
|
+
## Completion Gate
|
|
139
|
+
|
|
140
|
+
Close only when:
|
|
141
|
+
|
|
112
142
|
- acceptance criteria are satisfied by AC ID
|
|
113
143
|
- validation result matrix exists for user-visible behavior
|
|
114
144
|
- verification evidence is recorded
|
|
115
|
-
-
|
|
116
|
-
-
|
|
117
|
-
-
|
|
118
|
-
-
|
|
119
|
-
-
|
|
145
|
+
- cross-review has passed with no unresolved critical/high findings
|
|
146
|
+
- reflector verdict is PASS
|
|
147
|
+
- architecture docs are synced if affected
|
|
148
|
+
- no unresolved critical/high review findings remain
|
|
149
|
+
- any optimistic UI mutation has a declared and verified rollback path
|
|
150
|
+
- any file declared as DONE in PLAN.md or PROGRESS.md exists on disk (chat output is not durable evidence)
|
|
151
|
+
- `Harness/tasks/<task-id>/PROGRESS.md` states the final status or next iteration
|
|
@@ -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)
|
|
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
|
-
| `
|
|
40
|
-
| `
|
|
41
|
-
| `
|
|
42
|
-
| `
|
|
43
|
-
| `
|
|
44
|
-
| `
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
-
|
|
50
|
-
-
|
|
51
|
-
- If
|
|
52
|
-
- If
|
|
53
|
-
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
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 frontend
|
|
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
|
|
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
|
|
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
|
|
96
|
-
File claim: <list of exact file paths this agent exclusively owns. Optional; only used in /wf max.>
|
|
97
|
-
Granularity floor: <50 avgLines
|
|
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.
|
|
@@ -49,7 +49,7 @@ Every added skill must state:
|
|
|
49
49
|
- whether to update `Harness/PROGRESS.md` and task files
|
|
50
50
|
- whether to use [subagents.md](subagents.md) and [dispatch.md](dispatch.md)
|
|
51
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`.
|
|
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
53
|
|
|
54
54
|
## Rules
|
|
55
55
|
|