sw-increment
Skill164 starsChanged 13 months agoMITView on GitHub
Plan work as a SpecWeave increment - one spec.md with Problem, Scope, numbered ACs, Approach and Tasks - before writing code. Use for "plan a feature", "new increment", "let's build X".
In this repository12 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- sw-autoSkill
- sw-brainstormSkill
- sw-doneSkill
- sw-doSkill
- sw-handoffSkill
- sw-jevSkill
- sw-projectSkill
- sw-reviewSkill
- sw-syncSkill
- sw-teamSkill
The file
We split this skill into the rules it gives an agent
4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 19
Ask only what changes the spec: the problem behind the request, what is out of scope, how you will know it works.
- Distinctive: line 21
Read the code the change touches before writing Approach.
- Very specific: line 36
Write UTF-8 without a BOM.
- Very specific: line 67
Every AC is covered by at least one task.
≈ “Common” is an estimate: at least 1 in 5 of the 213,897 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
sw-increment: plan the unit of work
An increment is one folder, .specweave/increments/NNNN-slug/, with one file you write:
spec.md. ledger.jsonl beside it holds task state and is only appended to;
metadata.json is machine state you never need to read. One increment is one branch
and one PR.
Before writing
- A small self-contained fix needs no increment. Just do it.
- An open increment already owns the files this touches (
specweave task list)? Add ACs and tasks to its spec.md instead of opening another. - Ask only what changes the spec: the problem behind the request, what is out of scope, how you will know it works. A clear request needs no interview.
- Read the code the change touches before writing Approach.
Create it
specweave create-increment "Add rate limiting" prints the new folder with a scaffolded
spec.md; replace every [bracket]. Add --supersedes 0031 when this replaces an older
increment (that one is abandoned for you), --planned for backlog work.
Manual path (no CLI): next id = highest folder number + 1, zero-padded to 4. Create
NNNN-kebab-slug/ with spec.md, an empty ledger.jsonl and this metadata.json:
{"id":"0042-ledger-fold","status":"active","type":"feature","created":"2026-09-02T10:00:00Z","lastActivity":"2026-09-02T10:00:00Z"}Write UTF-8 without a BOM; in PowerShell use
[IO.File]::WriteAllText($p, $body, [Text.UTF8Encoding]::new($false)), never >.
spec.md
# 0042 Ledger fold
## Problem
Two agents can both believe they own T-01. Who hits it, and the evidence.
## Scope
In: claim ordering, malformed lines. Out: a ledger server.
## Acceptance Criteria
- [ ] AC-01: Two agents claiming the same task never both get it
- [ ] AC-02: A malformed ledger line is skipped and counted, never fatal
## Approach
Files that change and in what order, decisions, rejected alternatives, risks.
## Tasks
### T-01 Fold the ledger
- AC: AC-01 | Files: src/core/tasks/ledger.ts, src/core/tasks/ledger.test.ts | Test: npm test -- ledger
### T-02 Skip malformed lines
- AC: AC-02 | Files: src/core/tasks/ledger-parse.ts | Test: npm test -- ledger- ACs are observable: "p95 of /search under 300 ms with 10k rows", not "faster".
- Every AC is covered by at least one task; every task names its
Filesand aTestcommand a machine can run. Filesis the ownership unit: two tasks that edit one file cannot run in parallel, so merge them. Shared contracts (types, schema) go in an early task.- An AC is met when every task covering it is done. Nobody ticks the boxes; never write state into spec.md.
plan.mdis optional overflow for a genuinely large design.
Then
Show the ACs and tasks. Unless the user asked to review the plan first, carry on with sw-do (one agent) or sw-team (three or more disjoint lanes).
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

