Executable Rules
Write rules in TypeScript. Archgate runs them against your codebase and reports violations with file paths and line numbers. Rules live next to the decisions they enforce.
Archgate has two layers that work together:
ADRs as documents — Markdown files with YAML frontmatter that describe architectural decisions in plain language. Humans read them. AI agents read them. Everyone stays aligned.
ADRs as rules — Companion .rules.ts files with automated checks written in TypeScript. They run against your codebase and report violations with file paths and line numbers.
.archgate/ adrs/ ARCH-001-command-structure.md # The decision (human + AI readable) ARCH-001-command-structure.rules.ts # The checks (machine executable) ARCH-002-error-handling.md ARCH-002-error-handling.rules.ts lint/ archgate.config.ts # Archgate configurationWhen you run archgate check, the CLI loads every ADR that has rules: true in its frontmatter, executes the companion rules file, and reports any violations. Exit code 0 means your code complies. Exit code 1 means it does not.
Executable Rules
Write rules in TypeScript. Archgate runs them against your codebase and reports violations with file paths and line numbers. Rules live next to the decisions they enforce.
CI Integration
Wire archgate check into your pipeline. Exit code 1 blocks merges when
rules are violated. Works with GitHub Actions, GitLab CI, or any CI system
that respects exit codes.
AI-Aware Governance
The MCP server gives AI agents live access to your ADRs. They read decisions before writing code and validate after. No copy-pasting rules into prompts.
Self-Governance
Archgate governs its own development. The same tool that checks your code checks ours. Six ADRs enforce command structure, error handling, output formatting, testing, and more.
The Archgate CLI works standalone, but editor plugins unlock a full AI governance workflow. Plugins give AI agents role-based skills so they read your ADRs before coding, validate after, and capture new patterns for your team — automatically.
Claude Code
The Claude Code plugin adds five skills: developer, architect, quality-manager, adr-author, and onboard. Agents follow a structured read-validate-capture loop on every task.
Cursor
The Cursor plugin provides pre-built agent rules and skills that give Cursor’s AI agent the same governance workflow as Claude Code.