Source-linked AI summary

A Dynamic LLM-Powered Agent Network for Task-Oriented Agent Collaboration

Zijun Liu, Yanzhe Zhang, Peng Li, Yang Liu, Diyi Yang

arXiv:2310.02170v2cs.CLcs.AIcs.MA

TL;DR

Existing LLM multi-agent approaches often use fixed team membership and static communication, leaving task-oriented dynamic selection underexplored. DyLAN selects task-relevant agents using an unsupervised importance score, then solves queries through dynamic collaboration. It outperforms strong baselines across several task types with moderate computational cost, with up to 25.0% higher accuracy on specific MMLU subjects.

  • Problem

    Existing multi-agent approaches retain fixed agent teams and static communication structures, while task-oriented dynamic agent selection remains insufficiently explored.

  • Method

    DyLAN uses temporal feed-forward networks and a two-stage process that selects top-contributing agents with an unsupervised Agent Importance Score before dynamic task solving.

  • Results

    DyLAN improves performance across code generation, decision-making, general reasoning, and arithmetic reasoning tasks, with up to 25.0% higher accuracy on specific MMLU subjects.

  • Takeaways & Limitations

    Dynamic team optimization improves DyLAN’s accuracy and efficiency across diverse tasks while reducing reliance on fixed agent teams and human preconceptions.

  • Takeaways & Limitations

    The authors identify risks of improper or socially misaligned responses from pretrained models and hand- or LLM-generated agents.

Abstract

from arXiv · show

Recent studies show that collaborating multiple large language model (LLM) powered agents is a promising way for task solving. However, current approaches are constrained by using a fixed number of agents and static communication structures. In this work, we propose automatically selecting a team of agents from candidates to collaborate in a dynamic communication structure toward different tasks and domains. Specifically, we build a framework named Dynamic LLM-Powered Agent Network ($\textbf{DyLAN}$) for LLM-powered agent collaboration, operating a two-stage paradigm: (1) Team Optimization and (2) Task Solving. During the first stage, we utilize an $\textit{agent selection}$ algorithm, based on an unsupervised metric called $\textit{Agent Importance Score}$, enabling the selection of best agents according to their contributions in a preliminary trial, oriented to the given task. Then, in the second stage, the selected agents collaborate dynamically according to the query. Empirically, we demonstrate that DyLAN outperforms strong baselines in code generation, decision-making, general reasoning, and arithmetic reasoning tasks with moderate computational cost. On specific subjects in MMLU, selecting a team of agents in the team optimization stage improves accuracy by up to 25.0% in DyLAN.

1 Introduction

Existing multi-agent systems generally use fixed team membership and static communication structures, leaving task-oriented agent selection underexplored. DyLAN addresses this gap with dynamic team optimization followed by task solving, improving performance across tasks and reaching up to 25.0% higher accuracy on some MMLU subjects.

  • Research gap: Fixed communication structures do not change agent-team membership during collaboration, leaving task-oriented dynamic agent selection insufficiently explored.Existing systems include debating for reasoning and self-collaboration for coding, but retain fixed teams.
  • Framework: DyLAN represents multi-agent collaboration as temporal feed-forward networks, with layers as communication steps, nodes as agents, and edges as communications.This representation supports dynamic agent teams independently of a particular communication structure.
  • Framework: DyLAN selects top-contributing agents from an initial candidate team using an unsupervised Agent Importance Score during Team Optimization.A forward-backward message-passing algorithm estimates each agent’s contribution for the task query before forming a smaller team.
  • Framework: DyLAN’s two-stage paradigm combines Team Optimization with Task Solving, allowing selected agents to collaborate dynamically for the query.The framework is designed for task-oriented collaboration across different tasks and domains.
  • Results: 25.0% is the maximum reported accuracy improvement from team optimization on specific MMLU subjects.The result highlights the effect of dynamically selecting agents for particular subjects.

2 Related Work

Related work studies how LLM agents communicate and how teams are constructed or evaluated, but commonly relies on predefined structures or fixed agent roles. DyLAN extends this line of work by evaluating agent contributions within multi-round collaboration and representing collaboration as a temporal network.

  • Team Optimization: Team optimization methods choose tools or generate role prompts, but manual or predefined descriptions may not yield the desired agent abilities without verification.Posterior selection based on agents’ actual task-specific behavior is presented as essential.
  • Communication Structures: LLM collaboration research has explored communication structures such as fixed-round debate and other predefined agent architectures.These approaches aim to improve reasoning and the capabilities of individual LLMs through multi-agent interaction.
  • Contribution Evaluation: Evaluating individual agent contributions is difficult in multi-round systems, while existing response-ranking methods primarily address single-round settings.LLM-based pairwise ranking can require O(n^2) comparisons, or O(nk) with a k-length sliding window.
  • Comparison: Table 1 compares DyLAN with representative prior works using nodes for agents, arrows for communication edges, and colors for agent roles.The comparison organizes systems through their temporal network representations.

3 Dynamic LLM-Powered Agent Network

