mlsanityData to 13 Oct 2026

RGD: Multi-LLM Based Agent Debugger via Refinement and Generation Guidance

arXiv 2410.01242 ↗First posted 2 Oct 2024cs.SE cs.AI cs.CLcited by 12

On the map: LLM agents and tool use → Software engineering coding agents

Abstract (arXiv)

Large Language Models (LLMs) have shown incredible potential in code generation tasks, and recent research in prompt engineering have enhanced LLMs' understanding of textual information. However, ensuring the accuracy of generated code often requires extensive testing and validation by programmers. While LLMs can typically generate code based on task descriptions, their accuracy remains limited, especially for complex tasks that require a deeper understanding of both the problem statement and the code generation process. This limitation is primarily due to the LLMs' need to simultaneously comprehend text and generate syntactically and semantically correct code, without having the capability to automatically refine the code. In real-world software development, programmers rarely produce flawless code in a single attempt based on the task description alone, they rely on iterative feedback and debugging to refine their programs. Inspired by this process, we introduce a novel architecture of LLM-based agents for code generation and automatic debugging: Refinement and Guidance Debugging (RGD). The RGD framework is a multi-LLM-based agent debugger that leverages three distinct LLM agents-Guide Agent, Debug Agent, and Feedback Agent. RGD decomposes the code generation task into multiple steps, ensuring a clearer workflow and enabling iterative code refinement based on self-reflection and feedback. Experimental results demonstrate that RGD exhibits remarkable code generation capabilities, achieving state-of-the-art performance with a 9.8% improvement on the HumanEval dataset and a 16.2% improvement on the MBPP dataset compared to the state-of-the-art approaches and traditional direct prompting approaches. We highlight the effectiveness of the RGD framework in enhancing LLMs' ability to generate and refine code autonomously.

Key facts. Cited by 12 papers in the map (data through 13 Oct 2026). Placed in Software engineering coding agents, one of 16 directions in LLM agents and tool use. Builds on 35 of its 39 references that are in the map. First posted on arXiv 2 Oct 2024.

Builds on

35 of 39 references.

Closest ancestors · 2

Same direction, newest first

  1. 2024From LLMs to LLM-based Agents for Software Engineering: A Survey of Current, Challenges and Future5 Aug
  2. 2024MapCoder: Multi-Agent Code Generation for Competitive Problem Solving18 May

Other references · 33

  1. 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,376
  2. 2020Retrieval-Augmented Generation for Knowledge-Intensive NLP Taskscited by 9,221
  3. 2019Sentence-BERT: Sentence Embeddings using Siamese BERT-Networkscited by 9,107
  4. 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 8,502
  5. 2021Evaluating Large Language Models Trained on Codecited by 8,205
  6. 2023Reflexion: Language Agents with Verbal Reinforcement Learningcited by 4,156
  7. 2020Dense Passage Retrieval for Open-Domain Question Answeringcited by 3,797
  8. 2021Program Synthesis with Large Language Modelscited by 3,573
  9. 2023Tree of Thoughts: Deliberate Problem Solving with Large Language Modelscited by 3,181
  10. 2023Retrieval-Augmented Generation for Large Language Models: A Surveycited by 2,196
  11. 2020REALM: Retrieval-Augmented Language Model Pre-Trainingcited by 2,131
  12. 2023Code Llama: Open Foundation Models for Codecited by 2,130
21 more
  1. 2020CodeBERT: A Pre-Trained Model for Programming and Natural Languagescited by 1,304
  2. 2023Teaching Large Language Models to Self-Debugcited by 972
  3. 2021Measuring Coding Challenge Competence With APPScited by 891
  4. 2022CodeGen: An Open Large Language Model for Code with Multi-Turn Program Synthesiscited by 884
  5. 2023A Prompt Pattern Catalog to Enhance Prompt Engineering with ChatGPTcited by 616
  6. 2024A Survey on RAG Meeting LLMs: Towards Retrieval-Augmented Large Language Modelscited by 450
  7. 2023Harnessing the Power of LLMs in Practice: A Survey on ChatGPT and Beyondcited by 411
  8. 2023CodeGeeX: A Pre-Trained Model for Code Generation with Multilingual Benchmarking on HumanEval-Xcited by 298
  9. 2023Is Self-Repair a Silver Bullet for Code Generation?cited by 194
  10. 2023Self-planning Code Generation with Large Language Modelscited by 123
  11. 2023Evaluating the Code Quality of AI-Assisted Code Generation Tools: An Empirical Study on GitHub Copilot, Amazon CodeWhisperer, and ChatGPTcited by 71
  12. 2021A Few Brief Notes on DeepImpact, COIL, and a Conceptual Framework for Information Retrieval Techniquescited by 69
  13. 2023CodeScore: Evaluating Code Generation by Learning Code Executioncited by 66
  14. 2023SelfEvolve: A Code Evolution Framework via Large Language Modelscited by 43
  15. 2023SQL-PaLM: Improved Large Language Model Adaptation for Text-to-SQL (extended)cited by 42
  16. 2024CYCLE: Learning to Self-Refine the Code Generationcited by 42
  17. 2023ToolCoder: Teach Code Generation Models to use API search toolscited by 37
  18. 2023CodeCoT: Tackling Code Syntax Errors in CoT Reasoning for Code Generationcited by 29
  19. 2023L2CEval: Evaluating Language-to-Code Generation Capabilities of Large Language Modelscited by 22
  20. 2023Coffee: Boost Your Code LLMs by Fixing Bugs with Feedbackcited by 15
  21. 2024Leveraging Print Debugging to Improve Code Generation in Large Language Modelscited by 15

Built on by

Cited by year (2026 to 13 Oct)

Citing papers per year: 2025: 10; 2026: 2.

12 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2024COAST: Enhancing the Code Debugging Ability of LLMs through Communicative Agent Based Data Synthesis
  2. 2025A Survey on Code Generation with LLM-based Agents
  3. 2025debug-gym: A Text-Based Environment for Interactive Debugging
  4. 2026TDD-Agent: Test-Driven Reasoning for Code Generation
  5. 2025AdaCoder: An Adaptive Planning and Multi-Agent Framework for Function-Level Code Generation
  6. 2025Fully Autonomous Programming using Iterative Multi-Agent Debugging with Large Language Models
  7. 2025Empirical Research on Utilizing LLM-based Agents for Automated Bug Fixing via LangGraph
  8. 2025CodeVisionary: An Agent-based Framework for Evaluating Large Language Models in Code Generation