ChatCoder: Chat-based Refine Requirement Improves LLMs' Code Generation
Zejun Wang, Jia Li, Ge Li, Zhi Jin

TL;DR
ChatCoder is a chat-based method that helps users refine their natural language requirements, leading to significantly improved code generation performance from large language models.
Contribution
It introduces a novel chat scheme for iterative requirement refinement that enhances LLMs' code accuracy compared to existing methods.
Findings
Significant performance improvement in code generation.
Outperforms refine-based and fine-tuned LLM methods.
Effective in clarifying ambiguous requirements.
Abstract
Large language models have shown good performances in generating code to meet human requirements. However, human requirements expressed in natural languages can be vague, incomplete, and ambiguous, leading large language models to misunderstand human requirements and make mistakes. Worse, it is difficult for a human user to refine the requirement. To help human users refine their requirements and improve large language models' code generation performances, we propose ChatCoder: a method to refine the requirements via chatting with large language models. We design a chat scheme in which the large language models will guide the human users to refine their expression of requirements to be more precise, unambiguous, and complete than before. Experiments show that ChatCoder has improved existing large language models' performance by a large margin. Besides, ChatCoder has the advantage over…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsTopic Modeling · Software Engineering Research · Software System Performance and Reliability