DyLAN models agent collaboration as temporal feed-forward networks and separates task-oriented collaboration into team optimization and task solving. It dynamically passes messages, reforms teams, and selects agents through contribution-based evaluation.

  • Overview: The framework first performs Team Optimization and then uses the optimized team for Task Solving on the query.The first stage conducts a preliminary trial, while the second stage performs collaboration.
  • Overview: DyLAN constructs collaboration as a temporal feed-forward network whose layers represent time steps, nodes represent agents, and edges represent communication channels.The network can represent dynamic communication structures and agent team reformation.
  • Inference: During inference, agents receive responses from the previous time step and generate responses that may provide criticism, advice, refinement, or quality reviews.Forward message passing propagates responses through adjacent layers, with the final output selected from the last layer.
  • Agent Team Reformation: Agent team reformation uses an LLM Ranker to select top-ranked agents for subsequent time steps, thereby constructing a dynamic communication structure.The process iterates until a stopping condition is met, and early stopping can terminate inference when over 2/3 of agents in a layer agree.
  • Team Optimization: Agent selection evaluates candidate contributions in a primary trial through propagation, aggregation, and a three-step optimization procedure.Nodes rate predecessor solutions during forward passing, then backward aggregation quantifies each node’s contribution from successor ratings.

4 Experiments

DyLAN is evaluated across code generation, decision-making, general reasoning, and arithmetic reasoning, with results emphasizing task-oriented team optimization, efficiency, and stability. The experiments show that dynamic selection can improve accuracy and reduce API calls, while early stopping substantially lowers communication cost.

  • Experimental Setup: DyLAN is evaluated on HumanEval, WebShop, MMLU, and MATH for code generation, decision-making, general reasoning, and arithmetic reasoning.The study compares DyLAN with single-agent, multi-agent, and task-specific baselines across these benchmarks.
  • Experimental Setup: Agent selection is performed per general-reasoning subject and decision-making webpage, while code-generation teams are selected directly during team optimization.This setup makes team composition task- or domain-oriented rather than fixed globally.
  • Main Results: 10.2% higher accuracy and 10.6% lower #API calls than LLM Debate demonstrate DyLAN’s efficiency-effectiveness trade-off on general reasoning.The comparison is reported for L3 versus L4 in Table 3.
  • Main Results: Up to 25.0% accuracy improvement across general-reasoning subjects and up to 6.7% overall improvement show benefits from task-oriented team optimization.The paper also reports lower computational costs after agent selection, especially for decision-making.
  • Ablation Studies: An optimized three-agent team can outperform unoptimized DyLAN and four-agent LLM Debate, indicating that fewer suitable agents may perform better.The authors attribute this pattern to interference from imbalanced expertise and opinions before optimization.
  • Ablation Studies: Early stopping reduces #API calls by 45.0% on AR, 66.2% on GR, 11.3% on CG, and 54.2% on DM while slightly improving performance.Agent team reformation is reported as critical for final-answer correctness.
  • Ablation Studies: DyLAN maintains steady high code-generation performance across backbone models with almost the same number of API calls.This contrasts with the stronger backbone sensitivity reported for Reflexion and CodeT.

5 Conclusion and Future Work

DyLAN is a two-stage framework for dynamic agent-team collaboration, selecting contributory agents before task solving. The paper reports improved performance across diverse tasks with relatively lower computational cost and identifies open-source foundation models as future work.

  • Conclusion: DyLAN selects top-contributory agents using the unsupervised Agent Importance Score before dynamic task-solving collaboration.Its two stages are Team Optimization and Task Solving.
  • Conclusion: DyLAN improves performance across diverse tasks with relatively less computational cost than baselines.The conclusion summarizes the paper’s overall empirical finding.
  • Future Work: Future work will explore DyLAN built on open-source foundation models.

Ethics Statement

DyLAN is described as applicable to practical open-world agent systems, while the paper acknowledges risks from pretrained models and manually or automatically created agents. Team optimization is presented as a possible mitigation.

  • Practical Scope: DyLAN could cover software development, virtual room chat, and video games, with agents taking roles such as planners and actors.The system requires only rough instructions about agent constitution and can automatically optimize a team.
  • Risks: Pretrained models such as GPT-3.5 and GPT-4 may produce improper responses, and agent creation can lead to socially misaligned behavior.The paper identifies these as potential risks during agent collaboration.
  • Risk Mitigation: The paper suggests team optimization could potentially alleviate risks arising from agent behavior.

A Discussion & Limitation

The discussion identifies evaluation and optimization limitations in DyLAN, including reliance on BLEU for code consistency and unresolved finer-grained optimization. It also notes failure risks when most available agents conflict with task requirements.

  • Evaluation: BLEU is used to determine answer consistency for early stopping in code generation, although task-specific metrics could further improve evaluation.The paper specifically mentions CodeBLEU and CodeT as possible alternatives.
  • Evaluation: Human annotation could complement agent-evaluation metrics to measure individual contributions more precisely, especially with scarce data.
  • Optimization: Finer-grained cooperation between off-collaboration and in-collaboration optimization remains unresolved for improving performance and efficiency.
  • Scope boundaries: When most agents contradict task requirements, agent selection may still yield low performance because unsuitable agents dominate the candidate pool.The paper gives code-generation agents answering clinical questions as an example.

