← Back to Discover

agent-runbook

A command-line tool that turns YAML runbooks, with typed inputs and outputs for every step, into SKILL.md files that Claude Code or Codex can run, with loops, branching, parallel steps and checkpoints.

Agent frameworksCommand-line tools

What it does

agent-runbook lets you write a multi-step agent workflow once, as a YAML runbook, and generate a SKILL.md for Claude Code or Codex with one command. Every step declares its input and output with JSON Schema, and the compiler checks at build time that those contracts line up, that referenced schemas resolve and that the step graph has no cycles. Steps can be inline prompts, independent sub-agents, shell or Python scripts, parallel groups, conditional branches, loops that repeat until a goal is met or a maximum is reached, checkpoints and quality-check gates. Steps pass data to each other through files instead of the model's context, which the page says keeps each step's context clean and lets a broken run resume from its last checkpoint. It installs with pip from the GitHub repository and runs as python3 -m agent_runbook generate. The README includes a restart-nginx example and a fix-loop demo that reruns pytest and fixes failing files until the suite is green. It is Apache-2.0 licensed, and the page says it is in active development so the API may change.

Capabilities

  • Compiles YAML runbooks into SKILL.md for Claude Code and Codex
  • JSON Schema contracts on every step, validated at build time
  • Loop, branch, parallel, script and checkpoint step types
  • File-based state passing between steps
  • Resume a broken run from its last checkpoint
  • Quality-check gates that can block progress

When to use it

  • You build multi-step workflows in Claude Code or Codex that need more than a linear prompt
  • You want agents to hand results to each other through structured files
  • You want a long workflow to resume after a crash instead of restarting