
An open-source operating layer for Claude Code and OpenAI Codex.
Citadel helps coding agents work reliably across real repositories. It routes requests, preserves project state between sessions, coordinates parallel work, applies repository safeguards, and records verification and handoffs.
Quick install | Start using it | Is it a fit? | Portable operations | Documentation
Quick install
Requires: Claude Code or OpenAI Codex, Node.js 18+, and a git repository.
Open the repository you want Citadel to manage, then paste this into your coding agent:
Install Citadel in this repository.
Use https://github.com/SethGammon/Citadel as the source. If a local clone
already exists, reuse it or update it. Detect whether this session is running
in OpenAI Codex or Claude Code. From this project's root, run the matching
Citadel installer and report any plugin-enable or restart step it prints.
Use the current repository as the target. Do not require placeholder paths.
Follow any printed enable step, start a fresh session if prompted, then run:
/do setup --express
Setup installs the project hooks and creates the repo-local state Citadel uses to resume work later.
Manual installation
Clone Citadel once:
git clone https://github.com/SethGammon/Citadel.git ~/Citadel
From the repository you want Citadel to manage, run the installer for your runtime.
OpenAI Codex
node ~/Citadel/scripts/install.js --runtime codex --add-marketplace
Claude Code
node ~/Citadel/scripts/install.js --runtime claude --install --scope local
Start a fresh session in the same repository and run /do setup --express.
Dry runs, generated paths, runtime-specific setup, and rollback are documented in Installation.
Start using it
You do not need to learn the skill catalog. Start with /do and describe the outcome:
/do review README.md
/do generate tests for the changed files
/do next
| Command | What it gives you |
|---|
/do <request> | Selects and runs the appropriate workflow |
/do next | Shows active work, risks, and the next useful action |
/dashboard | Opens Mission Control for campaigns, agents, operations, hooks, and handoffs |
/cost | Reports token use and session cost from available local telemetry |
For a copyable walkthrough in a real repository, use the demo workflow.
When Citadel is useful
Citadel is most useful when coding-agent work extends beyond a single prompt:
| You are dealing with... | Citadel adds... |
|---|
| Repeated setup and lost context | Repo-local campaigns, decisions, discoveries, and handoffs |
| Unclear workflow choice | One natural-language entry point through /do |
| Risky or multi-step changes | Approval boundaries, lifecycle hooks, and explicit verification |
| Several agents or branches | Isolated worktrees, ownership, and shared discoveries |
| Work that must survive interruption | Durable state, recovery, and a concrete next action |
For a short, one-off edit, your coding agent may already be enough. Citadel becomes valuable when the operating discipline around the agent is the hard part.
Citadel does not replace CLAUDE.md or AGENTS.md. Those files describe the project and its rules. Citadel supplies the workflows and state used to carry them out consistently.
One operating loop
- Route:
/do chooses a focused skill, a coordinated session, a persistent campaign, or a parallel fleet.
- Execute and verify: hooks apply repository rules, gate consequential actions, and capture required checks.
- Record and resume: Citadel writes the result, handoff, and next action to the repository for the next session.
The repository remains the source of truth. Citadel adds an operating layer around the coding agent rather than replacing its runtime.
Portable operations