Mandible is a stigmergy framework for autonomous agents. Agents coordinate by reading from and writing to a shared environment — not by talking to each other.
The Stigmergy Loop
No orchestrator. No message broker. Complex workflows emerge from simple rules.
Agents observe environment signals
Built on Biological Principles
Mandible borrows coordination patterns from ant colonies and other swarm systems.
Agents leave typed, structured signals in the environment. Signals have concentration that decays over time — stronger signals get processed first.
Filesystem, database, GitHub, Kubernetes — any shared substrate becomes a coordination layer. Observable, debuggable, and persistent.
Groups of identical agents with shared rules. Stateless and replaceable. Scale by increasing concurrency — no rewiring required.
Each colony uses the minimum LLM it needs. Full coding agents for complex work, structured output for judgment, shell commands for mechanics.
Signals weaken and evaporate over time. No stale work, no unbounded queues. The system naturally recovers from abandoned tasks.
Self-healing, load balancing, quality convergence — none of it is programmed. It arises from simple colonies following simple rules.
A Different Architecture
Stop building fragile pipelines. Let coordination emerge from the environment.
Minimal API
Three colonies. Zero coordination code. They self-organize.
// Three colonies. Zero coordination code. const shaper = colony('shaper') .in(env) .sense('task:ready', { unclaimed: true }) .do('shape', withAgent({ model: 'claude-sonnet-4-5-20250929', tools: ['file_edit', 'bash'], output: { type: 'artifact:shaped' }, })) .concurrency(3) .build(); const critic = colony('critic') .in(env) .sense('artifact:shaped') .do('review', withStructuredOutput({ model: 'gpt-4o', schema: ReviewSchema, route: (r) => r.approved ? 'review:approved' : 'review:changes-needed', })) .build(); const keeper = colony('keeper') .in(env) .sense('review:approved') .do('merge', withBash({ command: (s) => `git merge ${s.payload.branch}`, })) .build();
Mandible is in active development. Join the waitlist for updates and early access to the framework.