Best for
- You have a todo.md, checklist.md, or any markdown file with - [ ] checkbox items
- You want to dispatch independent checklist items as parallel swarm tasks
- You need to avoid hand-expanding long task lists into manual TaskCreate loops
Jamie-BitFlight/claude_skills/.claude/skills/swarm-from-markdown/SKILL.md
Parse a markdown file's unchecked checkbox items (- [ ]) and generate a self-organizing Claude Code swarm task pool. Use when you have a todo.md, checklist.md, or any markdown file with checkbox items and want to dispatch them as parallel swarm tasks using TeamCreate + TaskCreate + worker agents. Skips checked items (- [x] / - [X]) automatically.
Decision brief
Converts a markdown checklist file into a self-organizing Claude Code swarm. Each unchecked - [ ] item becomes a TaskCreate call and a spawned worker agent. Checked items (- [x], - [X]) are skipped automatically.
Compatibility matrix
| Platform | Status | Evidence | What to check |
|---|---|---|---|
| Codex | Not declared | No explicit evidence | Portability before use |
| Claude Code | Declared | Source record | Install path and trigger |
| Cursor | Not declared | No explicit evidence | Portability before use |
| Gemini CLI | Not declared | No explicit evidence | Portability before use |
Installation
The source command is displayed only when detected. A safe inspection prompt is always available so your agent can explain every action before execution.
npx skills add https://github.com/Jamie-BitFlight/claude_skills --skill ".claude/skills/swarm-from-markdown"Inspect the Agent Skill "swarm-from-markdown" from https://github.com/Jamie-BitFlight/claude_skills/blob/a00194f25fec502d3d659b7d610369614967251e/.claude/skills/swarm-from-markdown/SKILL.md at commit a00194f25fec502d3d659b7d610369614967251e. List every install step, command, network request, credential, file read/write, external action, and rollback step. Explain whether it fits my task. Do not install or execute anything until I approve.
Workflow
Then orchestrate the swarm:
You have a todo.md, checklist.md, or any markdown file with - [ ] checkbox items
1. Parse the markdown file using the marko GFM AST (not regex). 2. Walk the AST: collect ListItem nodes whose child Paragraph has checked is False. 3. Assign each item a 0-based index — worker-{index} — over unchecked items only. 4. Derive team name from the filename stem: swarm…
The checkbox checked attribute lives on the Paragraph child of a ListItem, not on the ListItem itself. The guard child.checked is not False skips both checked items (True) and non-checkbox list items (None).
Review the “CLI Script Reference” section in the pinned source before continuing.
Permission review
No configured static risk pattern was detected
This is not proof of safety. Runtime behavior, indirect dependencies, and hidden external systems are outside the static scan.
Evidence record
| Signal | Value | Evidence type | Meaning |
|---|---|---|---|
| Quality score | 91/100 | Computed | Documentation, specificity, maintenance, and trust rules |
| Repository stars | 64 | Source | Repository attention, not individual Skill quality |
| Compatibility | 1 platforms | Source | Declared in the catalog source record |
| Usage guide | automated source guide | Editorial | Generated or reviewed according to the visible evidence level |
Pinned source
Converts a markdown checklist file into a self-organizing Claude Code swarm. Each unchecked - [ ] item becomes a TaskCreate call and a spawned worker agent. Checked items (- [x], - [X]) are skipped automatically.
Use when:
todo.md, checklist.md, or any markdown file with - [ ] checkbox itemsTaskCreate loopsGiven tasks.md:
- [ ] Implement the login endpoint
- [x] Already done — skip this
- [ ] Write unit tests for auth
- [ ] Update API documentation
Run the parser:
uv run scripts/markdown_to_task_pool.py tasks.md --json
Output:
{
"team_name": "swarm-tasks",
"items": [
{"index": 0, "worker_id": "worker-0", "text": "Implement the login endpoint"},
{"index": 1, "worker_id": "worker-1", "text": "Write unit tests for auth"},
{"index": 2, "worker_id": "worker-2", "text": "Update API documentation"}
],
"worker_count": 3
}
Then orchestrate the swarm:
// Step 1 — Create team
TeamCreate({ team_name: "swarm-tasks" })
// Step 2 — Create one task per unchecked item (checked item is excluded)
TaskCreate({ subject: "Implement the login endpoint", description: "Implement the login endpoint", activeForm: "Working on Implement the login endpoint..." })
TaskCreate({ subject: "Write unit tests for auth", description: "Write unit tests for auth", activeForm: "Working on Write unit tests for auth..." })
TaskCreate({ subject: "Update API documentation", description: "Update API documentation", activeForm: "Working on Update API documentation..." })
// Step 3 — Spawn one worker per task (or use --workers N to cap concurrency)
Agent({ team_name: "swarm-tasks", name: "worker-0", subagent_type: "general-purpose", prompt: "...", run_in_background: true })
Agent({ team_name: "swarm-tasks", name: "worker-1", subagent_type: "general-purpose", prompt: "...", run_in_background: true })
Agent({ team_name: "swarm-tasks", name: "worker-2", subagent_type: "general-purpose", prompt: "...", run_in_background: true })
// Step 4 — Observe pool state
TaskList()
The [x] checked item never appears in any TaskCreate call.
ListItem nodes whose child Paragraph has checked is False.worker-{index} — over unchecked items only.swarm-{stem}.TaskCreate sequence and worker count.Worker IDs are stable when items are only appended: re-running on the same file with new items added at the end preserves existing IDs. Checking (completing) an earlier item shifts all subsequent unchecked items to lower indices — do not resume a partially-executed swarm after checking items mid-list.
The checkbox checked attribute lives on the Paragraph child of a ListItem, not on the ListItem itself. The guard child.checked is not False skips both checked items (True) and non-checkbox list items (None).
from marko import Markdown
from marko.block import List, ListItem, Paragraph
from marko.inline import RawText
md = Markdown(extensions=["gfm"])
doc = md.parse(markdown_text) # parse() returns AST — do NOT call md() which returns HTML
results = []
for node in doc.children:
if not isinstance(node, List):
continue
for item in node.children:
if not isinstance(item, ListItem):
continue
for child in item.children:
if not isinstance(child, Paragraph) or not hasattr(child, "checked"):
continue
if child.checked is not False: # True=checked, None=non-checkbox — both skip
continue
text_parts = [c.children.strip() for c in child.children if isinstance(c, RawText)]
text = " ".join(text_parts).strip()
if text:
results.append(text)
Marko normalizes [x] and [X] to checked=True at parse time — no separate patterns needed.
uv run scripts/markdown_to_task_pool.py <markdown_file> [--workers N] [--json] [-h]
| Argument | Description |
|---|---|
markdown_file | Path to markdown file with checkbox items |
--workers N | Number of worker agents to spawn (default: number of unchecked items) |
--json | Emit JSON instead of human-readable output |
-h | Show help |
Examples:
# Human-readable output
uv run scripts/markdown_to_task_pool.py todo.md
# JSON output (pipe to orchestration script)
uv run scripts/markdown_to_task_pool.py tasks.md --json
# Cap workers at 3 regardless of item count
uv run scripts/markdown_to_task_pool.py tasks.md --json --workers 3
--workers N overrides the worker count while item count stays unchanged. Use it to cap concurrency when you have many items but want fewer parallel agents.
Full orchestration for a file with N unchecked items:
// 1. Parse the file
// uv run scripts/markdown_to_task_pool.py <file> --json
// → { "team_name": "swarm-{stem}", "items": [...], "worker_count": N }
// 2. Create team
TeamCreate({ team_name: "swarm-{stem}" })
// 3. Create tasks — one per unchecked item (loop over items array from script output)
// Each unchecked item becomes one task; checked items are absent from items array
// See the worked example above for concrete TaskCreate calls
// 4. Spawn workers — one per item (or --workers N if capped)
Agent({ team_name: "swarm-{stem}", name: "{item.worker_id}", subagent_type: "general-purpose", prompt: WORKER_PROMPT, run_in_background: true })
// ... repeated for each worker
// 5. Observe and synthesize
TaskList()
// Collect findings via SendMessage team-lead channel
Each worker receives this 8-step self-organizing prompt, parameterized by {team_name} and {worker_id}:
You are swarm worker {worker_id} in team {team_name}.
Your job loop:
1. Call TaskList() to see all tasks in the pool.
2. Find a task with status 'pending' and no owner field set.
3. Claim it: call TaskUpdate with owner={worker_id} and status='in-progress'.
4. Re-read the task description and do the actual work.
5. Mark it done: call TaskUpdate with status='complete' and add a result summary.
6. Send your findings to the team-lead: SendMessage({ type: "direct_message", recipient: "team-lead", content: "Completed: {task subject} — {summary}" }).
7. Repeat from step 1 until TaskList() shows no pending tasks with no owner.
8. Send shutdown acknowledgment: SendMessage({ type: "shutdown_acknowledgment", recipient: "team-lead", content: "No tasks remain. Shutting down." }).
All workers run the same prompt. They race to claim tasks and naturally load-balance — no central coordinator needed.
JSON schema emitted by --json:
{
"team_name": "swarm-{stem}",
"items": [
{"index": 0, "worker_id": "worker-0", "text": "First unchecked item text"},
{"index": 1, "worker_id": "worker-1", "text": "Second unchecked item text"}
],
"worker_count": 2
}
team_name: swarm- prefix + markdown filename stem (no extension)items: only unchecked items — checked items are absentindex: 0-based over unchecked items onlyworker_id: worker-{index}worker_count: defaults to len(items); overridden by --workers NExit codes: 0 on success (including zero-item case), 1 on file-not-found or parse failure.
This skill automates the manual TaskCreate loop at lines 109-114 of ../swarm-patterns/SKILL.md (Pattern 3: Self-Organizing Swarm).
The "Todo-Driven Delegation" pattern — parsing todo.md checkbox items and generating worker assignments from item indices — originates in the Octogent agent framework:
SOURCE: ../../../research/agent-frameworks/octogent.md lines 51-53 (accessed 2026-05-19): "todo.md contains markdown checkbox items. The runtime parses these items and generates worker prompts from them. Incomplete items automatically become worker assignments in swarm runs, and terminal IDs like <tentacle-id>-swarm-0 are derived from parsed item indices."
Frequently asked questions
Converts a markdown checklist file into a self-organizing Claude Code swarm. Each unchecked - [ ] item becomes a TaskCreate call and a spawned worker agent. Checked items (- [x], - [X]) are skipped automatically.
The source record exposes this install command: npx skills add https://github.com/Jamie-BitFlight/claude_skills --skill ".claude/skills/swarm-from-markdown". Inspect the command and pinned source before running it.
The pinned source record declares support for: claude code.
Alternatives
oaustegard/claude-skills
Generate hierarchical _FEATURES.md files that describe what a codebase DOES from a user/consumer perspective, anchored to source symbols via tree-sitting. Supports large complex codebases through feature-driven decomposition into sub-feature files. Uses a multi-pass synthesis: orientation → detail → overview rewrite. Use when someone says "what does this do", "document features", "feature inventory", "_FEATURES.md", or needs to understand a codebase's purpose before modifying it. Complements tre
apollographql/skills
Guide for creating effective skills for Apollo GraphQL and GraphQL development. Use this skill when: (1) users want to create a new skill, (2) users want to update an existing skill, (3) users ask about skill structure or best practices, (4) users need help writing SKILL.md files.
terrylica/cc-skills
Park a draft message/text in macOS Notes for the operator to review and edit, then read it back before acting (e.g. before sending to a real person). Notes is the source of truth (AppleScript CRUD, iCloud-synced, provenance-stamped with the Claude Code session UUID); Stickies is a best-effort view-only desktop mirror. Use whenever you draft something a human should confirm/edit before it is sent or committed — messages, replies, announcements, anything outbound. TRIGGERS - park this draft, park
narrative-io/narrative-skills-marketplace
Translate a fuzzy analytical question into a rigorous investigation plan. Interrogates the ask, grounds the plan in the available data dictionary, applies analytical best practices, and produces a structured brief of query specifications for a downstream query-writing skill. Plans, does not write SQL. Use when: "why did X drop", "is there a relationship between A and B", "who are our highest-value customers", "what's driving the change in Y", "investigate this trend", "design an analysis for", "