Skip to content

Stigmergy: what it is and what ants teach AI agents

Ants coordinate with no boss or messages. In 2025 the idea came back: Cursor measured 70,000 merge conflicts among poorly coordinated AI agents.

Alessandro ColaceUpdated on 10 October 20269 min read
White and violet neon illustration: on the left AI agents densely cross-linked by direct arrows, on the right agents connected to a shared node with ants along the paths

Key takeaways

  • Stigmergy is indirect coordination: agents adjust to traces left in a shared environment.
  • It holds for ants, Wikipedia and AI agents: Heylighen formalized it as a universal mechanism.
  • Cursor measured 70,000 merge conflicts among poorly coordinated agents, fewer than 1,000 with explicit coordination.
  • An ontology-governed knowledge graph is probably the best stigmergic environment a company can build.

A termite colony builds pillars and arches a meter tall with no architect and not a single message exchanged between two workers. Each termite drops a bit of mud, almost at random. But one deposit invites another at the same spot: the structure itself becomes the instruction for the next step. French biologist Pierre-Paul Grassé described this in 1959 and called it stigmergy: coordination not through direct communication, but through the traces left in a shared environment.

In 2025 the word came back in fashion, for a different reason: describing how AI agents coordinate when they don't talk to each other, in what's often now called an agent swarm. It's a useful idea, with a solid part and a part that promises more than the research supports. The solid part is ant colony optimization, blackboard architectures and SRMT; the overpromising part is a paper that makes it the basis of a deterministic AGI.

What is stigmergy, in plain words?

No termite holds the nest's blueprint in its head. Each one reacts only to what it finds: if there's already a small mud pile, it adds to it; if there's nothing, it deposits at random. Theraulaz and Bonabeau formalized the concept in 1999: stigmergy is coordination mediated by the environment, not by communication. The environment itself accumulates memory and becomes the synchronization channel.

This is where Marco Dorigo's ant colony optimization comes from: algorithms that simulate digital ants depositing virtual "pheromones" on a graph to find the shortest path, still used today for network routing and logistics (Dorigo & Stützle, Ant Colony Optimization, MIT Press, 2004). It's one of the longest-lived bio-inspired algorithms in computing, and it works precisely because it gives up a central coordinator.

The work that turned stigmergy into a rigorous concept is cybernetician Francis Heylighen's: "Stigmergy as a Universal Coordination Mechanism I: Definition and Components" and its follow-up "II: Varieties and Evolution" (Cognitive Systems Research, 2016) are today's standard citation on the topic. Heylighen's claim: an action leaves a trace in the environment; perceiving that trace stimulates the next action; nobody needs to see the whole picture, or even know who left the trace before them.

It's the same principle behind Wikipedia, where each of millions of contributors fixes what looks incomplete or wrong, and the entry improves one edit at a time, with no central editorial board assigning articles (Heylighen applies the same scheme, with similar examples, in a research thread on "human-human stigmergy" started by Van Dyke Parunak in 2005).

On the left, several people edit the same shared document without coordinating with each other; on the right, ants converge on a mound following the same pheromone trails, the same stigmergy principle applied to humans and insects
Human stigmergy (a shared document) and biological stigmergy (a pheromone trail): same principle, two different media.

Cursor: stigmergy tested on a Git repository

Cursor had to solve this at real scale. In a July 2026 technical post, the company describes what happens when dozens of AI coding agents work in parallel on the same Git repository, a shared environment by definition. In the first version of their system, agents constantly collided: over 70,000 merge conflicts in a single session, with the most contested file touched 7,771 times.

In the revised version, with more explicit coordination between a "planner" agent and "worker" agents, the same conflicts dropped below a thousand. The repository is the stigmergic environment: when agents don't carefully read the traces others left before writing their own, the cost shows up as merge conflicts.

The paper that promises AGI (take it with a pinch of salt)

In July 2025, an "online-first" IntechOpen article by Nishanth Mudkey redefined stigmergy as the basis of an architecture called "Information Retrieval Network" (IRN): a shared memory in which agents would converge toward a "strategic resonance" described with Nash equilibria and even a wave formalism borrowed from quantum physics. The claim is that this leads to a "deterministic" AGI, superior to "probabilistic" language models as they exist today.

IntechOpen "online-first" isn't a peer-reviewed journal in the traditional sense, and this particular piece doesn't cite established multi-agent-systems literature to back its boldest claims. Its evidence is a self-run simulation of 30-200 agents.

The "deterministic AGI vs. probabilistic LLMs" contrast is a strong assertion, not a third-party-verified result. I read it as a stimulating intellectual provocation, and I wouldn't build a production architecture on it. For a more balanced view of the AGI debate, start with sources like Science, "Debates on the nature of artificial general intelligence" (2024).

Which stigmergy applications actually work, today?

While the AGI debate stays speculative, a much more concrete research thread is already demonstrating something stigmergy-like in real multi-agent systems. The strongest case is SRMT (Shared Recurrent Memory Transformer), posted to arXiv in January 2025 by Sagirova, Kuratov and Burtsev: agents write to and read from a shared memory slot that's pooled and broadcast to all of them, without exchanging messages (not, as it might sound, direct cross-attention between agents). Tested on multi-agent pathfinding problems (the POGEMA benchmark), it clearly beats multi-agent reinforcement-learning baselines on the sparse-reward "Bottleneck" task; across the full POGEMA suite the paper describes it as competitive with recent approaches, without beating them across the board (code on GitHub).

