MapCoder: Multi-Agent Code Generation for Competitive Problem Solving

被引:0
|
作者
Islam, Md. Ashraful [1 ]
Ali, Mohammed Eunus [1 ]
Parvez, Md Rizwan [2 ]
机构
[1] Bangladesh Univ Engn & Technol BUET, Dept Comp Sci & Engn, Dhaka, Bangladesh
[2] Qatar Comp Res Inst QCRI, Doha, Qatar
关键词
D O I
暂无
中图分类号
TP18 [人工智能理论];
学科分类号
081104 ; 0812 ; 0835 ; 1405 ;
摘要
Code synthesis, which requires a deep understanding of complex natural language (NL) problem descriptions, generation of code instructions for complex algorithms and data structures, and the successful execution of comprehensive unit tests, presents a significant challenge. Thus, while large language models (LLMs) demonstrate impressive proficiency in natural language processing (NLP), their performance in code generation tasks remains limited. In this paper, we introduce a new approach to code generation tasks leveraging the multi-agent prompting that uniquely replicates the full cycle of program synthesis as observed in human developers. Our framework, MapCoder, consists of four LLM agents specifically designed to emulate the stages of this cycle: recalling relevant examples, planning, code generation, and debugging. After conducting thorough experiments, with multiple LLMs ablations and analyses across eight challenging competitive problem-solving and program synthesis benchmarks-MapCoder showcases remarkable code generation capabilities, achieving their new state-of-the-art (pass@1) results-(HumanEval 93.9%, MBPP 83.1%, APPS 22.0%, CodeContests 28.5%, and xCodeEval 45.3%). Moreover, our method consistently delivers superior performance across various programming languages and varying problem difficulties. We open-source our framework at https://github.com/Md-Ashraful-Pramanik/MapCoder.
引用
收藏
页码:4912 / 4944
页数:33
相关论文
共 50 条
  • [1] Cooperative problem solving in mechanical multi-agent systems
    Xu, ZG
    Huang, KZ
    Ai, X
    Zeng, GZ
    PROCEEDINGS OF INTERNATIONAL WORKSHOP ON CSCW IN DESIGN, 1996, : 251 - 257
  • [2] The Role of Multi-Agent in Computational Problem Solving Environments
    Rajabi, Maryam
    Aris, Teh Noranis Mohd
    4TH INTERNATIONAL CONFERENCE ON ELECTRICAL ENGINEERING AND INFORMATICS (ICEEI 2013), 2013, 11 : 1103 - 1109
  • [3] A Multi-Agent Approach for Solving Traveling Salesman Problem
    ZHOU Tiejun~ 1
    2. Department of Information and Computer Science
    3. School of Management
    WuhanUniversityJournalofNaturalSciences, 2006, (05) : 1104 - 1108
  • [4] The genicAgent: a hybrid approach for multi-agent problem solving
    Saci, EA
    Cherruault, Y
    KYBERNETES, 2001, 30 (1-2) : 26 - 34
  • [5] Modeling and Solving the Multi-Agent Pathfinding Problem in Picat
    Bartak, Roman
    Zhou, Neng-Fa
    Stern, Roni
    Boyarski, Eli
    Surynek, Pavel
    2017 IEEE 29TH INTERNATIONAL CONFERENCE ON TOOLS WITH ARTIFICIAL INTELLIGENCE (ICTAI 2017), 2017, : 959 - 966
  • [6] Solving the Traveling Salesman Problem with a Multi-Agent System
    Yang, Chen
    Szeto, Kwok Yip
    2019 IEEE CONGRESS ON EVOLUTIONARY COMPUTATION (CEC), 2019, : 158 - 165
  • [7] A distributed problem solving environment for multi-agent systems
    Belo, O
    Neves, J
    CRITICAL TECHNOLOGY: PROCEEDINGS OF THE THIRD WORLD CONGRESS ON EXPERT SYSTEMS, VOLS I AND II, 1996, : 815 - 822
  • [8] TOWARDS PROBLEM SOLVING METHODS IN MULTI-AGENT SYSTEMS
    Bogg, Paul
    Beydoun, Ghassan
    Low, Graham
    ICSOFT 2009: PROCEEDINGS OF THE 4TH INTERNATIONAL CONFERENCE ON SOFTWARE AND DATA TECHNOLOGIES, VOL 2, 2009, : 308 - +
  • [9] A Multi-Agent Approach To Solving Dynamic Traveling Salesman Problem
    Varga, Andrea
    Chira, Camelia
    Dumitrescu, D.
    ADVANCED BIO-INSPIRED COMPUTATIONAL METHODS, 2008, : 220 - 227
  • [10] Solving a modified consensus problem of linear multi-agent systems
    Cheng, Long
    Hou, Zeng-Guang
    Lin, Yingzi
    Tan, Min
    Zhang, Wenjun
    AUTOMATICA, 2011, 47 (10) : 2218 - 2223