arXiv:2512.20159cs.SEcs.AI2025-12被引 2

用规则扰动和多源校准构建更可靠的代码评价基准

AXIOM: Benchmarking LLM-as-a-Judge for Code via Rule-Based Perturbation and Multisource Quality Calibration

  • 通过预定义规则让大模型逐步修改高质量代码,精准控制评分分布
  • 实现从高到低的均衡质量分级,避免评分偏差
  • 适合评估代码生成质量的评测系统开发者

大语言模型(LLMs)在软件工程中应用日益广泛,催生了代码质量评估指标。传统基于规则的指标仅根据代码与参考程序的表面相似性打分,未能深入分析功能与代码质量。为此,研究者提出了以 LLM 为评判者的评估方法,并构建了多个代码评估基准。然而这些基准存在严重缺陷:部分使用粗粒度二值标签,将复杂代码行为压缩为单一比特信息,掩盖细微错误;另一些则采用细粒度但主观、模糊的评价标准,导致人工标注得分不可靠,成为依赖的“真实标签”。此外,数据合成方法缺乏控制,造成评分分布失衡,无法反映真实代码生成场景。为构建具有多样化、质量分布均衡的基准并简化人工标注流程,我们提出 AXIOM——一种基于扰动的可扩展代码评估基准生成框架。该框架将程序评分重新定义为部署所需修正工作量,包含两个阶段:(1) 规则引导的扰动,利用大模型对高质量程序执行一系列预设扰动规则,改变其功能与质量,从而精确控制目标评分,实现评分分布均衡;(2) 多源质量校准,首先选取子集...

原文摘要 · Abstract (English)

Large language models (LLMs) have been increasingly deployed in real-world software engineering, fostering the development of code evaluation metrics to study the quality of LLM-generated code. Conventional rule-based metrics merely score programs based on their surface-level similarities with reference programs instead of analyzing functionality and code quality in depth. To address this limitation, researchers have developed LLM-as-a-judge metrics, prompting LLMs to evaluate and score code, and curated various code evaluation benchmarks to validate their effectiveness. However, these benchmarks suffer from critical limitations, hindering reliable assessments of evaluation capability: Some feature coarse-grained binary labels, which reduce rich code behavior to a single bit of information, obscuring subtle errors. Others propose fine-grained but subjective, vaguely-defined evaluation criteria, introducing unreliability in manually-annotated scores, which is the ground-truth they rely on. Furthermore, they often use uncontrolled data synthesis methods, leading to unbalanced score distributions that poorly represent real-world code generation scenarios. To curate a diverse benchmark with programs of well-balanced distributions across various quality levels and streamline the manual annotation procedure, we propose AXIOM, a novel perturbation-based framework for synthesizing code evaluation benchmarks at scale. It reframes program scores as the refinement effort needed for deployment, consisting of two stages: (1) Rule-guided perturbation, which prompts LLMs to apply sequences of predefined perturbation rules to existing high-quality programs to modify their functionality and code quality, enabling us to precisely control each program's target score to achieve balanced score distributions. (2) Multisource quality calibration, which first selects a subset of...

代码评估大模型评测基准构建

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。