SafeLLM4SE: Statistical Evaluation and Reporting for LLM-based Software Engineering Systems
作者: Francisco Ortin
分类: cs.SE, cs.LG
发布日期: 2026-09-29
备注: This work has been submitted for possible publication. Copyright may be transferred without notice, after which this version may no longer be accessible
💡 一句话要点
提出SafeLLM4SE以解决LLM软件工程评估中的不确定性问题
🎯 匹配领域: 支柱九:具身大模型 (Embodied Foundation Models)
关键词: 大型语言模型 软件工程 统计评估 随机过程 开源软件 评估标准 可重复性 性能比较
📋 核心要点
- 现有的评估方法未能充分考虑LLM输出的随机性,导致评估结果的可靠性受到质疑。
- SafeLLM4SE通过将LLM输出视为随机过程,结合自适应采样和置信区间等方法,提供了一种系统的评估框架。
- 在HumanEval基准上比较两种LLM的实验结果显示,SafeLLM4SE能够更准确地反映模型性能的稳定性和不确定性。
📝 摘要(中文)
大型语言模型(LLMs)在软件工程任务中的使用日益增加,但其随机行为对评估的有效性、可重复性和可比性构成挑战。传统的评估方法,如报告单一输出、平均分数或最佳表现,可能掩盖变异性和估计不确定性,从而导致对系统可靠性的误导性结论。本文提出了SafeLLM4SE,一种针对LLM软件工程系统的统计评估和报告标准,强调将生成输出视为随机过程的实现,区分质量、稳定性和估计不确定性,并结合自适应采样、置信区间和分布感知的统计比较等方法。SafeLLM4SE作为开源软件包提供,便于研究人员和从业者复现和扩展该方法。
🔬 方法详解
问题定义:论文要解决的问题是现有LLM软件工程评估方法未能充分考虑输出的随机性,导致评估结果的有效性和可靠性受到质疑。
核心思路:SafeLLM4SE的核心思路是将生成的输出视为随机过程的实现,强调质量、稳定性和估计不确定性,从而提供更全面的评估。
技术框架:SafeLLM4SE的整体架构包括自适应采样、置信区间计算、分布感知的统计比较和效果大小分析,确保评估的统计有效性。
关键创新:最重要的技术创新点在于将LLM输出视为随机过程,并引入了最低报告标准,涵盖模型配置、可重复性、评估程序和资源使用等方面。
关键设计:关键设计包括自适应采样策略的实现、置信区间的计算方法,以及如何进行分布感知的统计比较,确保评估结果的可靠性和可比性。
🖼️ 关键图片
📊 实验亮点
在HumanEval基准上,使用SafeLLM4SE方法对比两种LLM的实验结果显示,能够更准确地捕捉模型性能的变异性和不确定性,提升了评估的可靠性和可重复性,具体性能数据和提升幅度未知。
🎯 应用场景
SafeLLM4SE在软件工程领域具有广泛的应用潜力,尤其是在需要对LLM性能进行可靠评估的场景中,如代码生成、自动化测试和软件维护等。其开源特性使得研究人员和开发者能够在此基础上进行进一步的研究和应用,推动LLM技术在软件工程中的发展。
📄 摘要(原文)
Large language models (LLMs) are increasingly used for software engineering tasks, yet their stochastic behavior challenges the validity, reproducibility, and comparability of their evaluations. Conventional practices such as reporting a single output, an average score, best-of-N, or pass@k performance can obscure variability and estimation uncertainty, potentially leading to misleading conclusions about system reliability. This article presents SafeLLM4SE, a practical methodology and reporting standard for statistically principled evaluation of LLM-based software engineering systems. Rather than treating generated outputs as deterministic artifacts, SafeLLM4SE treats them as realizations of a stochastic process and distinguishes quality, stability, and estimation uncertainty. It combines adaptive sampling with confidence intervals, distribution-aware statistical comparisons, effect sizes, and a minimum reporting standard covering model configuration, reproducibility, evaluation procedures, and resource usage. SafeLLM4SE is also provided as an open-source software package available on PyPI, enabling researchers and practitioners to reproduce and extend the methodology. We illustrate its application by comparing two LLMs on HumanEval, a benchmark of programming problems assessed through functional tests.