Rulebook

From hivellm/rulebook · View interactive version

Rulebook is an AI agent skill from the GitHub repository hivellm/rulebook. Spec-driven task management for features and breaking changes with OpenSpec-compatible format

How to use this skill

Skill file

Rulebook Task Management

Use Rulebook's task system for spec-driven development. Create a task BEFORE implementing any feature, breaking change, architecture change, or performance/security work. Skip it for bug fixes, typos, and non-breaking dependency updates.

Workflow

  1. Create the task with its content in one call: rulebook_task {action:"create", taskId, why, what, items, impact}

via MCP, or rulebook task create <task-id> --why .. --what .. --item .. — proposal.md and tasks.md are written complete

  1. Add spec deltas (specs/<module>/spec.md) when the change has requirements
  2. Validate: rulebook task validate <task-id>
  3. Implement, checking off tasks.md items in order
  4. Archive when done: rulebook task archive <task-id>

Prefer the MCP tools (rulebook_task/list/show/validate/archive) when the MCP server is enabled. Never create task directories by hand.

Structure

.rulebook/tasks/<task-id>/
├── proposal.md         # Why and what changes
├── tasks.md            # Checklist only — no explanations
├── design.md           # Technical design (optional)
└── specs/<module>/spec.md

Formats

proposal.md: ## Why + ## What Changes + ## Impact (affected specs/code, breaking Y/N).

tasks.md: numbered phases with - [ ] 1.1 <simple item> entries only.

Spec deltas (specs/<module>/spec.md):

## ADDED Requirements

### Requirement: <Name>
The system SHALL <do something>.

#### Scenario: <Name>
Given <context>
When <action>
Then <expected result>

Use ## ADDED / ## MODIFIED / ## REMOVED headers; scenarios use 4 hashtags.

See .rulebook/specs/rulebook.md for the full format reference.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.