发现代码合并请求中近四成是无效审查,影响模型预测准确性。
On The Impact of Merge Request Deviations on Code Review Practices
- 识别出七类合并请求偏差,用少样本学习方法实现91%准确率检测
- 剔除偏差后,53%的模型预测时间精度提升至2.25倍,特征重要性显著变化
- 为开发者优化评审流程、提升分析可靠性提供实证支持
代码审查是软件工程中的关键实践,保障质量与协作。然而工业级合并请求(MR)工作流常偏离标准流程,许多MR实际用于非审查目的(如草稿、重基线或依赖更新)。我们称此类情况为偏差,并假设忽略它们会扭曲分析结果并削弱机器学习模型性能。研究识别出七类偏差,占所有MR的37.02%,提出一种少样本学习检测方法,准确率达91%。剔除偏差后,预测审查完成时间的机器学习模型在53.33%的案例中性能提升(最高达2.25倍),特征重要性发生显著变化(整体47%,前k项达60%)。贡献包括:(1) 构建了MR偏差分类体系;(2) 提出基于AI的检测方法;(3) 为基于机器学习的审查分析提供了实证依据。该研究有助于实践者优化审查投入,确保分析结果可靠。
原文摘要 · Abstract (English)
Code review is a key practice in software engineering, ensuring quality and collaboration. However, industrial Merge Request (MR) workflows often deviate from standardized review processes, with many MRs serving non-review purposes (e.g., drafts, rebases, or dependency updates). We term these cases deviations and hypothesize that ignoring them biases analytics and undermines ML models for review analysis. We identify seven deviation categories, occurring in 37.02% of MRs, and propose a few-shot learning detection method (91% accuracy). By excluding deviations, ML models predicting review completion time improve performance in 53.33% of cases (up to 2.25x) and exhibit significant shifts in feature importance (47% overall, 60% top-*k*). Our contributions include: (1) a taxonomy of MR deviations, (2) an AI-driven detection approach, and (3) empirical evidence of their impact on ML-based review analytics. This work aids practitioners in optimizing review efforts and ensuring reliable insights.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。