Comma README

The project's README from github.com/AFK-surf/Comma. As one markdown file: README.md.

Comma

The sessionless, relentless personal agent.

Comma: the open-source, sessionless, relentless personal agent for macOS and Web

Comma is an open-source personal agent built to be sessionless. Your work, memory, and context stay continuous across your computer, phone, cloud environment, applications, and connected devices.

It breaks down your goals into Tasks and keeps working through agentic loops until the job is done.

Built by AFK Inc., Comma is our attempt to create an open agentic system that keeps you away from software — and away from the keyboard.

You can use the hosted service at comma.surf, or run your own instance from this repository.

See Comma in action

No more applications.

Hand over your work and life. Comma gets it done.

https://github.com/user-attachments/assets/cefa2954-f29c-4434-9246-a82cb19a51fe

Personal context, aligned.

Save money. Shop smarter based on your preferences. Check out on your trusted device.

https://github.com/user-attachments/assets/486cde78-d927-4ff0-85de-00c46edc498e

Philosophy

What Comma does

Built with Elixir and Lean. Verified with Lean and TLA+.

Comma is built for long-running, fault-tolerant agent workloads. Its runtime is primarily built with Elixir/OTP, with Lean used for critical systems components. Important runtime properties are specified and machine-checked in Lean, and we use TLA+ to model-check core distributed protocols.

Each agent runs as its own process on the Erlang VM. When one part fails, it restarts, and the other agents keep running. Messages that Salix has accepted survive the restart. An interrupted action that changes something does not run again on its own.

The formal models check properties such as:

Formal verification does not prove model judgment or task success. It verifies something more fundamental: the runtime behaves according to the rules we designed, even when things fail.

For a sessionless agent, reliability is not an infrastructure detail. It is part of the product.

See Verification and the TLA+ models.

Self-host with Docker Compose

The root compose.yaml starts a complete single-node instance. It builds the Web client, the Admin client, and the server from source. It also starts PostgreSQL, Redis, MinIO, ClickHouse, and Mailpit, a local email inbox. You do not need a Comma account or a private repository token.

Requirements

First start

  1. Copy the example configuration:

    cp .env.example .env
    
  2. Set COMMA_OWNER_EMAIL to your email address. This account gets Admin access.

  3. Set your model provider in .env, or skip this step and configure a private model in Settings after login.

  4. Build and start the stack:

    docker compose up -d --build
    
  5. Open http://localhost:8080 and request a login code with your email address.

  6. Read the code in the local inbox at http://localhost:8025.

The first start generates persistent secrets and initializes empty stores. By default, all public ports bind to loopback only.

Configuration

Variable Purpose
COMMA_OWNER_EMAIL First owner account and Admin access
COMMA_ALLOW_SIGNUP Public registration, off by default
COMMA_LLM_BASE_URL Model provider endpoint
COMMA_LLM_PROTOCOL Provider protocol, such as chat_completions
COMMA_LLM_MODEL Provider model ID
COMMA_LLM_API_KEY Provider credential
COMMA_LLM_CONTEXT_TOKENS Model context budget
COMMA_LLM_MAX_TOKENS Output token limit
COMMA_EXA_API_KEY Optional Exa key for web search and page reading
COMMA_SMTP_* Mail server for login codes
COMMA_PUBLIC_URL, COMMA_API_URL, COMMA_ADMIN_URL, COMMA_SALIX_URL Browser origins

Model calls use your provider account and can cause provider charges. A self-hosted instance does not need Stripe or Comma credits.

Interfaces

Interface Default address
Comma Web http://localhost:8080
Comma Admin http://localhost:8082
Comma Product API http://localhost:8081
Salix dashboard http://localhost:4000/dash
Local inbox http://localhost:8025

Public access

For a public instance, put Comma behind your HTTPS reverse proxy. Web, Admin, and the Product API must use different origins on one registrable domain, for example app.example.com, admin.example.com, and api.example.com. Set a real SMTP server. The local inbox is for loopback use only, because anyone who can read it can use its login codes.

Features that need external accounts

Agents, Tasks, object storage, search, and subscription-account storage run inside the stack. To let Comma run commands on your own computer, connect the computer from the device settings. Group cloud computers need a Cloudflare configuration. Meetings and Agent VMM hosts need runtimes that this repository does not include.

Upgrades and backups

