ConDefects: A New Dataset to Address the Data Leakage Concern for LLM-based Fault Localization and Program Repair

📄 arXiv: 2310.16253v1 📥 PDF

作者: Yonghao Wu, Zheng Li, Jie M. Zhang, Yong Liu

分类: cs.SE, cs.AI

发布日期: 2023-10-25

备注: 5pages, 3 figures


💡 一句话要点

提出ConDefects以解决LLM故障定位和程序修复中的数据泄露问题

🎯 匹配领域: 支柱九:具身大模型 (Embodied Foundation Models)

关键词: 大型语言模型 故障定位 程序修复 数据集 数据泄露 Java Python 基准测试

📋 核心要点

  1. 现有的故障定位和程序修复方法面临数据泄露风险,导致性能评估不准确。
  2. 提出了ConDefects数据集,专门针对真实故障进行精心策划,消除与现有LLMs训练数据的重叠。
  3. ConDefects包含1254个Java和1625个Python故障程序,适用于各种故障定位和程序修复方法的基准测试。

📝 摘要(中文)

随着对大型语言模型(LLMs)在故障定位和程序修复中的兴趣日益增长,确保LLM方法的完整性和泛化能力变得至关重要。现有广泛采用的基准测试中的代码是在LLMs兴起之前编写的,可能包含在现有流行LLMs的训练数据中,从而面临数据泄露的威胁,导致性能指标过于乐观。为了解决这一问题,本文提出了“ConDefects”,一个新颖的数据集,包含1254个Java故障程序和1625个Python故障程序,所有程序均来自在线竞赛平台AtCoder,生成时间为2021年10月至2023年9月。每个故障都配有故障位置和相应的修复代码版本,旨在为故障定位和程序修复相关研究提供支持。该数据集公开可用,并提供基于不同时间窗口和编码任务难度选择子集的接口。

🔬 方法详解

问题定义:本文旨在解决现有LLM方法在故障定位和程序修复中因数据泄露而导致的性能评估不准确的问题。现有基准测试中的代码可能与LLMs的训练数据重叠,影响结果的可靠性。

核心思路:通过构建一个全新的数据集ConDefects,确保数据的独立性,消除与现有LLMs训练数据的重叠,从而提供更真实的性能评估基础。

技术框架:ConDefects数据集包含1254个Java和1625个Python故障程序,所有程序均来自AtCoder平台,时间范围为2021年10月至2023年9月。每个故障都配有故障位置和修复版本,支持多种故障定位和修复方法的评估。

关键创新:ConDefects是首个针对LLM方法数据泄露问题而设计的数据集,提供了真实故障的多样性和丰富性,确保了评估的公正性和准确性。

关键设计:数据集设计中考虑了故障的多样性和难度,提供了基于时间窗口和任务难度选择子集的接口,便于研究人员进行针对性实验。

🖼️ 关键图片

fig_0
fig_1
fig_2

📊 实验亮点

ConDefects数据集的引入使得故障定位和程序修复的性能评估更加准确,消除了数据泄露的影响。该数据集包含1254个Java和1625个Python故障程序,提供了丰富的测试用例,能够有效支持多种方法的基准测试。

🎯 应用场景

ConDefects数据集的构建为故障定位和程序修复研究提供了一个可靠的基准,能够有效评估各种方法的性能。其潜在应用包括软件开发中的自动化故障检测、修复工具的优化以及教育领域中的编程教学等,具有重要的实际价值和广泛的影响力。

📄 摘要(原文)

With the growing interest on Large Language Models (LLMs) for fault localization and program repair, ensuring the integrity and generalizability of the LLM-based methods becomes paramount. The code in existing widely-adopted benchmarks for these tasks was written before the the bloom of LLMs and may be included in the training data of existing popular LLMs, thereby suffering from the threat of data leakage, leading to misleadingly optimistic performance metrics. To address this issue, we introduce "ConDefects", a novel dataset of real faults meticulously curated to eliminate such overlap. ConDefects contains 1,254 Java faulty programs and 1,625 Python faulty programs. All these programs are sourced from the online competition platform AtCoder and were produced between October 2021 and September 2023. We pair each fault with fault locations and the corresponding repaired code versions, making it tailored for in fault localization and program repair related research. We also provide interfaces for selecting subsets based on different time windows and coding task difficulties. While inspired by LLM-based tasks, ConDefects can be adopted for benchmarking ALL types of fault localization and program repair methods. The dataset is publicly available, and a demo video can be found at https://www.youtube.com/watch?v=22j15Hj5ONk.