Archon README

项目的 README,来自 github.com/coleam00/Archon。合并为一个 markdown 文件:README.md。

Archon

Archon

The simplest way to build the software that builds your software.
YAML workflows that can do anything.

coleam00%2FArchon | Trendshift

License: MIT CI Docs


Archon is a factory builder. You describe how work should get done as YAML workflows, and Archon runs them with AI agents, scripts and your decisions in the places that need them. Software is the first factory: the bundled SDLC pack takes an issue to a merged pull request. The same engine runs any process you can describe.

Take yourself out of the loop and sit on top of it. Runs do the work, queues keep it moving, and a run comes to you only when it needs a decision you own.

Why Archon

Ask a coding agent to fix a bug and the result depends on the run. It may skip the plan, forget the tests or ignore your PR template. You end up supervising every step.

Archon turns your process into a workflow you own. The workflow fixes the steps, the checks and the gates. The agent supplies the judgment inside each step. That gives you:

What it looks like

A workflow is a graph of nodes. Agents judge, code computes, and you decide where it matters:

# .archon/workflows/build-feature.yaml
name: build-feature
description: Plan, implement until the tests pass, ask for approval, open the PR.
nodes:
  - id: plan
    prompt: "Read the request and the code. Write an implementation plan."

  - id: implement
    depends_on: [plan]
    loop:
      prompt: "Implement the next step of the plan."
      until_bash: "bun run test"          # your test command; code decides when it is done
      max_iterations: 10
      fresh_context: true

  - id: approve
    depends_on: [implement]
    wait:                                 # the run pauses and asks you
      attention: "Review the change. Approve, or reject to stop."
      form: approval

  - id: stop
    depends_on: [approve]
    when: "$approve.output.decision == 'reject'"
    cancel: "Rejected at review."

  - id: pr
    depends_on: [approve]
    when: "$approve.output.decision == 'approve'"
    prompt: "Push the branch and open a pull request."
flowchart LR
  plan["plan<br/>(agent)"] --> implement["implement<br/>(agent, loops until the tests pass)"]
  implement --> approve{"approve<br/>(waits for you)"}
  approve -- reject --> stop["stop"]
  approve -- approve --> pr["pr<br/>(agent)"]

Save it in your repository's .archon/workflows/, swap bun run test for your own test command, and run it:

archon workflow run build-feature "Add dark mode to the settings page"

Repository runs get their own git worktree by default, so several can work on one repository at once.

A software factory: issue in, merged PR out

The bundled sdlc pack is a working factory for a repository:

  1. You open an issue. archon-intake checks it against the current code and decides what it needs: a plan, an investigation, straight to delivery, or a maintainer's look.
  2. The build queue picks it up. archon-build-queue takes a ready issue, writes the brief and runs archon-ship: plan, implement, review through specialist lenses, fix the findings, wait for CI. It stops at a pull request whose review says Ready, asking once for any check no round can run, or at one a maintainer's ready answer hands on; the merge gate checks either the same way.
  3. The merge queue lands it. archon-merge-queue merges the clear ready pull requests that merge cleanly, through a gate that checks the review verdict and CI at the head commit and that the base branch is not red. The queue judges open review threads itself and sends a pull request that conflicts back to the build queue.
  4. You answer what's unclear. A scope question, a schema change or a stuck round becomes one attention item with a recommendation. Your answer is written into the issue as the new scope.
  5. Nothing found along the way is lost. archon-discoveries reads what runs noticed outside their task and files it, tracks it on an existing issue, or drops it.

Archon builds Archon: of the 524 pull requests merged into this repository between 1 and 19 October 2026, Archon runs built 363.

You start the queues by hand or bind them to a schedule or issue events with a trigger. The pack binds nothing by default. The pack reaches GitHub through the forge plugin (archon plugin add coleam00/Archon/plugins/forge-github); see the forge path. The SDLC factory introduces it and links its setup guide, and SDLC pack workflows describes every workflow in it.

Build any factory

