mlsanityData to 7 Oct 2026

Generating Bug-Fixes Using Pretrained Transformers

arXiv 2104.07896 ↗First posted 16 Apr 2021cs.CL cs.PLcited by 18

Not on the map. Why?

Abstract (arXiv)

Detecting and fixing bugs are two of the most important yet frustrating parts of the software development cycle. Existing bug detection tools are based mainly on static analyzers, which rely on mathematical logic and symbolic reasoning about the program execution to detect common types of bugs. Fixing bugs is typically left out to the developer. In this work we introduce DeepDebug: a data-driven program repair approach which learns to detect and fix bugs in Java methods mined from real-world GitHub repositories. We frame bug-patching as a sequence-to-sequence learning task consisting of two steps: (i) denoising pretraining, and (ii) supervised finetuning on the target translation task. We show that pretraining on source code programs improves the number of patches found by 33% as compared to supervised training from scratch, while domain-adaptive pretraining from natural language to code further improves the accuracy by another 32%. We refine the standard accuracy evaluation metric into non-deletion and deletion-only fixes, and show that our best model generates 75% more non-deletion fixes than the previous state of the art. In contrast to prior work, we attain our best results when generating raw code, as opposed to working with abstracted code that tends to only benefit smaller capacity models. Finally, we observe a subtle improvement from adding syntax embeddings along with the standard positional embeddings, as well as with adding an auxiliary task to predict each token's syntactic class. Despite focusing on Java, our approach is language agnostic, requiring only a general-purpose parser such as tree-sitter.

Key facts. Cited by 18 papers in the map (data through 7 Oct 2026). Builds on 22 of its 27 references that are in the map. First posted on arXiv 16 Apr 2021.

Builds on

22 of 27 references.

References · 22

  1. 2017Attention Is All You Needcited by 59,932
  2. 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
  3. 2020Scaling Laws for Neural Language Modelscited by 6,411
  4. 2019BART: Denoising Sequence-to-Sequence Pre-training for Natural Language Generation, Translation, and Comprehensioncited by 5,874
  5. 2018GLUE: A Multi-Task Benchmark and Analysis Platform for Natural Language Understandingcited by 4,854
  6. 2015Neural Machine Translation of Rare Words with Subword Unitscited by 2,898
  7. 2019fairseq: A Fast, Extensible Toolkit for Sequence Modelingcited by 1,486
  8. 2020CodeBERT: A Pre-Trained Model for Programming and Natural Languagescited by 1,286
  9. 2017Get To The Point: Summarization with Pointer-Generator Networkscited by 1,281
  10. 2019Theoretical Limitations of Self-Attention in Neural Sequence Modelscited by 286
  11. 2017OpenNMT: Open-source Toolkit for Neural Machine Translationcited by 251
  12. 2020IntelliCode Compose: Code Generation Using Transformercited by 225
10 more
  1. 2018SequenceR: Sequence-to-Sequence Learning for End-to-End Program Repaircited by 144
  2. 2018An Empirical Study on Learning Bug-Fixing Patches in the Wild via Neural Machine Translationcited by 106
  3. 2019Parallel Iterative Edit Models for Local Sequence Transductioncited by 81
  4. 2020Encoder-Decoder Models Can Benefit from Pre-trained Masked Language Models in Grammatical Error Correctioncited by 59
  5. 2019An Empirical Study of Incorporating Pseudo Data into Grammatical Error Correctioncited by 55
  6. 2019Improving Grammatical Error Correction via Pre-Training a Copy-Augmented Architecture with Unlabeled Datacited by 50
  7. 2019Learning and Evaluating Contextual Embedding of Source Codecited by 33
  8. 2017Semantic Code Repair using Neuro-Symbolic Transformation Networkscited by 13
  9. 2020Copy that! Editing Sequences by Copying Spanscited by 13
  10. 2019ENCORE: Ensemble Learning using Convolution Neural Machine Translation for Automatic Program Repaircited by 3

Built on by

Cited by year (2026 to 7 Oct)

Citing papers per year: 2021: 5; 2022: 8; 2023: 3; 2024: 0; 2025: 0; 2026: 2.

18 papers.

Sort:

By area:

  1. 2021Evaluating Large Language Models Trained on Codecited by 8,053
  2. 2022ReACC: A Retrieval-Augmented Code Completion Frameworkcited by 117
  3. 2021Examining Zero-Shot Vulnerability Repair with Large Language Modelscited by 105
  4. 2022CoditT5: Pretraining for Source Code and Natural Language Editingcited by 45
  5. 2022Training and Evaluating a Jupyter Notebook Data Science Assistantcited by 31
  6. 2022Deep Learning Meets Software Engineering: A Survey on Pre-Trained Models of Source Codecited by 20
  7. 2021DeepDebug: Fixing Python Bugs Using Stack Traces, Backtranslation, and Code Skeletonscited by 17
  8. 2021Long-Range Modeling of Source Code Files with eWASH: Extended Window Access by Syntax Hierarchycited by 14
  9. 2022A Survey on Pretrained Language Models for Neural Code Intelligencecited by 13
  10. 2022Unveiling Code Pre-Trained Models: Investigating Syntax and Semantics Capacitiescited by 9
  11. 2023Automating Code-Related Tasks Through Transformers: The Impact of Pre-trainingcited by 8
  12. 2022On The Cross-Modal Transfer from Natural Language to Code through Adapter Modulescited by 6
6 more
  1. 2021Self-Supervised Learning to Prove Equivalence Between Straight-Line Programs via Rewrite Rulescited by 3
  2. 2023Neural Machine Translation for Code Generationcited by 3
  3. 2022Exploring and Evaluating Personalized Models for Code Generationcited by 2
  4. 2023Program Repair with Minimal Edits Using CodeT5cited by 2
  5. 2026On the Impact of Code Comments for Automated Bug-Fixing: An Empirical Studycited by 0
  6. 2026MultiFixer: A Coordinator-Proposer Based Multi-Agent Framework For Fixing Multi-Hunk Bugscited by 0