Dynamic Topology Routing
Form and dissolve the connections between agents at runtime by matching the task to candidate collaborators, instead of committing the multi-agent system to a fixed chain, star, or mesh up front.
Problem
A fixed inter-agent topology is a compromise across all tasks the system will ever see. A mesh pays quadratic message and token cost even when a chain would do; a chain serialises work that could fan out; a star bottlenecks on its hub. Hard-wiring the structure at design time forces every task through the same shape, so some tasks over-communicate and others lack the links they need.
Solution
Separate the agent pool from the communication graph over it. For each task (or each step), a routing layer scores candidate agents against the current subtask — by capability description, embedding similarity, or a learned router — and instantiates only the edges needed: a chain when the work is sequential, a fan-out when it is parallel, a small clique when it needs debate. As the task evolves, edges are added and dropped. Approaches range from per-step semantic matching (DyTopo) to treating the whole topology as an optimisable graph trained end to end (GPTSwarm). The static chain, star, and mesh become special cases the router can choose, not the only option.
When to use
- The system serves tasks that want genuinely different communication shapes.
- A fixed mesh is too costly and a fixed chain too rigid for the workload.
- Agents carry clear, machine-comparable capability descriptions to route against.
- You can afford a routing decision per task or per step.
Open the full interactive page →
Diagram, neighbourhood map, code examples, related patterns and full provenance.