RDF: spec-driven governance for AI coding agents

Make Claude Code, Codex and Antigravity CLI follow your project's rules on every task.
Drop RDF (rfxn Development Framework) on any repo. It detects your stack, writes project
governance and takes each change from spec to ship, with review gates sized to the work.
Quickstart ·
Documentation ·
Commands ·
FAQ ·
Demo walkthrough
Quick Start
You need git, bash 3.2+, jq and an AI coding tool.
From source, with the full rdf CLI:
git clone https://github.com/rfxn/rdf.git ~/rdf && cd ~/rdf
bin/rdf generate claude-code && bin/rdf deploy claude-code
bin/rdf init ~/projects/my-app # detects your stack, scaffolds CLAUDE.md and .rdf/
Or as a Claude Code plugin, with commands namespaced /rdf:r-*:
/plugin marketplace add rfxn/rdf
/plugin install rdf@rdf
Then, in your agent session:
/r-init scan the code and write project governance
/r-start see version, plan progress and warnings
/r-spec describe a change; each command names the next step
Hooks, Codex, Antigravity CLI and upgrades are in the
Quickstart.
1. Why RDF
- Rules that stick: agents read your conventions, constraints and checks before they work
- Review before code: a reviewer challenges the spec and plan, then audits the diff
- Evidence at every gate: test output, grep results and commit hashes
- Process that scales: a docs edit gets a self-report; a credential change gets QA and three-pass review
- One source, several tools: generates for Claude Code, Codex and Antigravity CLI
- Visible spend:
rdf tokens reports usage from local transcripts, and nothing leaves your machine
- Small footprint: the default deploy adds ~0.1K always-loaded tokens, before
CLAUDE.md and skills
2. How It Works
Seven universal agents handle every project, shaped by governance written for your repo.
Enter at any stage, or skip the pipeline: /r-plan --bugfix handles a small fix and
/r-review reviews any diff. See Pipeline and quality gates.
3. Configuration
Most projects need nothing beyond rdf init and /r-init. Your rules live in plain files:
| To change | Edit |
|---|
| Project rules | CLAUDE.md |
| Generated governance | .rdf/governance/, or run /r-refresh |
| Detected stack | rdf init <path> --type rust,infrastructure |
| Supported tools | rdf init <path> --tools codex |
The most specific rule wins:
project CLAUDE.md > workspace CLAUDE.md > profile defaults > core defaults
Everything else is in the configuration reference.
4. Usage
| Command | Purpose |
|---|
/r-start | Load project context and show health |
/r-spec | Research and write a reviewed spec |
/r-plan | Break a spec into phases, or --bugfix for a small fix |
/r-build | Execute phases with TDD and quality gates |
/r-ship | Preflight, verify, release |
/r-verify, /r-review | Run QA or adversarial review on any diff |
/r-save | Sync plan progress, memory and the session log |
rdf doctor | Check project health and convention drift |
rdf tokens | Report Claude Code and Codex token spend |
rdf run, rdf account | Launch a tool in a set mode, on any account |
See all 38 slash commands and the
CLI reference.
Exit codes
| Code | Meaning |
|---|
| 0 | Success |
| 1 | Failure, including a FAIL from rdf doctor |
| 2 | Invalid usage from rdf run or rdf tokens, or an unknown account |