Self-hosted · Claude Code and Codex
From ticket to merged code, with agents.
Run a software delivery board on your machine. Claude Code and Codex work in separate Git worktrees, your repository runs its own checks, and one Inbox keeps decisions that need you in view. Factory opens GitHub pull requests and waits for your approval before merging by default.
# Local mode · signed-in CLI
sh scripts/start.sh --local
# Server mode · Docker Compose
sh scripts/compose.sh
Workflow
How tickets move through the board
File a ticket on the board or bring work in from GitHub, Linear, Jira or Slack. Factory uses branch, pull request and merge status to place tickets. You can also set a ticket’s column yourself.
- Spec
- Write the requirements and name a check for each one.
- Build
- An agent implements the ticket in a dedicated worktree.
- Review
- Run the repository checks and review the change before merge.
- Merged
- The work has reached the default branch.
- Released
- Publishing a release archives the tickets it names.
The Inbox
Handle decisions in one place
Answer agent questions, approve permissions and screenshots, review proposed memory, and see which pull requests are failing or ready to merge.
- Permissions reach the running agent
- When a permission request needs your decision, the hook waits for Allow or Deny and sends the answer back to the agent.
- Answers stay with the ticket
- An agent can ask a focused question with choices and a recommendation. Your answer is available to the next run.
- Reply from your phone
- Set up ntfy or a webhook to receive Inbox notifications with links for answering requests.
{
"method": "tools/call",
"params": {
"name": "ask_question",
"arguments": {
"question": "Remove the old endpoint now?",
"choices": [
{"text": "Keep it a release", "recommended": true,
"reason": "Two clients call it"},
{"text": "Remove it"}
]
}
}
}
Examples
MCP tools, CLI commands and configuration
Agents use MCP to read and update tickets. You can manage the board from the browser or the code-factory command line.
{
"method": "tools/call",
"params": {
"name": "write_document",
"arguments": {
"name": "spec",
"base_version": 2,
"content": "# Export\n\n## Clauses\n\n- EX-1: one row per merged ticket\n"
}
}
}
Board and analytics
See the work and what it took to ship
Ticket board
See what is blocked and what each ticket has cost. Use saved views, bulk changes and undo to manage the queue.
Agent sessions
Inspect each captured run’s timeline, token usage and cost.
Shared memory
Approve rules, decisions and lessons for agents to load in future runs.
Flow and Factory
Track first-pass yield, intervention, and whether changes held after merge. Record active owner time to include it alongside priced runs in merged pull request costs.
Screen approvals
Review light and dark captures for UI tickets from the Inbox.
Releases
Draft release notes from merged tickets, edit them, and archive those tickets on publication.
Verification
Set the rules for checks, repairs and merges
Configure your repository in .code-factory/config.toml. Enable the review roles and verification steps your project needs.
- Prove acceptance tests before Build
- With a pre-Build proof configured, Factory verifies that named tests fail for the expected reasons, seals their files, and checks that seal again before accepting a passing verdict for merge.
- Run fast and full checks
- A passing fast check queues the required full check for the same commit. This repository can also run optional Semgrep and mutation scans that report warnings.
- Limit automatic repairs
- A confirmed CI failure or merge conflict can queue a repair. The default is three automatic repair rounds per ticket. At the cap, the queue shows why the ticket is held so you can take over.
- Keep approval for higher-risk changes
- Changes that touch sensitive paths or exceed the configured size limit require the owner to merge.
[checks]
command = "sh scripts/gate.sh --force --secrets"
fast = "sh scripts/gate.sh --fast --force --secrets"
timeout = 1200 # seconds a checks run may take
[agents]
sensitive_paths = ["alembic/**", ".github/**"]
large_change = 400
fix_rounds = 3 # automatic CI or conflict repairs
review_rounds = 3 # separate cap for review returns
Start
Run it from a source checkout
Factory is in development and serves one owner over loopback. Choose Local mode to use your signed-in coding CLI or Server mode to run the app in Docker.
- Version
- 0.1.0
- Python
- 3.14
- Database
- PostgreSQL
- Web app
- Vue 3 and shadcn-vue
- Tests
- 8,200+ in pytest
- Default address
- 127.0.0.1:4000
- Local mode
- Use your installed Claude Code or Codex CLI. PostgreSQL runs in Docker.
- sh scripts/start.sh --local
- Server mode
- Run the app and PostgreSQL together with Docker Compose.
- sh scripts/compose.sh