Raw capture โ€” raw/loomkin.md


url: https://github.com/pass-agent/loomkin date_fetched: 2026-07-05 backfilled: true


What if AI agents could form teams as fluidly as humans?

Spawn specialists in milliseconds. Share discoveries in real-time. Review each other's work. Debate approaches and vote on decisions. Heal themselves when things break. Verify their own output before moving on. Remember everything across sessions โ€” not just what happened, but why.

Watch it all unfold from a live mission control UI. Built on Erlang/OTP.

loomkin.dev | 328 source files, ~77K LOC, 2,700+ tests

Traditional AI Assistants Loomkin
Default experience Single agent, teams opt-in Teams-first: every session is a team of 1+ that auto-scales
Memory Conversation history, maybe embeddings Persistent decision graph โ€” goals, tradeoffs, rejected approaches survive across sessions
Context Summarized away as it grows (lossy) Context Mesh: offloaded to Keeper processes with staleness tracking, zero loss, 228K+ tokens preserved
Agent spawn 20-30 seconds <500ms ( GenServer.start_link)
Inter-agent messaging JSON files on disk, polled In-memory PubSub, microsecond latency, cross-team discovery
Concurrent file edits Overwrite risk Region-level locking with intent broadcasting
Task decomposition Lead plans upfront, frozen Living plans: agents create tasks, negotiate assignments, propose revisions, re-plan as they learn
Peer review None Native protocol โ€” review gates, pair programming, structured handoffs
Agent concurrency 3-5 practical limit 100+ lightweight processes per node
Model mixing Single model for all agents Per-agent selection โ€” cheap grunts + expensive judges (18x cost savings)
Error recovery Crash = lost session Self-healing: error classification, ephemeral diagnostician + fixer agents, OTP supervision
Verification Manual testing Autonomous verify loops โ€” write, test, diagnose, fix, re-test. Upstream verifiers gate dependents
Deliberation None Conversation agents โ€” spawn brainstorms, design reviews, red teams on demand
Web UI Terminal only, or separate web app LiveView mission control โ€” agent cards, comms feed, decision graph, context library, permissions. Zero JS
Decision persistence None PostgreSQL DAG with 7 node types, typed edges, confidence scores, pulse reports
Session persistence None Workspaces persist teams and tasks across tab closes and reconnects
Community None Social platform โ€” publish skills, share kin agents, install from community or git repos
Self-improvement None Reflection agent reviews team patterns and proposes improvements via kindred bundles
MCP Client or server Both โ€” expose tools to editors AND consume external tools
Hot reload Restart required Update tools, providers, prompts while agents are running

No Docker?If you prefer system-installed Postgres, setDB_PORT=5432(or your custom port) in your environment and skip themake db.upstep.

Dev container?A shared SSH-accessible container with Tailscale, mise tooling, and Postgres is available for team development. See the devcontainer config in the repo.

git clone https://github.com/bleuropa/loomkin.git
cd loomkin
# Install deps, start Postgres container, set up the database
make setup
# Start the web UI
make dev
# โ†’ http://localhost:4200

Set your LLM provider API key:

export ANTHROPIC_API_KEY="sk-ant-..."
# or
export OPENAI_API_KEY="sk-..."

Optionally create a .loomkin.toml in your project root:

[model]
default = "anthropic:claude-sonnet-4-6"
weak = "anthropic:claude-haiku-4-5"
[permissions]
auto_approve = ["file_read", "file_search", "content_search", "directory_list"]
# Web UI โ€” streaming chat, file tree, decision graph, team dashboard
mix phx.server
# โ†’ http://localhost:4200
โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                      INTERFACES                          โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”   โ”‚
โ”‚  โ”‚ LiveView Web  โ”‚  โ”‚   MCP Svr    โ”‚  โ”‚ Channel Adapt โ”‚   โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜   โ”‚
โ”‚         โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜           โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Workspace Layer          โ”‚                              โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ดโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”‚
โ”‚  โ”‚ Workspace (persistent team + task state)            โ”‚  โ”‚
โ”‚  โ”‚  โ”œโ”€โ”€ Session GenServer (per-connection UI overlay)  โ”‚  โ”‚
โ”‚  โ”‚  โ”œโ”€โ”€ Agent Teams (DynamicSupervisor + GenServers)   โ”‚  โ”‚
โ”‚  โ”‚  โ”œโ”€โ”€ Context Window (token-budgeted history)       โ”‚  โ”‚
โ”‚  โ”‚  โ”œโ”€โ”€ Decision Graph (persistent reasoning memory)  โ”‚  โ”‚
โ”‚  โ”‚  โ””โ”€โ”€ Permission Manager (trust policies + audit)   โ”‚  โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Agent Runtime                                           โ”‚
โ”‚  Conversation Agents โ”‚ Self-Healing โ”‚ Verification Loop  โ”‚
โ”‚  Speculative Execution โ”‚ Task Negotiation โ”‚ Orchestrator โ”‚
โ”‚  Adaptive Spawning โ”‚ Partial Results โ”‚ Reflection Agent โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Tool Layer (58 Actions)                                 โ”‚
โ”‚  File I/O โ”‚ Search โ”‚ Shell โ”‚ Git โ”‚ LSP โ”‚ Decisions โ”‚     โ”‚
โ”‚  Team Mgmt โ”‚ Peer Comms โ”‚ Context โ”‚ Skills โ”‚ Verify โ”‚    โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Social Layer                                            โ”‚
โ”‚  Auth โ”‚ Organizations โ”‚ Snippets โ”‚ Community โ”‚ Feed      โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Intelligence                                            โ”‚
โ”‚  Decision Graph โ”‚ Repo Intel โ”‚ Keeper Intelligence โ”‚     โ”‚
โ”‚  Failure Memory โ”‚ Self-Introspection โ”‚ Kindred Bundles   โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Protocols: MCP Server โ”‚ MCP Client โ”‚ LSP Client         โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  LLM Layer: req_llm (16 providers, 665+ models, Ollama) โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚  Signal Bus โ”‚ Telemetry โ”‚ Observability                  โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Create a LOOMKIN.md in your project root to give Loomkin persistent instructions:

# Project Instructions
This is a Phoenix LiveView app using Ecto with PostgreSQL.
## Rules
- Always run `mix format` after editing .ex files
- Run `mix test` before committing
- Use `binary_id` for all primary keys
## Allowed Operations
- Shell: `mix *`, `git *`, `elixir *`
- File Write: `lib/**`, `test/**`, `priv/repo/migrations/**`
- File Write Denied: `config/runtime.exs`, `.env*`

Loomkin is in active development. The core agent runtime, team orchestration, and web UI are stable and feature-rich.

Loomkin wouldn't exist without these projects:

Loomkin is in active development. Contributions welcome. 2,700+ tests across 218 files. ~77K LOC application code. ~40K LOC tests.

# Full setup (Docker, deps, database)
make setup
# Start the dev server
make dev
# Run tests
make test
# Format code
make format
# Database lifecycle
make db.up      # start Postgres container
make db.down    # stop Postgres container
make db.reset   # drop, create, migrate, seed

MIT