B.1 Detailed Experiment Settings

The experiments implement DyLAN as a temporal feed-forward agent network with explicit inference, team reformation, agent scoring, and task-specific settings. Configuration choices include bounded memory, listwise ranking, temperature controls, and task-dependent agent teams.

  • Inference: DyLAN represents inference with a T-FFN whose input is a query and whose output is a final answer.
  • Team optimization: Agent Importance Scores are computed by propagating contributions backward through the network, with team reformation replacing agents according to ranked responses.
  • Experimental settings: DyLAN uses one-response memory, listwise ranking, k = 2 for reformation, and task-specific temperatures, token limits, rounds, and candidate teams.
  • Agent selection: Agent selection prompts each node to rate predecessor solutions from 1 to 5, normalizes the scores, and shuffles responses to reduce positional bias.
  • Agent selection: Reasoning and decision-making experiments distribute final contributions across consistent answers, while code-generation experiments use final-round solutions without syntax errors.

C.1 Data Efficiency of Team Optimization

The data-efficiency experiments test whether agent teams can be optimized from limited subsets and then evaluated on the full dataset. DyLAN improves over random selection on code generation, while tool-augmented agents are consistently selected.

  • Data efficiency: Agent selection is optimized using 1% and 10% dataset subsets, then the selected team is evaluated on the whole dataset.Random selection and human-prior selection serve as baselines.
  • Results: +3.7 improvement over random selection is obtained on CG with limited-data team optimization.
  • Results: Tool-augmented agents are always selected during team optimization across the tested dataset proportions.The paper presents this pattern as evidence that Agent Importance Score indicates useful agents.

C.2 Robustness of different foundation models in DyLAN

DyLAN is evaluated across foundation models, agent-selection indicators, and temperature settings. The reported results show transfer of teams optimized on GPT-3.5 to GPT-4, differences from human-prior selection, and stronger temperature robustness than most baselines, with higher temperature increasing API calls.

  • Foundation-model robustness: DyLAN consistently outperforms other multi-agent methods on GPT-4 code generation, indicating transferability of teams optimized on GPT-3.5.LATS performs better but requires over 40 GPT-4 calls per sample for inference-time MCTS.
  • Agent selection: Agent Importance Score selections sometimes differ from human priors, including High School Computer Science receiving the highest score for “Doctor.”
  • Agent selection: Agent Importance Score selection steadily outperforms Human Prior Selection on the compared MMLU and HumanEval subjects.
  • Temperature robustness: Most baselines lose performance as temperature increases, whereas DyLAN remains robust and can improve with higher temperature on arithmetic reasoning and code generation.The paper attributes this pattern to diversity and retaining strong responses through team reformation.
  • Temperature robustness: +0.98 average API calls are required on AR when temperature increases from 0.2 to 1.0.

C.5 Different Ranking Methods

DyLAN’s agent-team reformation performance changes relatively little across the tested ranking methods on the general reasoning task.

  • Different ranking methods have a relatively low impact on DyLAN’s general reasoning performance.The tested methods include listwise, pairwise GPT, Elo Score, and pairwise Sliding Window ranking.
  • The comparison evaluates listwise, pairwise GPT, Elo Score, and pairwise Sliding Window ranking methods.
  • Table 14 reports DyLAN’s overall accuracy (%) under different ranking methods for agent-team reformation.All other experimental settings remain identical to Table 4.

C.6 Does Agent Importance Score Captures Actual Contributions?

The paper evaluates Agent Importance Score against Shapley Value as an indicator of individual agent contributions, while illustrating dynamic collaboration across tasks. It reports high correlation between the two metrics but notes that Shapley Value has high combinatorial computation cost.

  • Shapley Value serves as a supervised reference metric for evaluating individual agent contributions in multi-agent systems.Its computation requires ground truth and multi-pass results for different agent subsets.
  • Shapley Value becomes computationally expensive as the number of agents grows because of its combinatorial complexity.The metric uses classification accuracy or Pass@1 as the system-performance measure, depending on the task.
  • Agent Importance Score is evaluated as an unsupervised alternative to Shapley Value for selecting agents in DyLAN.The paper summarizes it as having light computational complexity.
  • High correlation is reported between Agent Importance Scores and Shapley Values on general reasoning tasks.The comparison uses KL divergence and ListMLE to measure similarity between their distributions.
  • DyLAN’s case studies show query-dependent communication structures and progressively improved answers across temporal steps.The examples cover code generation and general reasoning, including one initially incorrect answer that becomes correct at the second time step.
  • A code-generation failure case attributes the wrong optimization direction to the Code Reflector.
Loading 2310.02170v2…