Skip to main content
Article
DeepReview: Automatic code review using deep multi-instance learning
Advances in knowledge discovery and data mining: 23rd Pacific-Asia Conference, PAKDD 2019, Macau, China, April 14-17: Proceedings
  • Hengyi LI, Nanjing University
  • Shuting SHI, Nanjing University
  • Ferdian THUNG, Singapore Management University
  • Xuan HUO, Nanjing University
  • Bowen XU, Singapore Management University
  • Ming LI, Nanjing University
  • David LO, Singapore Management University
Publication Type
Conference Proceeding Article
Version
publishedVersion
Publication Date
4-2019
Abstract

Code review, an inspection of code changes in order to identify and fix defects before integration, is essential in Software Quality Assurance (SQA). Code review is a time-consuming task since the reviewers need to understand, analysis and provide comments manually. To alleviate the burden of reviewers, automatic code review is needed. However, this task has not been well studied before. To bridge this research gap, in this paper, we formalize automatic code review as a multi-instance learning task that each change consisting of multiple hunks is regarded as a bag, and each hunk is described as an instance. We propose a novel deep learning model named DeepReview based on Convolutional Neural Network (CNN), which is an end-to-end model that learns feature representation to predict whether one change is approved or rejected. Experimental results on open source projects show that DeepReview is effective in automatic code review tasks. In terms of F1 score and AUC, DeepReview outperforms the performance of traditional single-instance based model TFIDF-SVM and the state-of-the-art deep feature based model Deeper.

Keywords
  • Automatic code review,
  • Machine learning,
  • Multi-instance learning,
  • Software mining
ISBN
9783030161446
Identifier
10.1007/978-3-030-16145-3_25
Publisher
Springer
City or Country
Cham
Copyright Owner and License
Publisher
Creative Commons License
Creative Commons Attribution-NonCommercial-No Derivative Works 4.0 International
Additional URL
https://doi.org/10.1007/978-3-030-16145-3_25
Citation Information
Hengyi LI, Shuting SHI, Ferdian THUNG, Xuan HUO, et al.. "DeepReview: Automatic code review using deep multi-instance learning" Advances in knowledge discovery and data mining: 23rd Pacific-Asia Conference, PAKDD 2019, Macau, China, April 14-17: Proceedings Vol. 11440 (2019) p. 318 - 330
Available at: http://works.bepress.com/david_lo/236/