From agent-harness
Use when you have a spec or requirements for a multi-step task, before touching code
How this skill is triggered — by the user, by Claude, or both
Slash command
/agent-harness:writing-plansWhen to use
[feedforward] Triggered after brainstorming, before implementation, to decompose work into tasks.
The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Write comprehensive implementation plans assuming the engineer has zero context for our codebase and questionable taste. Document everything they need to know: which files to touch for each task, code, testing, docs they might need to check, how to test it. Give them the whole plan as bite-sized tasks. DRY. YAGNI. TDD. Frequent commits.
Write comprehensive implementation plans assuming the engineer has zero context for our codebase and questionable taste. Document everything they need to know: which files to touch for each task, code, testing, docs they might need to check, how to test it. Give them the whole plan as bite-sized tasks. DRY. YAGNI. TDD. Frequent commits.
Assume they are a skilled developer, but know almost nothing about our toolset or problem domain. Assume they don't know good test design very well.
Announce at start: "I'm using the writing-plans skill to create the implementation plan."
Save plans to: docs/agent-harness/plans/YYYY-MM-DD-<feature-name>.md
git check-ignore <dir>). If so, inform the user and suggest .agent-harness/plans/ as an alternative, but respect the user's choice.If the spec covers multiple independent subsystems, it should have been broken into sub-project specs during brainstorming. If it wasn't, suggest breaking this into separate plans — one per subsystem. Each plan should produce working, testable software on its own.
Before defining tasks, check for sprint contract:
docs/agent-harness/contracts/{feature-name}.contract.mdagent-harness:sprint-contract first
If contract exists: Plan tasks must trace to contract acceptance criteria.
Before defining tasks, map out which files will be created or modified and what each one is responsible for. This is where decomposition decisions get locked in.
This structure informs the task decomposition. Each task should produce self-contained changes that make sense independently.
Each step is one action (2-5 minutes):
Every plan MUST start with this header:
# [Feature Name] Implementation Plan
> **For agentic workers:** REQUIRED SUB-SKILL: Use agent-harness:subagent-driven-development (recommended) or agent-harness:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
**Goal:** [One sentence describing what this builds]
**Architecture:** [2-3 sentences about approach]
**Tech Stack:** [Key technologies/libraries]
---
Before generating tasks, determine the commit strategy:
### Task N: [Component Name]
**Files:**
- Create: `exact/path/to/file.py`
- Modify: `exact/path/to/existing.py:123-145`
- Test: `tests/exact/path/to/test.py`
- [ ] **Step 1: Write the failing test**
```python
def test_specific_behavior():
result = function(input)
assert result == expected
```
- [ ] **Step 2: Run test to verify it fails**
Run: `pytest tests/path/test.py::test_name -v`
Expected: FAIL with "function not defined"
- [ ] **Step 3: Write minimal implementation**
```python
def function(input):
return expected
```
- [ ] **Step 4: Run test to verify it passes**
Run: `pytest tests/path/test.py::test_name -v`
Expected: PASS
- [ ] **Step 5: Commit**
```bash
git add tests/path/test.py src/path/file.py
git commit -m "feat: add specific feature"
```
Every step must contain the actual content an engineer needs. These are plan failures — never write them:
After defining the task list, check whether any task involves a global pattern replacement (token rename, CSS class migration, API signature change, import path shift). If it does, run a project-wide search (Grep) for the pattern before finalizing the plan. List every affected file in the relevant task — do not assume the brainstorming-confirmed file list is exhaustive. A cleanup task that discovers 13 affected files when the plan listed 8 is a plan failure, not a win for the cleanup task.
When the plan references API types (interfaces, request/response types, DTOs), verify each referenced field exists before finalizing the plan:
data-contracts.ts, *.d.ts, auto-generated API types) and confirm every field name and type mentioned in the plan matchesThis prevents plan execution interruptions from type errors discovered during implementation.
After writing the complete plan, look at the spec with fresh eyes and check the plan against it. This is a checklist you run yourself — not a subagent dispatch.
1. Spec coverage: Skim each section/requirement in the spec. Can you point to a task that implements it? List any gaps.
2. Placeholder scan: Search your plan for red flags — any of the patterns from the "No Placeholders" section above. Fix them.
3. Type consistency: Do the types, method signatures, and property names you used in later tasks match what you defined in earlier tasks? A function called clearLayers() in Task 3 but clearFullLayers() in Task 7 is a bug.
If you find issues, fix them inline. No need to re-review — just fix and move on. If you find a spec requirement with no task, add the task.
After saving the plan, offer execution choice:
"Plan complete and saved to docs/agent-harness/plans/<filename>.md. Two execution options:
1. Subagent-Driven (recommended) - I dispatch a fresh subagent per task, review between tasks, fast iteration
2. Inline Execution - Execute tasks in this session using executing-plans, batch execution with checkpoints
Which approach?"
If Subagent-Driven chosen:
If Inline Execution chosen:
npx claudepluginhub evanfang0054/agent-harness --plugin agent-harnessSets up isolated workspaces using native worktree tools or git worktree fallback. Use before starting feature work to protect the current branch.