[Paper Review] FixEval: Execution-based Evaluation of Program Fixes for Programming Problems
FixEval introduces a novel benchmark for evaluating program repair models using execution-based testing on real competitive programming submissions, demonstrating that execution-based evaluation outperforms traditional match-based metrics in assessing functional correctness of generated fixes. The dataset includes 700 problems in Python and Java with unit tests, time/memory constraints, and verdict feedback, enabling robust evaluation of model-generated patches.
The complexity of modern software has led to a drastic increase in the time and cost associated with detecting and rectifying software bugs. In response, researchers have explored various methods to automatically generate fixes for buggy code. However, due to the large combinatorial space of possible fixes for any given bug, few tools and datasets are available to evaluate model-generated fixes effectively. To address this issue, we introduce FixEval, a benchmark comprising of buggy code submissions to competitive programming problems and their corresponding fixes. FixEval offers an extensive collection of unit tests to evaluate the correctness of model-generated program fixes and assess further information regarding time, memory constraints, and acceptance based on a verdict. We consider two Transformer language models pretrained on programming languages as our baseline and compare them using match-based and execution-based evaluation metrics. Our experiments show that match-based metrics do not reflect model-generated program fixes accurately. At the same time, execution-based methods evaluate programs through all cases and scenarios designed explicitly for that solution. Therefore, we believe FixEval provides a step towards real-world automatic bug fixing and model-generated code evaluation. The dataset and models are open-sourced at https://github.com/mahimanzum/FixEval.
Motivation & Objective
- To address the lack of comprehensive benchmarks for evaluating automated program repair models in real-world contexts.
- To provide a dataset of buggy and fixed program pairs with unit tests, time/memory constraints, and execution verdicts for accurate evaluation.
- To compare match-based and execution-based evaluation metrics in assessing model-generated code fixes.
- To demonstrate that execution-based evaluation better reflects functional correctness than traditional similarity metrics.
- To support future research in code repair, code completion, and feedback-driven model training.
Proposed method
- Collect 700 competitive programming problems from AtCoder and Aizu Online Judge with both buggy and accepted solutions in Python and Java.
- Include 25 unit tests per problem to evaluate functional correctness of generated fixes.
- Integrate time and memory constraints and execution verdicts (e.g., Wrong Answer, Compilation Error) as input context for models.
- Fine-tune two pretrained sequence-to-sequence models—PLBART and CodeT5—on the FixEval dataset for program repair.
- Evaluate model outputs using both match-based metrics (e.g., BLEU, CodeBLEU) and execution-based metrics via test suite execution.
- Analyze the impact of decoding strategies (greedy, beam search, nucleus sampling) and verdict information on fix quality.
Experimental results
Research questions
- RQ1How do match-based evaluation metrics compare to execution-based metrics in assessing the correctness of model-generated program fixes?
- RQ2To what extent does access to execution verdicts (e.g., Wrong Answer, Compilation Error) improve the quality of generated fixes?
- RQ3How do different decoding strategies (greedy, beam search, nucleus sampling) affect the performance of program repair models on FixEval?
- RQ4What is the impact of model input context, including time/memory constraints and test case feedback, on fix generation accuracy?
- RQ5How do task difficulty and edit similarity influence the performance of automated program repair models?
Key findings
- Execution-based evaluation using unit tests significantly outperforms match-based metrics like BLEU and CodeBLEU in identifying functionally correct fixes.
- Models provided with verdict information (e.g., Wrong Answer) generate more accurate and contextually relevant fixes than those without.
- Beam search decoding consistently outperforms greedy decoding and nucleus sampling, though performance gains are marginal.
- The model with verdict input avoids adding syntactically correct but semantically incorrect code, reducing noise in repairs.
- FixEval captures real-world repair challenges, including complexity constraints and edge cases, making it suitable for evaluating practical program repair systems.
- The benchmark reveals that while some fixes are trivial, many require deep understanding of logic and constraints, highlighting the need for robust evaluation.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.