Help us improve
Share bugs, ideas, or general feedback.
From harness
Decomposes failing tests into atomic task DAGs with wave-based parallel execution, analyzes module dependencies, and generates AGENT.md files plus module graphs.
npx claudepluginhub zxdxjtu/harness --plugin harnessHow this skill is triggered — by the user, by Claude, or both
Slash command
/harness:decomposeThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
**Parameter**: $ARGUMENTS — feature ID (e.g. F001)
Generates hierarchical TDD task breakdowns from approved SDD designs, applying test pyramid (unit/integration/E2E) and red-green-refactor cycles for implementable work items.
Generates TDD-ready task specs from feature plans via developer collaboration, drafting test plans and embedding specs into the plan document before coding.
Breaks a designed feature into atomic ≤1-day tasks with a dependency graph, per-task Definition of Done, and a machine-readable tasks.json for the implement engine. Requires spec.md, sad.md, and an Accepted ADR.
Share bugs, ideas, or general feedback.
Parameter: $ARGUMENTS — feature ID (e.g. F001)
approved (or reviewed if spec-review was in the flow)Read all test files for this feature. List every test ID.
Map each test ID (or group of closely related tests) to one atomic task.
Each task must satisfy:
Determine task ordering:
Analyze which code modules each task will touch:
.harness/full-design.mdRead the template from the harness plugin's templates/agent-md-template.md and generate a module-specific AGENT.md:
# Module: {module-name}
## Path: {relative/path}
## Last Updated: {ISO timestamp}
## Responsibilities
{derived from code analysis and design doc}
## Boundaries
- **Owns**: {files in this directory}
- **Depends On**: {modules imported by this module}
- **Depended By**: {modules that import this module}
- **Forbidden Dependencies**: {inferred from architecture — e.g. UI modules should not import from CLI}
## Quality Standards
{derived from project config and existing linting rules}
## Interface Contract
- **Exports**: {detected public API}
- **Data Flow**: {input/output shapes}
## Change History
| Date | Change | Impact | Reviewer |
|------|--------|--------|----------|
Place AGENT.md in the actual module directory (e.g. src/auth/AGENT.md).
.harness/module-graph.json:{
"modules": {
"src/auth": {
"agent_md": "src/auth/AGENT.md",
"depends_on": ["src/db", "src/config"],
"depended_by": ["src/api", "src/middleware"],
"forbidden": ["src/ui"]
}
},
"last_updated": "{ISO timestamp}"
}
Write to .harness/tasks.md:
# Tasks — $ARGUMENTS
## DAG Visualization
Wave 1: [T001] [T002] [T005] ← parallel, no dependencies
Wave 2: [T003] [T006] ← depends on Wave 1
Wave 3: [T004] ← depends on Wave 2
Wave 4: [T007] [T008] ← E2E verification
## Task List
| ID | Name | Wave | Status | Tests | Retries | BlockedBy | Files | Modules |
|----|------|------|--------|-------|---------|-----------|-------|---------|
| T001 | desc | 1 | pending | T001-V1 | 0 | - | src/... | src/auth |
| T002 | desc | 1 | pending | T002-V1 | 0 | - | src/... | src/db |
| T003 | desc | 2 | pending | T003-V1,V2 | 0 | T001 | src/... | src/auth, src/api |
## Module Stewardship
| Module | AGENT.md | Tasks Affecting | Guardian Active |
|--------|----------|----------------|-----------------|
| src/auth | src/auth/AGENT.md | T001, T003 | Yes |
| src/db | src/db/AGENT.md | T002 | Yes |
## Summary
- Total tasks: N
- Waves: M
- Modules affected: K
- AGENT.md files generated: J
- Estimated parallel speedup: Nx → Mx
Append to .harness/progress.md:
## [timestamp] Task Decomposition — $ARGUMENTS
- Total tasks: N
- Waves: M
- Modules with stewardship: K
- Status: awaiting human approval
Present the DAG and module stewardship plan to the user. Ask:
"任务拆解完成:{N} 个原子任务,分 {M} 个 Wave,涉及 {K} 个模块(已生成 AGENT.md)。任务依赖关系是否正确?有需要拆分或合并的任务吗?"
Do NOT proceed until approved.
flow field from the spec📋 SDD 进度 — {FXXX}: {feature name}
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
✅ proposal → ✅ tdd-align → ✅ decompose → ⬜ sprint → ...
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
当前阶段: decompose (任务拆解 + 责任田) ✅ 已完成
下一阶段: sprint (自动执行)