arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2406.00515cs.CLcs.AIcs.SE
收藏

大型语言模型用于代码生成的综述

A Survey on Large Language Models for Code Generation

The Hong Kong University of Science and Technology (Guangzhou)(香港科学与技术大学(广州))

Juyong Jiang, Fan Wang, Jiasi Shen, Sungju Kim, Sunghun Kim

AI总结:

本文系统综述了大型语言模型在代码生成领域的研究进展,提出分类法,涵盖数据、方法、评估与伦理,并通过基准对比展示能力提升,指出挑战与机遇。

摘要:

大型语言模型(LLMs)在各类代码相关任务中取得了显著进展,被称为代码大语言模型(Code LLMs),尤其是在代码生成方面,即利用LLM从自然语言描述生成源代码。这一新兴领域因其在软件开发中的实际意义(例如GitHub Copilot)而引起了学术界和工业界专业人士的极大兴趣。尽管从自然语言处理(NLP)或软件工程(SE)或两者的角度,人们已积极探索LLM用于各种代码任务,但针对LLM用于代码生成的全面且最新的文献综述却明显缺失。在本综述中,我们旨在通过提供一份系统性的文献回顾来弥合这一差距,为研究人员探究LLM用于代码生成的前沿进展提供有价值的参考。我们引入了一个分类法,以分类和讨论LLM用于代码生成的最新发展,涵盖数据整理、最新进展、性能评估、伦理影响、环境影响和实际应用等方面。此外,我们提供了LLM用于代码生成演化的历史概述,并使用HumanEval、MBPP和BigCodeBench基准在不同难度级别和编程任务类型上进行了实证比较,以突出LLM在代码生成能力上的逐步增强。我们识别了学术界与实际开发之间差距的关键挑战和有前景的机遇。此外,我们建立了一个专门的资源GitHub页面(https://github.com/juyongjiang/CodeLLMSurvey),以持续记录和传播该领域的最新进展。

英文摘要:

Large Language Models (LLMs) have garnered remarkable advancements across diverse code-related tasks, known as Code LLMs, particularly in code generation that generates source code with LLM from natural language descriptions. This burgeoning field has captured significant interest from both academic researchers and industry professionals due to its practical significance in software development, e.g., GitHub Copilot. Despite the active exploration of LLMs for a variety of code tasks, either from the perspective of natural language processing (NLP) or software engineering (SE) or both, there is a noticeable absence of a comprehensive and up-to-date literature review dedicated to LLM for code generation. In this survey, we aim to bridge this gap by providing a systematic literature review that serves as a valuable reference for researchers investigating the cutting-edge progress in LLMs for code generation. We introduce a taxonomy to categorize and discuss the recent developments in LLMs for code generation, covering aspects such as data curation, latest advances, performance evaluation, ethical implications, environmental impact, and real-world applications. In addition, we present a historical overview of the evolution of LLMs for code generation and offer an empirical comparison using the HumanEval, MBPP, and BigCodeBench benchmarks across various levels of difficulty and types of programming tasks to highlight the progressive enhancements in LLM capabilities for code generation. We identify critical challenges and promising opportunities regarding the gap between academia and practical development. Furthermore, we have established a dedicated resource GitHub page (https://github.com/juyongjiang/CodeLLMSurvey) to continuously document and disseminate the most recent advances in the field.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