In enterprise practice, a useful distinction for framing the problem is between Direct MAS, where agents talk to each other explicitly via protocols like A2A or gRPC, and Stigmergic MAS, where agents that look isolated influence each other's behavior by writing to and reading from shared systems: databases, queues, or a Model Context Protocol (MCP) server exposing a persistent resource. A2A has been under Linux Foundation governance since 2025, with over 150 member organizations per its one-year progress report.

MCP itself is "just" the protocol an agent uses to call tools and read external resources, it doesn't define any multi-agent shared-memory scheme. It only becomes a stigmergic substrate once the resource behind that server is shared and writable by more than one agent (a database, a graph): at that point agents read and write state into the same resource through the same standardized protocol. MCP (tool/data access) and A2A (agent-to-agent messaging) cover two different layers of the same stack, which is why purpose-built agent-memory frameworks (Mem0, Graphiti) often build a graph under the hood, exactly as described below.

AspectDirect MASStigmergic MAS
How they coordinateDirect messages between agents (A2A, gRPC)Reading/writing to a shared environment
ExampleExplicit requests between agentsKnowledge graph, MCP, shared database
With more agentsComplexity grows with connectionsGrows less: just connect to the environment
Direct MAS (Multi-Agent System with direct communication) and Stigmergic MAS (indirect coordination via a shared environment), side by side.

This pattern has an academic precedent: the blackboard architecture (Hayes-Roth, 1985), agents collaborating by reading and writing to a shared "blackboard" instead of talking directly. In 2025 the first studies applying this scheme to LLM-based agents appeared, with concrete results: an October 2025 arXiv paper measures a 13-57% improvement in task success over classic RAG and master-slave multi-agent systems, on data-science tasks. The limits are discussed in a 2025 arXiv critique of whether LLM agents actually reproduce swarm-intelligence properties or just their appearance.

Practical attention is also growing outside academia: community forums and writeups (including competitions like Kaggle's Gemma 3n hackathon) describe implementations of "stigmergic coordination" between agents that communicate through shared files or queues, with claimed but not independently verified efficiency gains.

Can the knowledge graph become the enterprise stigmergic environment?

If stigmergy works when the shared environment is structured and readable by multiple agents, then a knowledge graph governed by an ontology is a natural candidate to become that environment inside a company: an explicit representation of entities and relationships that different agents, human or AI, can read and enrich without needing to coordinate by hand, provided that ontology is actually built, not just called one.

Picture an agent that qualifies leads, one that schedules technical work, one that handles invoicing. If all three write to and read from the same graph (this client, that contract, that open ticket), you don't need central orchestration making them talk: the graph itself carries information from one agent to the next, in the right order, with the right semantics. It's the same principle behind why I build multi-agent systems on top of a shared ontology instead of a fragile message bus: implicit coordination scales better as the number of agents grows, and breaks less when one of them changes version. Purpose-built agent memory layer frameworks for multi-agent shared memory, like Mem0 or Graphiti, arrive at the same conclusion from a different direction, building a graph under the hood themselves to track provenance and entities over time (see Mem0's 2026 report on AI agent memory). Here instead the graph is the enterprise one that already models clients, contracts and tickets: no extra memory layer to bolt on.

Lead agentClientContractKnowledgeGraphBilling agent
The lead agent writes two different facts (client, contract) into the same graph; the billing agent reads them from there, with no direct message exchange from the first.

Where is caution warranted?

Stigmergy isn't free. Without governance, if one agent writes bad data into the graph, every downstream agent silently inherits the error. In practice: no agent gets direct write access to the canonical graph. It writes to a staging area first, tagged with provenance (which agent, which model version, which source); a policy layer or a human reviewer promotes the write into the canonical graph only after validation (a human-in-the-loop pattern); every promoted fact keeps an audit trail of who asserted it and when. Several agent-memory frameworks (Mem0, Graphiti) now ship this pattern by default.

In practice, when I design a multi-agent system the first question isn't how the agents talk to each other: it's who can write what, and who notices if they get it wrong. It's the same principle behind the on-site work I describe on the how-I-work page, just applied to agents instead of people.

In short

Stigmergy as a principle, coordination through a shared environment instead of direct messages, rests on solid ground and has concrete applications: from Dorigo's ant colony optimization to blackboard architectures, all the way to SRMT and the Model Context Protocol. The jump to "universal algorithm for deterministic AGI" is a different matter: one author's stimulating hypothesis, not a verified result. For a business, a well-governed knowledge graph is probably the best stigmergic environment you can build today.

Sources and further reading
Multi-Agent SystemsKnowledge GraphAI

Frequently asked questions

It's coordination among agents (ants, robots, AI systems) that happens by modifying a shared environment instead of exchanging direct messages: the environment itself carries information from one agent to another.

Ant colony optimization is an algorithm (Dorigo, 1990s) inspired by real ants' stigmergy: it simulates digital pheromones on a graph to find optimal paths. Stigmergy is the more general biological principle behind it.

Treat it with caution. It's an 'online-first' IntechOpen contribution, not a traditionally peer-reviewed publication, and its strongest claims (deterministic AGI) aren't backed by independent verification.

Yes: if multiple agents (human or AI) read and write to the same ontology-governed graph, the graph carries information between them without needing a central orchestrator to make them communicate directly.

Keep reading

If you need the AI in production, not in a demo, that is my job.

SEE AI INTEGRATIONS

Or write to me.