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 Nov
16:00 - 16:20 Talk | Predicting Licenses for Changed Source Code Xiaoyu LiuDepartment of Computer Science and Engineering, Southern Methodist University, Liguo HuangDept. of Computer Science, Southern Methodist University, Dallas, TX, 75205, Jidong GeState Key Laboratory for Novel Software and Technology, Nanjing University, Vincent NgHuman Language Technology Research Institute, University of Texas at Dallas, Richardson, TX 75083-0688 | |||||||||||||||||||||||||||||||||||||||||
16:20 - 16:40 Talk | Empirical evaluation of the impact of class overlap on software defect prediction Lina GongChina University of Mining and Technology, Shujuan JiangChina University of Mining and Technology, Rongcun WangChina University of Mining and Technology, Li JiangChina University of Mining and Technology | |||||||||||||||||||||||||||||||||||||||||
16:40 - 17:00 Talk | Combining Program Analysis and Statistical Language Model for Code Statement Completion Son NguyenThe University of Texas at Dallas, Tien N. NguyenUniversity of Texas at Dallas, Yi LiNew Jersey Institute of Technology, USA, Shaohua WangNew Jersey Institute of Technology, USA | |||||||||||||||||||||||||||||||||||||||||
17:00 - 17:20 Talk | Balancing the trade-off between accuracy and interpretability in software defect prediction Toshiki MoriCorporate Software Engineering & Technology Center, Toshiba Corporation, Naoshi UchihiraSchool of Knowledge Science, Japan Advanced Institute of Science and Technology (JAIST) Link to publication File Attached | |||||||||||||||||||||||||||||||||||||||||
17:20 - 17:40 Talk | Fine-grained just-in-time defect prediction Luca PascarellaDelft University of Technology, Fabio PalombaDepartment of Informatics, University of Zurich, Alberto BacchelliUniversity of Zurich Link to publication |