arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2512.08810cs.SEcs.AIcs.LG
收藏

面向LLM的多校准代码生成

Multicalibration for LLM-based Code Generation

RheinMain University of Applied Sciences(莱茵-美因应用科学大学)

Viola Campos, Robin Kuschnereit, Adrian Ulges

AI总结:

本文提出多校准方法以提升代码生成模型的置信度评分准确性,通过实验验证其在技能分数上的显著提升。

摘要:

随着基于AI的代码生成技术的广泛应用,研究者正在探索代码LLM的校准问题,即确保其置信度评分能够真实反映代码正确性的真正可能性。为此,我们研究了多校准方法,该方法可以捕捉关于编码问题的额外因素,如复杂性、代码长度或所用编程语言。我们研究了四种多校准方法,使用最新一代的代码LLM(Qwen3 Coder、GPT-OSS、DeepSeek-R1-Distill)在三个函数合成基准上进行测试。我们的结果表明,多校准在技能分数上相比未校准的token似然(+1.03)和基线校准(+0.37)均取得了显著改进。我们还研究了上述因素在消融实验中的影响,并将包含代码生成、似然和正确性标签的数据集提供给未来代码LLM校准研究。

英文摘要:

As AI-based code generation becomes widespread, researchers are investigating the calibration of code LLMs - ensuring their confidence scores faithfully represent the true likelihood of code correctness. To do so, we investigate multicalibration, which can capture additional factors about a coding problem, such as complexity, code length, or programming language used. We study four multicalibration approaches on three function synthesis benchmarks, using latest-generation code LLMs (Qwen3 Coder, GPT-OSS, DeepSeek-R1-Distill). Our results demonstrate that multicalibration can yield distinct improvements over both uncalibrated token likelihoods (+1.03 in skill score) and baseline calibrations (+0.37 in skill score). We study the influence of the aforementioned factors in ablations, and make our dataset (consisting of code generations, likelihoods, and correctness labels) available for future research on code LLM calibration.

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

↑