Failure Localization in Multi-Agent Code Generation via Knowledge-Guided and Transferable Reasoning
DOI:
https://doi.org/10.1609/aaai.v40i1.36993Abstract
Recent advances in multi-agent Large Language Model-based code generation enable collaborative software development through role-specialized agents. However, failure localization of code generation remains challenging due to inter-agent dependencies and solution-path multiplicity. Consequently, existing prompting-based localization methods exhibit vulnerability towards semantically valid but non-canonical strategies. To address this, we propose FLKR (Failure Localization via Knowledge-guided Reasoning), an self-supervised framework that combines behavior encoding, knowledge-strategy alignment, and consistency scoring for solution-path invariant localization. To evaluate, we also introduce COFL (Code Oriented Failure Localization), the first expert-annotated benchmark for fine-grained failure localization. Experiments show FLKR outperforms state-of-the-art prompting-based baselines by up to 14 points in Fault Localization Accuracy and 45 points in Top-1 accuracy, with strong performance in divergent, real-world, and refinement-critical cases. Such results demonstrate that our proposed FLKR generalizes well to real-world software development scenarios and opens up a new direction for failure-aware refinement recommendation by providing precise and interpretable responsibility signals.Published
2026-03-14
How to Cite
Geng, M., Gu, S., Liu, Z., Xu, C., Qu, Z., & Wang, H. (2026). Failure Localization in Multi-Agent Code Generation via Knowledge-Guided and Transferable Reasoning. Proceedings of the AAAI Conference on Artificial Intelligence, 40(1), 318-326. https://doi.org/10.1609/aaai.v40i1.36993
Issue
Section
AAAI Technical Track on Application Domains I