Stop the stack before an upgrade. Back up all five named volumes together: config, postgres, objects, clickhouse, and redis. The config volume holds the encryption key and authentication secrets. Do not delete it or regenerate its secrets. docker compose down keeps your data. Do not add -v unless you want to delete the instance.

Read the self-hosting guide before public deployment, upgrades, or restores.

Repository layout

clients/        # Web and Electron clients and shared React packages
systems/        # Elixir umbrella for Salix, the Comma product, and Bridge For Teams
selfhost/       # Self-hosting configuration and storage images
docs/           # Engineering contracts
tla/            # TLA+ models of core distributed protocols

Development

Install the client dependencies once, then start the local backend and the Web client:

pnpm install
make dev

make dev uses a deterministic mock model, so you do not need a model key. Sign in as [email protected] and read the code in Mailpit at http://127.0.0.1:8025. Use make dev-electron for the Mac app. Run the tests from the repository root:

make test-clients
make test-systems
make test-policy

Start with these documents:

Security

Report a vulnerability to [email protected]. See the security page for details.

License and contributions

Comma's original code is licensed under AGPL-3.0-only. Third-party components keep their own licenses. If you serve a modified version, keep the /source.tar.gz download available.

Contributions require the AFK AI, Inc. CLA. See CONTRIBUTING.md.

Comma (AFK-surf/Comma)

Searching Database…

266 ·GitHub
这是什么?Comma 是一个开源、无会话的个人 AI 代理,把你的请求变成持久的 Task,并通过自主代理循环持续处理,直到任务完成,覆盖你的电脑、手机和云端。
这是我安装的应用,还是我自托管的服务?它是一个自托管服务(由 Web 和 Admin 客户端加服务器组成的 Docker Compose 技术栈),你也可以直接使用 comma.surf 上的托管产品;还有一个名为 Salix 的 Mac 伴侣应用,让它能读取并控制你自己电脑上的文件。
怎么让自己的实例跑起来?复制示例 .env 配置,设置 COMMA_OWNER_EMAIL 以获得管理员权限,把它指向一个模型服务商,然后运行“docker compose up”,构建并启动 Web 客户端、Admin 客户端、服务器、PostgreSQL、Redis、MinIO、ClickHouse 和 Mailpit。
启动之前需要装好什么?你需要带 Compose v2.24 或更高版本的 Docker Engine、为首次构建准备充足的磁盘空间(它会拉取 Lean、Elixir、Go 和 Node 工具链),以及一个模型服务商账号,因为默认技术栈不带任何模拟模型。
形式化验证意味着任务总能成功吗?不能——Lean 和 TLA+ 证明只保证运行时在故障下行为正确,例如不丢失已接受的工作、不重复执行修改性操作;它们并不能证明代理的判断或任务结果真的正确。
我的敏感数据实际存放在哪里?长时间运行的工作发生在 Comma 自己的环境里,但身份、会话、支付和私人数据被设计为保留在你自己的设备上,必要时 Comma 会把 Task 交回你的电脑或手机。
如果我修改后再分发会怎样?Comma 的原始代码采用 AGPL-3.0-only,如果你把修改后的版本作为公共服务运行,就必须保留一个包含你修改内容的 /source.tar.gz 下载,供用户获取。
我还能在 Comma 之外继续用 Claude Code 或 Codex 吗?可以——Codex、Claude Code、Pi 和 Kimi 可以作为应用被调用,或注册为 Worker 和子代理,所以 Comma 是在编排你现有的代理工具,而不是取代它们。
Salix 是什么?Salix 是把你的电脑连接到 Comma 的 Mac 伴侣应用;它允许 Comma 读取你的文件,而一旦你启用“允许操作”,它还能修改文件、执行命令并记录调用。
Loops 是什么?Loop 是你的代理编写的一个小程序,用来监视收件箱、仓库或信息流,只在真正需要关注时才唤醒代理,因此安静的监视不会消耗任何模型 token。
为什么用 Elixir 加 Lean 验证来构建运行时,而不是典型的代理技术栈?Elixir/OTP 在 Erlang 虚拟机上把每个代理作为独立、可重启的进程运行,而 Lean 和 TLA+ 则形式化验证核心分布式协议绝不默默丢失工作或重复执行副作用——可靠性被当作核心产品属性,而不是事后才考虑的东西。
Creator
AFK-surf
Size
41.1 MB
Stars
266
Updated
CommitOct 02
Age
17d
Commits · 90 Days