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

无限生成未见过的代码测试

Generating Unseen Code Tests In Infinitum

IBM Research AI(IBM研究院人工智能部门)

Marcel Zalmanovici, Orna Raz, Eitan Farchi, Iftach Freund

AI总结:

针对LLM基准易泄漏到训练数据的问题,提出一种持续生成测试数据的方法,并实现了名为auto-regression的基准用于Python文本到代码生成任务的调试与回归测试。

摘要:

大型语言模型(LLMs)被用于许多任务,包括与编码相关的任务。能够利用LLMs的一个重要方面是能够评估其对特定用途的适用性。常见的做法是根据一组基准来评估LLMs。虽然基准为评估和比较替代方案提供了坚实的基础,但它们存在一个众所周知的弱点,即泄漏到训练数据中。我们提出了一种创建基准变体的方法,该方法可推广到各种编码任务和编程语言,也可应用于内部代码库。我们的方法能够持续生成测试数据,从而缓解泄漏到训练数据中的问题。我们为Python中的文本到代码生成任务实现了一个名为auto-regression的基准。Auto-regression专门用于辅助调试,并作为LLM回归测试过程的一部分来跟踪模型生成的变化。

英文摘要:

Large Language Models (LLMs) are used for many tasks, including those related to coding. An important aspect of being able to utilize LLMs is the ability to assess their fitness for specific usages. The common practice is to evaluate LLMs against a set of benchmarks. While benchmarks provide a sound foundation for evaluation and comparison of alternatives, they suffer from the well-known weakness of leaking into the training data \cite{Xu2024Benchmarking}. We present a method for creating benchmark variations that generalize across coding tasks and programming languages, and may also be applied to in-house code bases. Our approach enables ongoing generation of test-data thus mitigating the leaking into the training data issue. We implement one benchmark, called \textit{auto-regression}, for the task of text-to-code generation in Python. Auto-regression is specifically created to aid in debugging and in tracking model generation changes as part of the LLM regression testing process.

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

↑