Getting Started with Archon: Define Your First AI Coding Workflow in 5 Minutes
Step-by-step tutorial to install and run Archon. From prerequisites and installation to defining your first YAML workflow with isolated worktrees and human approval gates.
Get Archon Running in 5 Minutes β Then Build Your First AI Coding Workflow
I spent a solid 30 minutes on my first Archon setup because I missed one prerequisite. Don't be me. Here's exactly what worked, what didn't, and how to go from zero to a running workflow that plans, codes, validates, and opens a PR β all automatically.
Archon is written in TypeScript and runs on Bun, not Node. That tripped me up first. Also, you need Claude Code installed separately if you're using the compiled binary. The Docker image ships with everything pre-bundled, which is my recommended path if you just want to try it.
π Want to deploy Archon yourself?
Docker Compose configs, system requirements, and installation guides β all on one page.
View Archon Tool Page βPrerequisites (Don't Skip This)
| What | Why | Time |
|---|---|---|
| Bun runtime | Archon runs on Bun, not Node.js | 30s |
| Claude Code | Required as the AI assistant backend | 30s |
| GitHub CLI | For PR creation and git operations | 30s |
| Git repo | Any project you want to run workflows on | β |
Install Bun
curl -fsSL https://bun.sh/install | bash
That's it. Add ~/.bun/bin to your PATH if the script doesn't do it automatically. Run bun --version to confirm.
Install Claude Code
curl -fsSL https://claude.ai/install.sh | bash
Install GitHub CLI
# macOS
brew install gh
# Linux
sudo apt install gh
# Then authenticate
gh auth login
Step 1: Clone and Install
git clone https://github.com/coleam00/Archon
cd Archon
bun install
What I learned the hard way: If bun install fails, check your Bun version. I was running an old 1.0.x that didn't support some lockfile features. bun upgrade fixed it instantly.
Once installed, start the guided setup:
claude
Then inside Claude Code, say: "Set up Archon"
The wizard walks through: authentication (GitHub, Claude), platform selection (CLI only or Web UI too), and copies the Archon skill to your target project. This takes about 2 minutes.
π‘ Tip: Point the setup at a test repo first β not your production codebase. Once you're comfortable, rerun the setup on your real project. The Archon skill lives in .archon/workflows/ and doesn't modify your source code.
Step 2: Define Your First Workflow
Create .archon/workflows/fix-bug.yaml in your project:
nodes:
- id: plan
prompt: "Explore the codebase and create a fix plan"
- id: implement
depends_on: [plan]
loop:
prompt: "Read the plan. Implement the fix. Run validation."
until: ALL_TASKS_COMPLETE
fresh_context: true
- id: validate
depends_on: [implement]
bash: "bun run test"
- id: pr
depends_on: [validate]
prompt: "Commit changes and create a pull request"
This is a minimal workflow: plan β implement (with loop until all tasks complete) β run tests β create PR. Each node is self-contained and the AI starts fresh at each step.
β οΈ What tripped me up: I forgot fresh_context: true on the loop node. Without it, the AI accumulates context across iterations and gets confused. Add this flag to every loop node unless you specifically want long-term context.
Step 3: Run It
cd /path/to/your/project
claude
Inside Claude Code:
Use archon to fix issue #42
Archon creates an isolated git worktree on a branch like archon/task-fix-issue-42, runs through your workflow nodes in order, and... you wait. Go make coffee. This takes 30-90 seconds depending on the complexity.
β If Archon says: "PR ready: https://github.com/you/project/pull/47" β you're done. The PR has the changes, tests passed, and the description follows your template.
β Common failures: Missing GitHub CLI auth (gh auth status to check), Claude Code not finding your binary (export CLAUDE_BIN_PATH), or Bun version mismatch (bun upgrade).
Going Further: Human Approval Gate
For sensitive changes, add an interactive: true node before the PR step:
- id: approve
depends_on: [validate]
loop:
prompt: "Present the diff for review. Address any feedback."
until: APPROVED
interactive: true
- id: pr
depends_on: [approve]
prompt: "Create the pull request"
Archon pauses at the approve node, shows you the diff, and waits for your input. Say "looks good" to continue or "change X" to iterate. This is my favorite feature β I never merge without reviewing, and now Archon doesn't either.
Quick Install Alternative (30 Seconds)
If you already have Claude Code set up and just want the CLI binary:
curl -fsSL https://archon.diy/install | bash
Or via Homebrew:
brew install coleam00/archon/archon
Then set your Claude binary path:
export CLAUDE_BIN_PATH="$HOME/.local/bin/claude"
π Pro tip: The Docker image (otakulabz/archon:server-latest) ships with Claude Code pre-installed. If you want the full Web UI + server setup without installing Bun locally, use Docker. The otakulabz/archon:agents-latest tag runs headless agents for background processing.
π Explore Archon on Run This Ai
Docker Compose configs, system requirements, installation guides, and more β all in one place.
View Archon Tool Page β