Summary
This paper proposes CanItEdit, a hand-curated evaluation benchmark consisting of 105 Python code editing problems, spanning three different categories: corrective edits, adaptive edits, and perfective edits. Each problem comes with two different types of natural language instructions: descriptive (entailing specific details for more explicit guidance) and lazy (minimal instructions that more closely resemble typical user queries). They further construct a training set for this task by filtering the CommitPackFT dataset and also mining additional examples from GitHub commits, where the instructions correspond to commit messages. They demonstrate out-of-the-box, open-source models (CodeLlama, Mixtral, DeepSeekCoder, StarCoder, OctoCoder) fall behind closed models (GPT-3.5-Turbo, GPT-4) by significant margins on this benchmark. By fine-tuning DeepSeekCoder-Base on their new training set, they observe improvements which appear to reduce the gap to a certain extent.
Reasons to accept
- The authors propose an evaluation set that captures diverse use cases (e.g., editing based on detailed specifications like the descriptive instruction versus editing based on brief user queries like lazy instruction) as well as many different categories of edits: corrective edits (35 examples), adaptive edits (35 examples), and perfective edits (35 examples). I believe this is a novel and very useful contribution to the community as it allows more fine-grained evaluation of LLMs with respect to code editing tasks.
- While I would like to get some more clarity on the details behind this dataset creation procedure (see below), the benchmark is hand-curated, making it likely a very high-quality evaluation set, relative to the few existing code editing datasets. This makes it a very valuable resource for the research community.
- The authors defined a new metric ExcessCode which I believe is very clever and useful. Benchmarks like SWEBench which rely on execution metrics only do not penalize models for making unnecessary changes to the code. I think this metric is also an interesting contribution to the community.
- The experiments are very comprehensive, spanning many different models and dataset ablations. This has highlighted important results with respect to the effect of model size on pass@1 and ExcessCode, and the gap between open and closed source models on this task.
Reasons to reject
- Very minimal details about the dataset creation procedure are provided. (Please see questions below). This makes it very difficult to understand how the dataset was constructed and consequently assess its quality.
- The dataset is Python-only and does not allow evaluating across different programming languages.
Missing references:
- Automating Code Review Activities by Large-Scale Pre-training (https://arxiv.org/abs/2203.09095)
- CoditT5: Pretraining for Source Code and Natural Language Editing (https://arxiv.org/abs/2208.05446)
- Top Leaderboard Ranking = Top Coding Proficiency, Always? EvoEval: Evolving Coding Benchmarks via LLM (https://arxiv.org/abs/2403.19114)
- CodeEditorBench: Evaluating Code Editing Capability of Large Language Models (https://arxiv.org/abs/2404.03543). (Note: This can be considered contemporary work and I have just included it for reference.)
Questions to authors
- Please provide more details about the dataset creation procedure. For instance, how were the annotators recruited? What were the exact instructions provided to them? It is not clear how the annotators come up with problems. Are they from scratch or is a starting point provided to them? If a starting point is provided, how is it derived? Do these annotators write both the descriptive and lazy instructions. Please explain in more detail the following claim: "Upon completion of a problem, the lead generated sample completions to ensure that the failures and successes were reasonable and consistent with the problem's intent."
- A common use case is updating documentation (e.g., comments, README); however, it is not clear how such documentation edits can be evaluated with test cases. Does this evaluation benchmark include such edits?
- The following claim is made in the paper: "GPT-4, despite not being specifically trained on code-related tasks, surpasses…" Could you explain how you came to this conclusion? It does seem that GPT-4 was trained on a significant amount of code, including come commits data.
- It's not clear why Table 4 was not presented like Table 3, with results for "Descriptive" and "Lazy" shown separately. Do the ablations perform differently for these different use cases?
- Despite motivating the different categories of edits, the main paper does not dive into this at all. I see that some additional results are provided in Table 6 of the Appendix, but this does not include all models in Table 3. Could you share details on whether the same trends are there across these categories for all the models presented in Table 3?