Skip to content

Task Management

Task management in Crucible uses structured markdown files (typically TASKS.md) to track implementation plans. The file format is designed for both human readability and machine parsing.

TASKS.md files combine:

  • Frontmatter for project metadata
  • Phases to organize work into logical stages
  • Tasks with checkboxes, IDs, and dependencies
  • Inline metadata for machine parsing
---
description: Brief description of the project
context_files:
- path/to/relevant/file.rs
- path/to/another/file.rs
verify: cargo test --workspace
tdd: true
---
## Phase 1: Phase Name
### 1.1 Section Name
- [ ] Task description [id:: 1.1.1]
- Implementation details
- [tests:: test_name_1, test_name_2]
- [ ] Another task [id:: 1.1.2] [deps:: 1.1.1]
- This task depends on 1.1.1
FieldRequiredDescription
descriptionYesBrief description of what this task list accomplishes
context_filesNoList of files relevant to this work (for agent context)
verifyNoCommand to run to verify completion (e.g., just test)
tddNoWhether to follow TDD (test-driven development) workflow

Standard markdown checkboxes with extended statuses:

SymbolStatusDescription
[ ]pendingNot started
[x]completedFinished successfully
[/]in_progressCurrently being worked on
[-]blockedCannot proceed, needs intervention
[!]urgentHigh priority, needs immediate attention
[?]questionNeeds clarification before starting
[w]waitingWaiting on external dependency

Metadata is embedded in task lines using [key:: value] syntax (Dataview-compatible):

KeyDescriptionExample
idUnique task identifier[id:: 1.1.1]
depsComma-separated dependency IDs[deps:: 1.1.1, 1.2.1]
testsTest names to verify this task[tests:: test_foo, test_bar]
priorityTask priority (low/medium/high)[priority:: high]

Task IDs follow the pattern: {phase}.{section}.{task}

  • Phase 1, Section 1, Task 1: 1.1.1
  • Phase 2, Section 3, Task 2: 2.3.2

The cru tasks command provides operations on TASKS.md files:

Terminal window
# List all tasks with status
cru tasks list [path]
# Show next available task (respecting dependencies)
cru tasks next [path]
# Mark a task as in-progress
cru tasks pick <task_id> [path]
# Mark a task as completed
cru tasks done <task_id> [path]
# Mark a task as blocked
cru tasks blocked <task_id> [path]

Tasks with [deps:: ...] metadata won’t be available until all dependencies are completed:

- [x] Create database schema [id:: 1.1.1]
- [ ] Implement CRUD operations [id:: 1.1.2] [deps:: 1.1.1] # Available
- [ ] Add caching layer [id:: 1.1.3] [deps:: 1.1.2] # Not available yet

Task management is implemented as a built-in CLI command in crates/crucible-cli/src/commands/tasks.rs, with parsing support in crucible-core.

TASKS.md serves as more than task tracking—it’s a context management strategy for AI agents.

Traditional agent loops accumulate conversation history:

  • Turn 1: 1k tokens
  • Turn 2: 2k tokens (includes turn 1)
  • Turn N: N×k tokens → context explosion

TASKS.md follows the “Ralph Wiggum” pattern (named after Geoffrey Huntley’s technique):

  1. State lives in files, not conversation history
  2. Each agent iteration gets a fresh context window
  3. The file is read as part of a cached prefix (system prompt position)
  4. Progress accumulates in the file, not in tokens
PositionAttentionCost
Start (TASKS.md)HighCached (75% cheaper)
Middle (old history)LowFull price
End (current query)HighFull price

TASKS.md in the prefix = high attention + amortized cost across iterations.

Instead of passing full conversation history between agents:

## Handoff Notes
- agent-A completed auth schema (see task 1.1.1)
- agent-B found edge case: empty password validation

Curated handoffs in the file replace expensive message passing.

  1. Use descriptive IDs: IDs should reflect the phase/section structure
  2. Keep tasks small: Each task should be completable in one focused session
  3. Specify dependencies explicitly: Don’t assume order implies dependency
  4. Include verification steps: Add [tests::] for testable tasks
  5. Group related work: Use phases and sections to organize logically
  6. Use for context optimization: Keep TASKS.md in the cached prefix for efficient multi-turn agent work
  • Creating Plugins - Plugin development guide
  • Index - Workflow system overview
  • Plugin User Stories - Plugin system user stories