arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2412.04478cs.SEcs.AI
收藏

LibEvolutionEval:面向版本特定代码生成的基准与研究

LibEvolutionEval: A Benchmark and Study for Version-Specific Code Generation

AWS AI Labs(AWS人工智能实验室);NVIDIA(英伟达)

Sachit Kuhar, Wasi Uddin Ahmad, Zijian Wang, Nihal Jain, Haifeng Qian, Baishakhi Ray, Murali Krishna Ramanathan, Xiaofei Ma, Anoop Deoras

AI总结:

本文提出 LibEvolutionEval 基准,研究公共库版本演进对代码补全模型的影响,并验证版本特定文档检索与提示可有效提升模型处理快速演进库的能力。

摘要:

代码补全模型的最新进展主要聚焦于本地文件上下文。然而,这些研究并未完全捕捉现实世界软件开发的复杂性,而现实开发往往需要使用快速演进的公共库。为填补这一空白,我们引入了 LibEvolutionEval,这是一项需要理解库演进才能准确执行行内代码补全的详细研究。LibEvolutionEval 提供了一个版本特定的代码补全任务,由八个库(torch、torchvision、scipy、pil、tqdm、pyyaml、matplotlib 和 pandas)在一年间的演进构成,并附有对两个流行且维护良好的公共库 PyTorch 和 Matplotlib 演进的详细分析。我们评估了流行的公共模型,发现公共库演进显著影响模型性能。我们探索了缓解方法,研究了检索到的版本特定库文档和提示如何提升模型处理这些快速演进软件包的能力,为更好地处理快速演进库铺平了一条有前景的未来道路。

英文摘要:

Recent advancements in code completion models have primarily focused on local file contexts. However, these studies do not fully capture the complexity of real-world software development, which often requires the use of rapidly-evolving public libraries. To fill the gap, we introduce LibEvolutionEval, a detailed study requiring an understanding of library evolution to perform in-line code completion accurately. LibEvolutionEval provides a version-specific code-completion task comprised of eight libraries (torch, torchvision, scipy, pil, tqdm, pyyaml, matplotlib, and pandas) as they evolve over the year along with a detailed analysis of the evolution of two popular and well-maintained public libraries: PyTorch and Matplotlib. We evaluate popular public models and find that public library evolution significantly influences model performance. We explored mitigation methods by studying how retrieved version-specific library documentation and prompting can improve the model's capability in handling these fast-evolving packages, paving a promising future path in better handling fast-evolving libraries.

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

↑