🛡️ Rigour
Local-first quality gates for AI-generated code.
Rigour forces AI agents to meet strict engineering standards before marking tasks "Done".
Zero cloud. Zero telemetry. PASS/FAIL is always free.
🚀 Quick Start
npx @rigour-labs/cli init # Initialize quality gates
npx @rigour-labs/cli check # Verify code quality
npx @rigour-labs/cli run -- claude "Build feature X" # Agent loop
🛑 The "Vibe Coding" Trap
AI agents often fall into a cycle of "Guess and Hope":
- Agent makes a change.
- Agent claims "Task 100% complete" or "CI will pass now."
- Agent pushes to remote.
- CI Fails (Type error, lint failure, broken test).
This is "Vibe Coding"—the agent is hallucinating success based on narrative, not execution.
Rigour breaks this cycle. It forces the agent to face the same cold, hard verification tools (ruff, mypy, vitest) that CI runs, but locally and immediately. Rigour turns a "claim of victory" into a "proof of execution."
🔄 How It Works
Agent writes code → Rigour checks → FAIL? → Fix Packet → Agent retries → PASS ✓
The rigour run command loops until your agent achieves PASS or hits max iterations.
⚙️ What Gets Checked
| Gate | Description |
|---|---|
| File Size | Max lines per file (default: 300-500) |
| Hygiene | No TODO/FIXME comments allowed |
| Complexity | Cyclomatic complexity limits (AST-based) |
| Required Docs | SPEC.md, ARCH.md, README must exist |
| Safety Rails | Protected paths, max files changed |
| Context Alignment | Prevents drift by anchoring on project patterns |
🤖 Works With
- Claude Code:
rigour run -- claude "..." - Cursor / Cline / Gemini: Via high-fidelity MCP server (
rigour_check,rigour_explain)
📖 Documentation
| Quick Links | |
|---|---|
| Getting Started | Install and run in 60 seconds |
| CLI Reference | All commands and options |
| Configuration | Customize quality gates |
| MCP Integration | AI agent setup |
| Concepts | How Rigour works |
🧪 CI Integration
- run: npx @rigour-labs/cli check --ci
See full example for GitHub Actions setup.
📜 License
MIT © Rigour Labs
"Rigour adds the engineering."