Combining Program Analysis and Statistical Language Model for Code Statement Completion
Automatic code completion helps improve developers’ productivity in their programming tasks. A program contains instructions expressed via code statements, which are considered as the basic units of program execution. In this paper, we introduce AutoSC, which combines program analysis and the principle of software naturalness to fill in partially completed statements. AutoSC benefits from the strengths of both directions, in which the completed code statement is both frequent and valid. AutoSC is first trained on a large code corpus to learn the templates of candidate statements. Then, it uses program analysis to validate and concretize the templates into syntactically and type-valid candidate statements. Finally, these candidates are ranked by using a language model trained on the lexical form of the source code in the code corpus. Our empirical evaluation shows that AutoSC achieves 38.9–41.3% top-1 and 48.2-50.1% top-5 accuracy in statement completion and outperforms the state-of-the-art approach from 9X–69X in top-1 accuracy.
Wed 13 NovDisplayed time zone: Tijuana, Baja California change
16:00 - 17:40 | PredictionResearch Papers / Journal First Presentations at Cortez 1 Chair(s): Xin Xia Monash University | ||
16:00 20mTalk | Predicting Licenses for Changed Source Code Research Papers Xiaoyu Liu Department of Computer Science and Engineering, Southern Methodist University, Liguo Huang Dept. of Computer Science, Southern Methodist University, Dallas, TX, 75205, Jidong Ge State Key Laboratory for Novel Software and Technology, Nanjing University, Vincent Ng Human Language Technology Research Institute, University of Texas at Dallas, Richardson, TX 75083-0688 | ||
16:20 20mTalk | Empirical evaluation of the impact of class overlap on software defect prediction Research Papers Lina Gong China University of Mining and Technology, Shujuan Jiang China University of Mining and Technology, Rongcun Wang China University of Mining and Technology, Li Jiang China University of Mining and Technology | ||
16:40 20mTalk | Combining Program Analysis and Statistical Language Model for Code Statement Completion Research Papers Son Nguyen The University of Texas at Dallas, Tien N. Nguyen University of Texas at Dallas, Yi Li New Jersey Institute of Technology, USA, Shaohua Wang New Jersey Institute of Technology, USA | ||
17:00 20mTalk | Balancing the trade-off between accuracy and interpretability in software defect prediction Journal First Presentations Toshiki Mori Corporate Software Engineering & Technology Center, Toshiba Corporation, Naoshi Uchihira School of Knowledge Science, Japan Advanced Institute of Science and Technology (JAIST) Link to publication File Attached | ||
17:20 20mTalk | Fine-grained just-in-time defect prediction Journal First Presentations Luca Pascarella Delft University of Technology, Fabio Palomba Department of Informatics, University of Zurich, Alberto Bacchelli University of Zurich Link to publication |