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 条
  • [21] Multi-agent modeling for solving profit based unit commitment problem
    Sharma, Deepak
    Trivedi, Anupam
    Srinivasan, Dipti
    Thillainathan, Logenthiran
    APPLIED SOFT COMPUTING, 2013, 13 (08) : 3751 - 3761
  • [22] Solving the rendezvous problem for multi-agent systems using contraction theory
    Russo, Giovanni
    di Bernardo, Mario
    PROCEEDINGS OF THE 48TH IEEE CONFERENCE ON DECISION AND CONTROL, 2009 HELD JOINTLY WITH THE 2009 28TH CHINESE CONTROL CONFERENCE (CDC/CCC 2009), 2009, : 5821 - 5826
  • [23] Abstract Architecture for Task-oriented Multi-agent Problem Solving
    Vokrinek, Jiri
    Komenda, Antonin
    Pechoucek, Michal
    IEEE TRANSACTIONS ON SYSTEMS MAN AND CYBERNETICS PART C-APPLICATIONS AND REVIEWS, 2011, 41 (01): : 31 - 40
  • [24] Cooperative Multi-Agent System for Solving Packet World Problem in Grid
    Abusnaina, Ahmed A. A.
    Yong, Chan Huah
    2009 IEEE 9TH MALAYSIA INTERNATIONAL CONFERENCE ON COMMUNICATIONS (MICC), 2009, : 754 - 758
  • [25] Inducing domain theory from problem solving in a multi-agent system
    Puertas, E
    Armengol, E
    RECENT ADVANCES IN ARTIFICIAL INTELLIGENCE RESEARCH AND DEVELOPMENT, 2004, 113 : 325 - 332
  • [26] A bankruptcy based approach to solving multi-agent credit assignment problem
    Yarahmadi, Hossein
    Shiri, Mohammad Ebrahim
    Navidi, Hamidreza
    Sharifi, Arash
    INTERNATIONAL JOURNAL OF NONLINEAR ANALYSIS AND APPLICATIONS, 2021, 12 : 1987 - 2018
  • [27] Multi-agent collaboration in competitive scenarios
    Fuchs, F
    RE-ENGINEERING FOR SUSTAINABLE INDUSTRIAL PRODUCTION, 1997, : 275 - 283
  • [28] Multi-agent Competitive Control Systems
    Zhang, Zhenning
    Cheng, Daizhan
    PROCEEDINGS OF THE 10TH WORLD CONGRESS ON INTELLIGENT CONTROL AND AUTOMATION (WCICA 2012), 2012, : 2263 - 2267
  • [29] Evolutionary multi-agent model with intent exchange solving multi objective optimization problem
    Kangping, Wang
    Chunguang, Zhou
    Dongwei, Guo
    Zhe, Wang
    DYNAMICS OF CONTINUOUS DISCRETE AND IMPULSIVE SYSTEMS-SERIES B-APPLICATIONS & ALGORITHMS, 2007, 14 : 430 - 433
  • [30] Solving multi-agent games on networks
    Vaknin, Yair
    Meisels, Amnon
    AUTONOMOUS AGENTS AND MULTI-AGENT SYSTEMS, 2025, 39 (01)