Use when planning work (to create items and tasks), when starting implementation (to claim and work tasks), when completing work (to mark tasks done), or to check backlog status. Manages .backlogmd/ with manifest.json for features, bugfixes, refactors, and chores.
backlog system. You can create items (features, bugfixes, refactors, chores) and tasks, claim and release tasks, update statuses, edit content, and archive completed work. The manifest (
manifest.json
) is the machine-readable index — read it before acting and update it alongside every file edit.
Workflow (MANDATORY)
RULE: For new features, bugfixes, refactors, or chores — create or update backlog items BEFORE writing code. The backlog is the source of truth for planned work. For small iterations on an existing task (tweaks, adjustments, follow-ups), you may skip backlog updates and just work.
Before planning: Read
manifest.json
and check the backlog for existing items and tasks.
When planning: Create items and tasks in the backlog FIRST, before any implementation. Don't just describe plans in conversation — record them. New tasks start as
open
(ready for agents) or
plan
(draft, needs human promotion).
Wait for approval: After planning, present the plan to the user and STOP. Do NOT start implementing until the user explicitly approves.
When implementing: Follow this loop for EACH task, one at a time:
Claim the task: set
s: reserved
,
a: <agent-id>
.
Start the task: set
s: ip
(verify every
dep
path resolves to a task with
s: done
first).
Implement the task.
Complete the task: if
h: false
, set
s: done
and clear
a
. If
h: true
, set
s: review
and stop — only a human may move
review → done
.
Only then move to the next task.
Always write manifest first, then task file, then
index.md
.
When all tasks are done: Inform the user and ask if they want to archive the item.
Spec v3.0.1 (embedded)
Single source of truth for
.backlogmd/
is
SPEC.md
in the repo; this section embeds the key rules so the skill is self-contained. When in doubt, prefer
Bullet list of relative links to task files within the same directory.
Sorted by task id (
tid
) ascending.
Format:
- [<tid>-<task-slug>](<tid>-<task-slug>.md)
Task Format (
work/<item-id>-<slug>/<tid>-<task-slug>.md
)
md
<!-- METADATA -->```yamlt: Add login form
s: plan # plan | open | reserved | ip | review | block | donep:10# priority within item (lower = higher priority)dep:["work/002-ci-initialize-github-actions/001-ci-cd-setup.md"]# optional: paths (relative to .backlogmd/) to tasks that must be done before this task can starta:""# assignee/agent id; empty string if unassignedh:false# true if human review required before doneexpiresAt:null# ISO 8601 timestamp for reservation expiry, or null```<!-- DESCRIPTION -->## Description<detaileddescription><!-- ACCEPTANCE -->## Acceptance criteria- [ ] <criterion>
). Cross-item deps allowed. Agents must wait for each referenced task to be
s: done
before moving to
ip
. No self-reference; no duplicates; no cycles (backlog must remain a DAG).
Three HTML comment markers only:
<!-- METADATA -->
,
<!-- DESCRIPTION -->
,
<!-- ACCEPTANCE -->
.
Acceptance criteria use markdown checkboxes.
No YAML frontmatter outside the fenced block; keep metadata lines ≤ 120 chars.
Manifest (
manifest.json
)
Machine-readable index. Agents MUST read the manifest before acting and MUST update it alongside every file edit. The file is strict JSON (no trailing commas, no comments).
"what's the current state?", "show backlog", "what's in progress?"
Sanity check
"check backlog", "validate backlog", "sanity check", "is the backlog consistent?"
If the intent is ambiguous, ask the user to clarify before proceeding.
Inferring the Type (optional)
When creating an item, you may infer a Conventional Commits type from context to include in the slug. This is optional — slugs without a type are valid.
Words like "add", "implement", "build", "create" →
feat
Words like "fix", "bug", "broken", "crash", "error" →
fix
Words like "refactor", "clean up", "simplify", "restructure" →
refactor
Words like "update deps", "migrate", "maintenance", "chore" →
chore
If the type is unclear, omit it.
Operation A: Create a new item
A1. Propose the item and tasks
Based on
$ARGUMENTS
, propose:
Item name — short, descriptive title
Type (optional) — Conventional Commits type to include in the slug (e.g.
feat
,
fix
,
refactor
,
chore
)
Tasks — break the item into concrete implementation tasks. For each task propose:
Task name (
t
)
Short description (2–3 sentences)
Acceptance criteria (as checkbox items)
Whether human review is required (
h
)
Present the full proposal and ask for confirmation or edits before writing any files.
A2. Item placement
After user confirms:
Read
manifest.json
to get current
openItemCount
and existing item IDs.
Determine the next available
item-id
.
Then:
If open items exist: List them and ask whether to add tasks to an existing item or create a new one.
If no open items exist: Proceed with creating a new item folder.
If 50 items already exist: Archive a completed item first (all tasks
done
), then create. If none can be archived, inform the user.
Every task has YAML metadata with required fields:
t
,
s
,
p
,
dep
,
a
,
h
,
expiresAt
.
Task statuses are valid (
plan
,
open
,
reserved
,
ip
,
review
,
block
,
done
).
dep
values are paths relative to
.backlogmd/
:
work/<item-id>-<slug>/<tid>-<task-slug>.md
; no self-references, no duplicates, no cycles (DAG across backlog).
Item IDs and task IDs are zero-padded (min 3 digits) and unique in their scope.
Slugs are lowercase kebab-case.
reserved
,
ip
,
review
tasks have non-empty
a
.
done
tasks have empty
a
.
No YAML frontmatter outside the fenced code block.
F4. Validate manifest consistency
Every item in
manifest.json
with
status: "open"
has a folder in
work/
.
Every task in manifest matches its task file for
s
,
a
,
p
,
dep
,
h
,
expiresAt
.
openItemCount
matches the actual count of non-archived items.
Manifest
t
matches the task file's
t
field.
F5. Validate dependencies and workflow
No circular dependencies across the backlog (all
dep
paths form a DAG).
No task is
ip
while any of its
dep
(resolved by path to manifest task) is not
done
.
No task with
h: true
has transitioned directly from
ip
to
done
(should go through
review
).
F6. Validate archive
Archived item folders in
.archive/
are not also present in
work/
.
backlog.md
does not reference archived items.
Archived items in manifest have
status: "archived"
.
F7. Report
Present results as:
Errors — spec violations that must be fixed (missing files, broken links, invalid statuses, manifest mismatches).
Warnings — potential issues (items with all tasks done but not archived, stale
expiresAt
).
OK — checks that passed.
If errors are found, offer to fix them automatically (with user confirmation before writing). For manifest/file mismatches, follow reconciliation rules (manifest wins for status/assignment, task file wins for content).
Rules
Follow the spec formats exactly — YAML metadata in fenced code blocks, no YAML frontmatter.
All paths are relative within
.backlogmd/
.
Always update
manifest.json
first, then task files, then
index.md
.
Never overwrite existing items or tasks — only append (for creation) or edit in place (for updates).
Always confirm with the user before writing or modifying files.
Max 50 open items in
work/
. If the limit is reached, the user must archive an item or use an existing one.
The
.archive/
directory is cold storage. After moving items into it, never modify them again.
A completed task cannot be reopened. If the work needs revisiting, create a new task instead.