arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2202.13169cs.PLcs.CL
收藏

代码的大语言模型的系统评价

A Systematic Evaluation of Large Language Models of Code

Carnegie Mellon University(卡内基梅隆大学)

Frank F. Xu, Uri Alon, Graham Neubig, Vincent J. Hellendoorn

摘要:

代码的大语言模型(LM)最近在完成代码和从自然语言描述合成代码方面显示出巨大的前景。然而,当前最先进的代码LM(例如,Codex(Chen等人,2021年))尚未公开,这给他们的模型和数据设计决策留下了许多问题。我们的目标是通过对现有最大的模型进行系统评估来填补其中的一些空白:Codex,GPT-J,GPT-Neo,GPT-NeoX-20 B和CodeParrot,跨越各种程序设计语言。虽然Codex本身不是开源的,但我们发现现有的开源模型在某些程序设计语言中确实实现了接近的结果,尽管主要针对自然语言建模。我们进一步确定了一个重要的缺失部分,即专门在多语言代码语料库上训练的大型开源模型。我们发布了一个新的模型,PolyCoder,具有基于GPT-2架构的2.7 B参数,该模型在一台机器上使用12种程序设计语言的249 GB代码进行训练。在C程序设计语言中,PolyCoder优于包括Codex在内的所有型号。我们的训练模型是开源的,可以在https://github.com/VHellendoorn/Code-LMs上公开获取,这使得未来在这一领域的研究和应用成为可能。

英文摘要:

Large language models (LMs) of code have recently shown tremendous promise in completing code and synthesizing code from natural language descriptions. However, the current state-of-the-art code LMs (e.g., Codex (Chen et al., 2021)) are not publicly available, leaving many questions about their model and data design decisions. We aim to fill in some of these blanks through a systematic evaluation of the largest existing models: Codex, GPT-J, GPT-Neo, GPT-NeoX-20B, and CodeParrot, across various programming languages. Although Codex itself is not open-source, we find that existing open-source models do achieve close results in some programming languages, although targeted mainly for natural language modeling. We further identify an important missing piece in the form of a large open-source model trained exclusively on a multi-lingual corpus of code. We release a new model, PolyCoder, with 2.7B parameters based on the GPT-2 architecture, which was trained on 249GB of code across 12 programming languages on a single machine. In the C programming language, PolyCoder outperforms all models including Codex. Our trained models are open-source and publicly available at https://github.com/VHellendoorn/Code-LMs, which enables future research and application in this area.

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

↑