Skip to main content
You author the substrate once. forge sync compiles that source into each tool’s native config. The four layers are how the brain is expressed; the compiler is how it is delivered.

One source, many emitters

Author rules once (source/rules.json); a deterministic compiler (forge sync) emits each tool’s native format with a content-hash header, so drift is detectable and re-running is a no-op. No rule is ever written twice. The canonical source is three files:

The four layers

Each layer is brand-named and emitted cross-tool.
~/.forge/tools/~/.claude/skills/. Model-invoked skills, following the SKILL.md standard (name + description frontmatter).
~/.forge/crew/~/.claude/agents/. Isolated-context sub-agents such as scout, verifier, and frontend-verifier.
~/.forge/guards/settings.json hooks. The only layer that enforces rather than suggests. A guard is a deterministic hook the model cannot drift from. Prose rules in CLAUDE.md get acknowledged and then forgotten after compaction; a guard does not. Every enforceable invariant belongs here.
Forge ships one stdio server (src/cortex_mcp.js) exposing 19 MCP tools: the substrate checks (substrate_check / predict_impact / assumption_gate / …), memory reads and writes (forge_remember, ledger ratify/retract), and ops/health.
Cross-cutting concerns thread through all four: atlas (the code graph), lean (minimalism — shipped as both a tool and a Stop-guard, so it applies whether or not the model invokes it), and recall (memory).

Guard over prose

Rules the model can drift from live in prose; rules it must never break live in guards (deterministic shell hooks). A guard can’t be forgotten after context compaction.
Move every enforceable invariant out of CLAUDE.md and into a guard; keep the prose thin. This is the single most important discipline in Forge’s design.

The verified cross-tool emit matrix

Forge emits config for nine tools, plus an MCP server for Roo Code and VS Code. Each row is confirmed against vendor docs. Roo Code and VS Code receive the Forge MCP server via forge init (.roo/mcp.json, .vscode/mcp.json) rather than a rules file.
Char caps are real. Codex truncates at 32 KiB, Windsurf at 6k/12k. forge sync enforces a source size budget so a config never silently truncates.