FormicOS is an AI agent orchestration system. It manages background work across multiple AI agents (colonies), keeps institutional memory that improves over time, and learns from outcomes to suggest better approaches. Think of it as a persistent team of AI specialists that remembers what worked and what didn't.
-
Start FormicOS:
docker compose up
-
Generate MCP config for your project:
python -m formicos init-mcp
This creates
.mcp.json(project-scoped MCP config) and.formicos/DEVELOPER_QUICKSTART.mdwith usage reference. -
Restart Claude Code so it picks up the new MCP server.
-
Try it: Ask Claude Code: "What's the status of my workspace?" — it will use the
morning-statusprompt to give you a briefing.
Use the morning-status prompt to get a briefing on workspace activity,
completed colonies, knowledge changes, and pending actions.
Use knowledge-for-context to search what FormicOS has learned about
your codebase — conventions, bug patterns, architectural decisions.
Use delegate-task to plan and spawn a colony of AI agents to handle it,
or handoff-to-formicos to transfer your current work context to a
background colony.
Use log-finding to record it in institutional memory so future colonies
(and future you) benefit from it.
Use review-overnight-work to see what FormicOS did autonomously — what
it dispatched, what it learned, and what needs your review.
| Prompt | Purpose |
|---|---|
knowledge-query |
Search institutional memory for relevant context |
plan-task |
Plan a colony task with team composition |
morning-status |
Briefing on workspace activity and pending items |
delegate-task |
Plan and spawn a background colony for a task |
review-overnight-work |
Review autonomous actions and outcomes |
knowledge-for-context |
Retrieve relevant knowledge for current work |
economic-status |
Economic overview: billing, receipts, revenue share |
review-task-receipt |
Review the economic receipt for a completed task |
list_workspaces— list all workspacesget_status— workspace status and active coloniesspawn_colony— start a colony with a taskkill_colony— stop a running colonysuggest_team— get recommended team composition for a task
log_finding— record a finding in institutional memorysearch_knowledge— search institutional memory using full retrieval pipelinequery_service— query knowledge entries
approve/deny— handle pending approval requestsget_maintenance_policy/set_maintenance_policy— autonomy controls
addon_status— check addon health and call countstoggle_addon— enable/disable an addontrigger_addon— manually fire an addon trigger
handoff_to_formicos— transfer work context to a background colony
get_task_receipt— get a deterministic receipt for completed A2A work
| URI | Returns |
|---|---|
formicos://knowledge/{workspace} |
Knowledge entries for a workspace |
formicos://knowledge/{entry_id} |
Single knowledge entry detail |
formicos://threads/{workspace_id} |
Thread list for a workspace |
formicos://threads/{workspace_id}/{thread_id} |
Thread detail with colonies |
formicos://colonies/{colony_id} |
Colony detail with rounds and agents |
formicos://briefing/{workspace_id} |
Proactive intelligence briefing |
formicos://plan |
Project plan milestones (global) |
formicos://procedures/{workspace_id} |
Operating procedures |
formicos://journal/{workspace_id} |
Queen journal entries |
formicos://billing |
Current-period billing status |
formicos://receipt/{task_id} |
Deterministic receipt for a completed task |
FormicOS reads and writes files in your project's .formicos/ directory:
.formicos/project_plan.md— project milestones (Queen-managed).formicos/project_context.md— project instructions for colonies.formicos/operations/*/operating_procedures.md— autonomy rules per workspace.formicos/operations/*/queen_journal.md— what FormicOS did and why
The Queen tab in the FormicOS UI provides direct visibility and control over the Queen agent's behavior:
- Display board — structured observations with attention/urgent items
- Active work — continuation candidates, current goals, plan state
- Operating procedures — autonomy level, workspace rules
- Behavioral overrides — disable specific tools, inject custom rules, override team composition and round/budget heuristics
- Health & budget — trust score, tool usage counters, context budget
Behavioral overrides are workspace-scoped and stored as config fields. They nudge the Queen's behavior without hard enforcement — the Queen sees them as guidance in its context window.
FormicOS tracks the economics of agent work through A2A task contracts and receipts:
- Task contracts — when submitting work via A2A, include an optional
contractdescribing acceptance criteria and sponsorship - Task receipts — completed tasks produce deterministic receipts with cost, token totals, quality scores, and transcript hashes
- Revenue share — receipts include eligibility status based on sponsor
verification in
.formicos/sponsors.json
From Claude Code, use get_task_receipt to inspect receipts for completed
work. See docs/A2A_ECONOMICS.md for the full protocol specification.
FormicOS supports multiple MCP clients simultaneously. Both Claude Code and Claude Desktop can connect to the same running FormicOS server at the same time -- they share the same workspaces, knowledge, and Queen.
python -m formicos init-mcp
# Creates .mcp.json and .formicos/DEVELOPER_QUICKSTART.md
# Restart Claude Code to connectClaude Desktop connects to local MCP servers via claude_desktop_config.json.
FormicOS is an HTTP MCP server, so it needs the mcp-remote bridge (a
lightweight npm package that translates between Claude Desktop's stdio
transport and FormicOS's HTTP transport).
Prerequisites: Node.js (for npx).
-
Open Claude Desktop > Settings > Developer > Edit Config (or manually edit the config file):
- Windows:
%APPDATA%\Claude\claude_desktop_config.json - macOS:
~/Library/Application Support/Claude/claude_desktop_config.json
- Windows:
-
Add FormicOS:
{
"mcpServers": {
"formicOSa": {
"command": "npx",
"args": ["mcp-remote", "http://localhost:8080/mcp"]
}
}
}Or generate the snippet from the CLI:
python -m formicos init-mcp --desktop-
Restart Claude Desktop. Look for the hammer icon in the chat input -- that confirms the MCP tools are loaded.
-
Test: Ask Claude to call
get_statusor try themorning-statusprompt.
Both Claude Code and Claude Desktop connect to the same FormicOS instance and share the same workspaces, knowledge, and Queen.
Use log_finding from Claude Desktop to record discoveries in institutional
memory. This is the primary ingestion path for developer-sourced knowledge.
Tool signature:
log_finding(title, content, domains, workspace_id)
title-- short descriptive name for the findingcontent-- the full text of the findingdomains-- comma-separated domain tags (e.g.,"auth,security")workspace_id-- target workspace; defaults to the first workspace if omitted. Specify explicitly for bulk operations to avoid ambiguity.
Entries are created at candidate status with decay_class="stable" and
balanced priors (Beta(5, 5)). They require operator confirmation via the
Operations inbox to become verified. Until confirmed, entries participate
in retrieval but with a status penalty in the scoring formula.
Use search_knowledge to retrieve entries after population. It uses the
full 7-signal retrieval pipeline (semantic, Thompson sampling, freshness,
status, co-occurrence, graph proximity, thread bonus).
FormicOS is event-sourced with a 4-layer architecture: Core (types, events), Engine (pure colony execution), Adapters (LLM, vector DB, search), and Surface (HTTP/WS/MCP wiring). Agents coordinate through shared environmental signals (stigmergic coordination) rather than direct messaging.
Knowledge entries that prove useful gain confidence over time; unreliable ones decay naturally. Multiple FormicOS instances can federate knowledge with conflict-free merge semantics.
For internals, see docs/ — architectural decision records, specs, and
subsystem documentation.