paperbot · PL 论文追踪

全部论文 待读 收藏

P2 LAURA: Enhancing Code Review Generation with Context-Enriched Retrieval-Augmented LLM

LAURA:利用上下文增强的检索增强 LLM 提升代码审查生成
ASE 2025 40th IEEE/ACM International Conference on Automated Software Engineering (ASE)2025匹配度 2/10 · 该论文聚焦用检索增强 LLM 生成代码审查意见,属于 LLM 在软件工程/代码理解中的应用,而非用户核心关注的静态分析、形式化验证、浮点程序分析或贝叶斯程序分析;也未涉及 Agentic 程序分析。虽然与 PL+ML 有交集且使用了较强模型,但研究目标本身偏向提升 LLM 生成质量,与画像匹配度较低。引用 4 inbox
Yuxin Zhang, Yuxia Zhang, Zeyu Sun, Yanjie Jiang, Hui Liu
crossref: 2026-09-12

AI 速览

一句话:提出 LAURA 框架,通过审查示例检索、上下文增强与系统引导,提升 LLM 生成代码审查意见的质量。

代码审查耗时且知识密集,现有自动生成方法主要利用历史代码变更与评论,忽略了代码变更上下文与先前审查知识。本文提出基于 LLM 的审查知识增强、上下文感知框架 LAURA,集成审查示例检索、上下文增强和系统化引导,以提升 ChatGPT-4o 和 DeepSeek v3 生成审查评论的能力;同时构建高质量数据集以缓解现有数据低质量问题。实验表明,两模型在 42.2% 和 40.4% 的案例中生成完全正确或至少对开发者有帮助的评论,显著优于 SOTA 基线;消融研究验证各组件均有正向贡献。

问题
现有代码审查自动生成方法主要依赖历史代码变更和评论,未充分利用代码变更上下文与历史审查知识,且数据集含大量低质量评论。
方法
提出 LAURA 框架,融合审查示例检索、上下文增强与系统化引导,并构建高质量代码审查数据集,以增强 ChatGPT-4o 和 DeepSeek v3 的审查评论生成。
评估
在两个 LLM 上实验,比较 SOTA 基线,并用消融研究验证各组件;结果显示生成完全正确或至少有用的评论比例分别达 42.2% 和 40.4%。
原文摘要(Abstract)

Code review is critical for ensuring software quality and maintainability. With the rapid growth in software scale and complexity, code review has become a bottleneck in the development process because of its time-consuming and knowledge-intensive nature and the shortage of experienced developers willing to review code. Several approaches have been proposed for automatically generating code reviews based on retrieval, neural machine translation, pre-trained models, or large language models (LLMs). These approaches mainly leverage historical code changes and review comments. However, a large amount of crucial information for code review, such as the context of code changes and prior review knowledge, has been overlooked. This paper proposes an LLM-based review knowledge-augmented, context-aware framework for code review generation, named LAURA. The framework integrates review exemplar retrieval, context augmentation, and systematic guidance to enhance the performance of ChatGPT-4o and DeepSeek v3 in generating code review comments. Besides, given the extensive low-quality reviews in existing datasets, we also constructed a high-quality dataset. Experimental results show that for both models, LAURA generates review comments that are either completely correct or at least helpful to developers in 42.2% and 40.4% of cases, respectively, significantly outperforming SOTA baselines. Furthermore, our ablation studies demonstrate that all components of LAURA contribute positively to improving comment quality.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@inproceedings{paperbot9382,
  title = {LAURA: Enhancing Code Review Generation with Context-Enriched Retrieval-Augmented LLM},
  author = {Yuxin Zhang and Yuxia Zhang and Zeyu Sun and Yanjie Jiang and Hui Liu},
  booktitle = {ASE},
  year = {2025},
  doi = {10.1109/ase63991.2025.00245}
}