Workflows are not tied to code. A node can be an agent prompt, a bash command, a script, a loop, a wait for a person or a child workflow, so any process with steps, checks and decisions fits: content production, research, operations, support. Write it as YAML, keep its commands and scripts beside it, and share it as a pack.

A reliable core, extensible at the seams

The core stays small: the workflow engine, isolation, durable state, the attention queue and an audit trail. Everything that talks to the outside world plugs in through a published contract, and you can build your own plugin for any of them:

Plugin kind What it adds Maintained here
Workflow pack Workflows, commands and scripts sdlc
Provider An agent runtime Claude Code, Codex, Pi
Forge A code host GitHub
Chat A conversation surface Slack

GitHub is the registry: publish in your own repository and install with archon plugin add owner/repo. See Publish a plugin and the plugin index.

Quickstart

  1. Install Claude Code and sign in, or install Codex.

  2. Install Archon. The installer asks which providers to add:

    curl -fsSL https://archon.diy/install | bash        # macOS / Linux
    irm https://archon.diy/install.ps1 | iex             # Windows (PowerShell)
    brew install coleam00/archon/archon                 # Homebrew, then: archon setup
    
  3. Run a workflow in any git repository:

    cd your-project
    archon workflow list
    archon workflow run archon-investigate "Why does the login test fail?"
    
  4. Watch runs and answer their questions in the web console with archon serve, or from the terminal with archon workflow attention.

To let your coding agent drive Archon for you, run archon skill add in your project, then ask it to "use archon to fix issue #42".

Other installs (from source, Docker, servers), provider setup and the Claude Code binary path are in the installation guide. The quick start shows how to write a brief a run can deliver against.

Connect a platform

The CLI and web console work out of the box. Connect a chat platform or forge to start and follow runs from there:

Platform Guide
Slack Slack guide
Telegram Telegram guide
GitHub webhooks GitHub guide
Discord Discord guide

Documentation

Full documentation is at archon.diy/docs.

Topic Description
Quickstart Install and first run
Workflow language Write your own YAML workflows
Operate runs Watch runs, answer the ones that need you, read results
CLI reference Every command and flag
Configuration Config options, model tiers and aliases, env vars
AI assistants Claude Code, Codex and Pi setup
Deployment Docker, VPS and production setup
Architecture Packages and boundaries
Troubleshooting Common issues and fixes

For AI tools: point your LLM at /llms.txt for an index of the docs, /llms-full.txt for all of them in one file, or /llms-small.txt for a condensed version.

Previous version

Looking for the original Python-based Archon (task management and RAG)? It is preserved on the archive/v1-task-management-rag branch.

Telemetry

Archon sends a few anonymous events so maintainers can see which workflows get real usage, on what platforms, and whether runs succeed, and prioritize accordingly. No PII, ever. Events: archon_started (at most once a day each for the CLI and the server, with the store it uses: files, sqlite or postgresql; archon serve reports as the server, and a detached run's worker process is counted by the command that started it), archon_active (daily heartbeat while a server is running, so long-running installs stay counted), chat_turn_handled (each direct AI chat turn: platform, provider, model, duration, and usage totals; never message content), workflow_invoked (each workflow start, and again for each resumed segment), workflow_completed / workflow_failed / workflow_cancelled (sent once when a run's final status is saved, whichever path ended it), workflow_approval_resolved (each human approve/reject decision: the binary resolution only, never comments or reasons), and codebase_registered (a pure count when a project is registered; no name, path, or URL).

What's collected (categorical only):

Workflow runs and direct-chat turns both report optional cache_read_tokens, cache_write_tokens, and true-only cache_partial. An unreported axis is absent; a reported zero stays zero. When cache_partial is true, cache totals are floors because some contributing results did not report cache usage. When telemetry is enabled and stderr is a terminal, the updated first-run notice appears once again for existing installs to disclose direct-chat cache capture. Headless installs show no notice; see telemetry settings for capture details and opt-outs.

What's not collected: your code, prompts, messages, custom workflow names, workflow descriptions, git remotes, file paths, usernames, tokens, AI output, error message text, your IP address, your geographic location. None of it.

Opt out: set any of these in your environment:

