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

CodeSift:一个无需参考的基于LLM的自动代码验证框架

CodeSift: An LLM-Based Reference-Less Framework for Automatic Code Validation

IBM Research(IBM研究院);IBM(IBM公司)

Pooja Aggarwal, Oishik Chatterjee, Ting Dai, Prateeti Mohapatra, Brent Paulovicks, Brad Blancett, Arthur De Magalhaes

AI总结:

本文提出CodeSift框架,利用LLM作为无需执行、参考代码或人工反馈的代码验证第一道过滤器,在多个数据集上超越现有方法且符合人类偏好。

摘要:

大型语言模型(LLMs)的出现极大地促进了代码生成,但确保生成代码的功能正确性仍是一项挑战。传统的验证方法通常耗时、易错,且不适用于大批量代码。我们提出了CodeSift,这是一个利用LLM作为代码验证第一道过滤器的全新框架,无需执行、参考代码或人工反馈,从而减少了验证工作量。我们在涵盖两种编程语言的三个不同数据集上评估了该方法的有效性。结果表明,CodeSift超越了最先进的代码评估方法。与领域专家进行的内部测试显示,CodeSift生成的输出符合人类偏好,进一步证实了其作为可靠自动代码验证工具的有效性。

英文摘要:

The advent of large language models (LLMs) has greatly facilitated code generation, but ensuring the functional correctness of generated code remains a challenge. Traditional validation methods are often time-consuming, error-prone, and impractical for large volumes of code. We introduce CodeSift, a novel framework that leverages LLMs as the first-line filter of code validation without the need for execution, reference code, or human feedback, thereby reducing the validation effort. We assess the effectiveness of our method across three diverse datasets encompassing two programming languages. Our results indicate that CodeSift outperforms state-of-the-art code evaluation methods. Internal testing conducted with subject matter experts reveals that the output generated by CodeSift is in line with human preference, reinforcing its effectiveness as a dependable automated code validation tool.

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

↑