Papers
Topics
Authors
Recent
Search
2000 character limit reached

ENCORE: Ensemble Learning using Convolution Neural Machine Translation for Automatic Program Repair

Published 20 Jun 2019 in cs.SE and cs.LG | (1906.08691v2)

Abstract: Automated generate-and-validate (G&V) program repair techniques typically rely on hard-coded rules, only fix bugs following specific patterns, and are hard to adapt to different programming languages. We propose ENCORE, a new G&V technique, which uses ensemble learning on convolutional neural machine translation (NMT) models to automatically fix bugs in multiple programming languages. We take advantage of the randomness in hyper-parameter tuning to build multiple models that fix different bugs and combine them using ensemble learning. This new convolutional NMT approach outperforms the standard long short-term memory (LSTM) approach used in previous work, as it better captures both local and long-distance connections between tokens. Our evaluation on two popular benchmarks, Defects4J and QuixBugs, shows that ENCORE fixed 42 bugs, including 16 that have not been fixed by existing techniques. In addition, ENCORE is the first G&V repair technique to be applied to four popular programming languages (Java, C++, Python, and JavaScript), fixing a total of 67 bugs across five benchmarks.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (76)
  1. Genprog: A generic method for automatic software repair. Ieee transactions on software engineering, 38(1):54–72, 2012.
  2. Staged program repair with condition synthesis. In Proceedings of the 2015 10th Joint Meeting on Foundations of Software Engineering, pages 166–178. ACM, 2015.
  3. Dynamoth: dynamic code synthesis for automatic program repair. In Proceedings of the 11th International Workshop on Automation of Software Test, pages 85–91. ACM, 2016.
  4. Better test cases for better automated program repair. In Proceedings of the 2017 11th Joint Meeting on Foundations of Software Engineering, pages 831–841. ACM, 2017.
  5. Nopol: Automatic repair of conditional statement bugs in java programs. IEEE Transactions on Software Engineering, 43(1):34–55, 2017.
  6. Elixir: effective object oriented program repair. In Proceedings of the 32nd IEEE/ACM International Conference on Automated Software Engineering, pages 648–659. IEEE Press, 2017.
  7. An analysis of the search spaces for generate and validate patch generation systems. In Software Engineering (ICSE), 2016 IEEE/ACM 38th International Conference on, pages 702–713. IEEE, 2016.
  8. Carol V Alexandru. Guided code synthesis using deep neural networks. In Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering, pages 1068–1070. ACM, 2016.
  9. Finding and correcting syntax errors using recurrent neural networks. PeerJ PrePrints, 2017.
  10. Deepfix: Fixing common c language errors by deep learning. In AAAI, pages 1345–1351, 2017.
  11. Sequencer: Sequence-to-sequence learning for end-to-end program repair. arXiv preprint arXiv:1901.01808, 2018.
  12. Convolutional sequence to sequence learning. arXiv preprint arXiv:1705.03122, 2017.
  13. Neural machine translation by jointly learning to align and translate. arXiv preprint arXiv:1409.0473, 2014.
  14. Long short-term memory. Neural computation, 9(8):1735–1780, 1997.
  15. Learning phrase representations using rnn encoder-decoder for statistical machine translation. arXiv preprint arXiv:1406.1078, 2014.
  16. Effective approaches to attention-based neural machine translation. arXiv preprint arXiv:1508.04025, 2015.
  17. Semantic code repair using neuro-symbolic transformation networks. arXiv preprint arXiv:1710.11054, 2017.
  18. A Multilayer Convolutional Encoder-Decoder Neural Network for Grammatical Error Correction. 2018.
  19. Automatically learning semantic features for defect prediction. In Software Engineering (ICSE), 2016 IEEE/ACM 38th International Conference on, pages 297–308. IEEE, 2016.
  20. On the properties of neural machine translation: Encoder-decoder approaches. arXiv preprint arXiv:1409.1259, 2014.
  21. Subword language modeling with neural networks. preprint (http://www. fit. vutbr. cz/imikolov/rnnlm/char. pdf), 8, 2012.
  22. An empirical investigation into learning bug-fixing patches in the wild via neural machine translation. In Proceedings of the 33rd ACM/IEEE International Conference on Automated Software Engineering. ACM, pages 832–837, 2018.
  23. Random search for hyper-parameter optimization. Journal of Machine Learning Research, 13(Feb):281–305, 2012.
  24. Defects4j: A database of existing faults to enable controlled testing studies for java programs. In Proceedings of the 2014 International Symposium on Software Testing and Analysis, pages 437–440. ACM, 2014.
  25. QuixBugs: a multi-lingual program repair benchmark set based on the quixey challenge. In Proceedings Companion of the 2017 ACM SIGPLAN International Conference on Systems, Programming, Languages, and Applications: Software for Humanity, pages 55–56. ACM, 2017.
  26. Automatic patch generation by learning correct code. POPL’16, page 298, 2016.
  27. Discovering bug patterns in javascript. In Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering, pages 144–156. ACM, 2016.
  28. Perplexity – a measure of the difficulty of speech recognition tasks. Journal of the Acoustical Society of America, 62:S63, November 1977. Supplement 1.
  29. Fairseq-py. https://github.com/pytorch/fairseq, 2018.
  30. Pytorch, 2017.
  31. Attention is all you need. In Advances in Neural Information Processing Systems, pages 5998–6008, 2017.
  32. You cannot fix what you cannot find! an investigation of fault localization bias in benchmarking automated program repair systems. ICST 2019, 2019.
  33. Astor: A program repair library for java. In Proceedings of the 25th International Symposium on Software Testing and Analysis, pages 441–444. ACM, 2016.
  34. History driven automated program repair. 2016.
  35. Precise condition synthesis for program repair. In Proceedings of the 39th International Conference on Software Engineering, pages 416–426. IEEE Press, 2017.
  36. Contract-based program repair without the contracts. In Automated Software Engineering (ASE), 2017 32nd IEEE/ACM International Conference on, pages 637–647. IEEE, 2017.
  37. Qi Xin and Steven P Reiss. Leveraging syntax-related code for automated program repair. In Proceedings of the 32nd IEEE/ACM International Conference on Automated Software Engineering, pages 660–670. IEEE Press, 2017.
  38. Context-aware patch generation for better automated program repair. ICSE, 2018.
  39. Sketchfix: a tool for automated program repair approach using lazy candidate generation. In Proceedings of the 2018 26th ACM Joint Meeting on European Software Engineering Conference and Symposium on the Foundations of Software Engineering, pages 888–891. ACM, 2018.
  40. Fixminer: Mining relevant fix patterns for automated program repair. arXiv preprint arXiv:1810.01791, 2018.
  41. Lsrepair: Live search of fix ingredients for automated program repair. 2018.
  42. Shaping program repair space with existing patches and similar code. 2018.
  43. Mining stackoverflow for program repair. In 2018 IEEE 25th International Conference on Software Analysis, Evolution and Reengineering (SANER), pages 118–129. IEEE, 2018.
  44. A comprehensive study of automatic program repair on the quixbugs benchmark. CoRR, abs/1805.03454, 2018.
  45. On the accuracy of spectrum-based fault localization. In Testing: Academic and Industrial Conference Practice and Research Techniques-MUTATION (TAICPART-MUTATION 2007), pages 89–98. IEEE, 2007.
  46. Dissection of a bug dataset: Anatomy of 395 patches from defects4j. arXiv preprint arXiv:1801.06393, 2018.
  47. An analysis of patch plausibility and correctness for generate-and-validate patch generation systems. In Proceedings of the 2015 International Symposium on Software Testing and Analysis, pages 24–36. ACM, 2015.
  48. Sydit: creating and applying a program transformation from an example. In Proceedings of the 19th ACM SIGSOFT symposium and the 13th European conference on Foundations of software engineering, pages 440–443. ACM, 2011.
  49. Automatic inference of code transforms for patch generation. In Proceedings of the 2017 11th Joint Meeting on Foundations of Software Engineering, ESEC/FSE, volume 2017, 2017.
  50. A multilayer convolutional encoder-decoder neural network for grammatical error correction. In Proceedings of the Thirty-Second AAAI Conference on Artificial Intelligence, February 2018.
  51. Exploiting Unlabeled Data for Neural Grammatical Error Detection. Journal of Computer Science and Technology, 32(4):758–767, 2017.
  52. Adapting Sequence Models for Sentence Correction. 2017.
  53. Systematically Adapting Machine Translation for Grammatical Error Correction. Proceedings of the 12th Workshop on Innovative Use of NLP for Building Educational Applications, pages 345–356, 2017.
  54. Grammatical Error Correction with Neural Reinforcement Learning. 2017.
  55. Approaching Neural Grammatical Error Correction as a Low-Resource Machine Translation Task. (2016):595–606, 2018.
  56. Neural Sequence-Labelling Models for Grammatical Error Correction. Proceedings of the 2017 Conference on Empirical Methods in Natural Language Processing, pages 2795–2806, 2017.
  57. Reaching Human-level Performance in Automatic Grammatical Error Correction: An Empirical Study. (3):1–15, 2018.
  58. Fluency Boost Learning and Inference for Neural Grammatical Error Correction. Proceedings of the 56th Annual Meeting of the Association for Computational Linguistics, 1:1–11, 2018.
  59. Grammatical Error Detection Using Error- and Grammaticality-Specific Word Embeddings. Proceedings ofthe The 8th International Joint Conference on Natural Language Processing, (2016):40–48, 2017.
  60. Software defect prediction via convolutional neural network. In Software Quality, Reliability and Security (QRS), 2017 IEEE International Conference on, pages 318–328. IEEE, 2017.
  61. Jinyong Wang and Ce Zhang. Software reliability prediction using a deep learning model based on the rnn encoder–decoder. Reliability Engineering & System Safety, 2017.
  62. code2vec: Learning distributed representations of code. Proceedings of the ACM on Programming Languages, 3(POPL):40, 2019.
  63. Dynamic neural program embeddings for program repair. In International Conference on Learning Representations, 2018.
  64. Learning to represent programs with graphs. In International Conference on Learning Representations, 2018.
  65. Building program vector representations for deep learning. In International Conference on Knowledge Science, Engineering and Management, pages 547–553. Springer, 2015.
  66. Deep code search. In Proceedings of the 40th International Conference on Software Engineering, pages 933–944. ACM, 2018.
  67. A convolutional attention network for extreme summarization of source code. In International Conference on Machine Learning, pages 2091–2100, 2016.
  68. Toward deep learning software repositories. In Mining Software Repositories (MSR), 2015 IEEE/ACM 12th Working Conference on, pages 334–345. IEEE, 2015.
  69. Are deep neural networks the best choice for modeling source code? In Proceedings of the 2017 11th Joint Meeting on Foundations of Software Engineering, ser. ESEC/FSE, pages 763–773, 2017.
  70. A survey of machine learning for big code and naturalness. arXiv preprint arXiv:1709.06182, 2017.
  71. Tree2tree neural translation model for learning source code changes. arXiv preprint arXiv:1810.00314, 2018.
  72. Deep learning code fragments for code clone detection. In Proceedings of the 31st IEEE/ACM International Conference on Automated Software Engineering, pages 87–98. ACM, 2016.
  73. Cclearner: A deep learning-based clone detection approach. In Software Maintenance and Evolution (ICSME), 2017 IEEE International Conference on, pages 249–260. IEEE, 2017.
  74. Neural sketch learning for conditional program generation. In International Conference on Learning Representations, 2018.
  75. Latent predictor networks for code generation. arXiv preprint arXiv:1603.06744, 2016.
  76. On end-to-end program generation from user intention by deep neural networks. arXiv preprint arXiv:1510.07211, 2015.
Citations (18)

Summary

No one has generated a summary of this paper yet.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Continue Learning

We haven't generated follow-up questions for this paper yet.

Collections

Sign up for free to add this paper to one or more collections.

Tweets

Sign up for free to view the 1 tweet with 0 likes about this paper.