Searching code in a large-scale codebase using natural language queries is a common practice during software development. Deep learning-based code search methods demonstrate superior performance if models are trained with large amount of text-code pairs. However, few deep code search models can be easily transferred from one codebase to another. It can be very costly to prepare training data for a new codebase and re-train an appropriate deep learning model. In this paper, we propose AdaCS, an adaptive deep code search method that can be trained once and transferred to new codebases. AdaCS decomposes the learning process into embedding domain-specific words and matching general syntactic patterns. Firstly, an unsupervised word embedding technique is used to construct a matching matrix to represent the lexical similarities. Then, a recurrent neural network is used to capture latent syntactic patterns from these matching matrices in a supervised way. As the supervised task learns general syntactic patterns that exist across domains, AdaCS is transferable to new codebases. Experimental results show that: when extended to new software projects never seen in the training data, AdaCS is more robust and significantly outperforms state-of-the-art deep code search methods.
Wed 15 JulDisplayed time zone: (UTC) Coordinated Universal Time change
08:30 - 09:30 | |||
08:30 20mPaper | GGF: A Graph-based Method for Programming Language Syntax Error Correction Research Liwei Wu Nanjing University, Fei Li Nanjing University, Youhua Wu Nanjing University, Tao Zheng Nanjing University Media Attached | ||
08:50 20mPaper | Adaptive Deep Code Search Research ChunYang Ling Peking University, Zeqi Lin Peking University, Yanzhen Zou Peking University, Bing Xie Peking University Pre-print Media Attached | ||
09:10 20mPaper | Duplicate Bug Report Detection Using Dual-Channel Convolutional Neural Networks Research Jianjun He School of Big Data & Software Engineering, Chongqing University, Ling Xu School of Big Data & Software Engineering, Chongqing University, Meng Yan School of Big Data & Software Engineering, Chongqing University, Xin Xia Monash University, Yan Lei School of Big Data & Software Engineering, Chongqing University Media Attached |