Is Multi-Agent Debate (MAD) the Silver Bullet? An Empirical Analysis of MAD in Code Summarization and Translation
Jina Chun, Qihong Chen, Jiawei Li, Iftekhar Ahmed
TL;DR
This study evaluates Multi-Agent Debate (MAD) in software engineering tasks, focusing on Code Summarization and Code Translation. It adapts MAD from NLP, employing three debate agents and a judge, and introduces two enhancements—Early Termination and Extended Reflection—to mitigate underperforming debate patterns. Results indicate that MAD can improve semantic alignment in code summaries and, with Extended Reflection, enhance translation quality, though performance relative to state-of-the-art baselines varies by task. The work analyzes debate interactions to identify failure patterns and demonstrates MAD's potential for SE automation while acknowledging cost and generalization considerations. It also provides a roadmap for future exploration of debate-driven reasoning in SE contexts.
Abstract
Large Language Models (LLMs) have advanced autonomous agents' planning and decision-making, yet they struggle with complex tasks requiring diverse expertise and multi-step reasoning. Multi-Agent Debate (MAD) systems, introduced in NLP research, address this gap by enabling structured debates among LLM-based agents to refine solutions iteratively. MAD promotes divergent thinking through role-specific agents, dynamic interactions, and structured decision-making. Recognizing parallels between Software Engineering (SE) and collaborative human problem-solving, this study investigates MAD's effectiveness on two SE tasks. We adapt MAD systems from NLP, analyze agent interactions to assess consensus-building and iterative refinement, and propose two enhancements targeting observed weaknesses. Our findings show that structured debate and collaboration improve problem-solving and yield strong performance in some cases, highlighting MAD's potential for SE automation while identifying areas for exploration.
