Assemble Your Crew: Automatic Multi-agent Communication Topology Design via Autoregressive Graph Generation
Shiyuan Li, Yixin Liu, Qingsong Wen, Chengqi Zhang, Shirui Pan
TL;DR
This paper reframes multi-agent system topology design as conditional autoregressive graph generation, introducing ARG-Designer which builds the collaboration graph from scratch conditioned on a natural language task query $\mathcal{Q}$ and an extensible role pool $\mathcal{R}$. It defines MAS as a DAG $\mathcal{G}$ and uses two GRU-based generators to sequentially decide node roles and incoming edges, with an END token to determine graph size and an autoregressive factorization $P(\mathcal{G}|\mathcal{Q},\mathcal{R})$. A two-phase curriculum training scheme combines a dense-exploration phase with a sparsity-focused efficiency phase, optimizing a weighted sum of node and edge likelihoods $\mathcal{L}_{\text{total}} = \alpha \mathcal{L}_{\text{node}} + (1-\alpha) \mathcal{L}_{\text{edge}}$ and using teacher forcing. Across six benchmarks, ARG-Designer achieves state-of-the-art results with markedly improved token efficiency and robustness to prompt attacks, while demonstrating strong extensibility by accommodating new agent roles on the fly. The work advances practical MAS design by enabling task-specific, scalable, and efficient collaboration topologies without reliance on rigid templates.
Abstract
Multi-agent systems (MAS) based on large language models (LLMs) have emerged as a powerful solution for dealing with complex problems across diverse domains. The effectiveness of MAS is critically dependent on its collaboration topology, which has become a focal point for automated design research. However, existing approaches are fundamentally constrained by their reliance on a template graph modification paradigm with a predefined set of agents and hard-coded interaction structures, significantly limiting their adaptability to task-specific requirements. To address these limitations, we reframe MAS design as a conditional autoregressive graph generation task, where both the system composition and structure are designed jointly. We propose ARG-Designer, a novel autoregressive model that operationalizes this paradigm by constructing the collaboration graph from scratch. Conditioned on a natural language task query, ARG-Designer sequentially and dynamically determines the required number of agents, selects their appropriate roles from an extensible pool, and establishes the optimal communication links between them. This generative approach creates a customized topology in a flexible and extensible manner, precisely tailored to the unique demands of different tasks. Extensive experiments across six diverse benchmarks demonstrate that ARG-Designer not only achieves state-of-the-art performance but also enjoys significantly greater token efficiency and enhanced extensibility. The source code of ARG-Designer is available at https://github.com/Shiy-Li/ARG-Designer.