ARCHON_TELEMETRY_DISABLED=1
DO_NOT_TRACK=1        # de facto standard honored by Astro, Bun, Prisma, Nuxt, etc.
POSTHOG_API_KEY=off   # off | 0 | false | disabled | "" all disable

CI environments (CI=true) are auto-disabled: forks running fixtures in GitHub Actions, CircleCI, etc. do not send events.

Check the current state: run archon telemetry status to see whether telemetry is enabled, why (if not), the install UUID, and the active host. Run archon telemetry reset to rotate the install UUID. archon doctor also surfaces the current state in its check list.

Shutdown gives pending telemetry a 75 ms flush window, then cancels outstanding requests. Slow or unreachable ingestion can lose events; it does not hold up command exit. Far from the ingest host (for example, about 250 ms TLS handshake from Europe to the default US host), events from short commands like --help are usually dropped; longer commands flush in the background while they run.

Self-host PostHog or use a different project by setting POSTHOG_API_KEY and POSTHOG_HOST.

Contributing

Contributions welcome. See the open issues for things to work on, and read CONTRIBUTING.md before opening a pull request.

Star history

Star History Chart

License

MIT

Archon (coleam00/Archon)

正在搜索数据库…

这是什么?Archon 是一个面向 AI 编程智能体的开源工作流引擎:你把开发流程——规划、实现、验证、审查、创建 PR——定义成 YAML 工作流,然后可以在所有项目里稳定可靠地运行它们。
这和直接提示 Claude Code 有什么区别?单靠提示词,智能体每次运行的表现都不一样——可能跳过规划,或者忘了跑测试。Archon 负责掌控结构:阶段、验证关卡和产出物都在 YAML 里固定下来,AI 只负责在每一步发挥它的智能。
我怎么把它跑起来?有两条路:完整安装会克隆仓库并带你走一遍引导式向导——只需告诉你的编程智能体“Set up Archon”;而快速安装只要 30 秒左右就能装好一个独立的 CLI 可执行文件,前提是你已经在用 Claude Code。
必须装 Claude Code 吗,还是也能配合其他编程智能体用?它是围绕 Claude Code 打造的,文档里也介绍了 Codex 和 Pi。引导式安装需要 Bun、Claude Code 和 GitHub CLI;快速安装的可执行文件不带 Claude Code——通过 CLAUDEBINPATH 或 config.yaml 里的二进制路径把 Archon 指向你自己的 Claude Code 即可。
安装上有什么坑需要注意吗?有:在 x64 架构上,macOS/Linux 的快速安装要求 CPU 支持 AVX2,所以较老的 Intel/AMD 硬件以及屏蔽了 AVX2 的虚拟机只能从源码构建。ARM64 不受影响,Windows 则通过 PowerShell 脚本安装。
我是不是只能守着终端,还是能从聊天软件里操控它?CLI 和网页控制台开箱即用,你还可以选择接入 Telegram 或 Discord(各需 5 分钟),或者 Slack 和 GitHub webhook(15 分钟),从而远程启动和监控工作流。
它会上报遥测数据吗?它会发送少量匿名的 PostHog 事件——工作流结果、token 总量、所在平台。消息内容、提示词和代码绝不会发送;退出只需要一行环境变量,CI 环境则自动排除在外。
这就是以前做任务管理和 RAG 的那个 Archon 吗?不是——这是一个专注于工作流编排的 TypeScript 重写版。原先围绕任务管理和 RAG 构建的 Python 版本完整保留在 archive/v1-task-management-rag 分支上。
我能自己部署或在服务器上运行吗?可以——仓库自带 Docker 和 docker-compose 配置,文档也涵盖了 Docker、VPS 和生产环境部署。它支持 SQLite 或 PostgreSQL,Docker 镜像里还预装了 Claude Code。
网页控制台里能用到什么?运行 archon serve 后,你会得到一个支持实时流式输出和工具调用可视化的聊天界面,一个用于监控运行中工作流、历史记录可筛选的 Mission Control 页面,以及任意一次运行的分步执行视图。
作者
coleam00
大小
111.6 MB
星标
24K
时长
1年
提交 · 90 天