Is a Single Model Enough? MuCoS: A Multi-Model Ensemble Learning for Semantic Code Search

Lun Du, Xiaozhou Shi, Yanlin Wang, Ensheng Shi, Shi Han +1 more
7/10/2021
cs.SEcs.LG

Official code: Xzh0u/MuCoS (10 stars, Python, MIT, last commit 2021-08-25).

Abstract

Recently, deep learning methods have become mainstream in code search since they do better at capturing semantic correlations between code snippets and search queries and have promising performance. However, code snippets have diverse information from different dimensions, such as business logic, specific algorithm, and hardware communication, so it is hard for a single code representation module to cover all the perspectives.

Show full abstract

On the other hand, as a specific query may focus on one or several perspectives, it is difficult for a single query representation module to represent different user intents. In this paper, we propose MuCoS, a multi-model ensemble learning architecture for semantic code search. It combines several individual learners, each of which emphasizes a specific perspective of code snippets. We train the individual learners on different datasets which contain different perspectives of code information, and we use a data augmentation strategy to get these different datasets. Then we ensemble the learners to capture comprehensive features of code snippets.

View on arXivView PDF

Code Implementations(1)

Xzh0u/MuCoSOfficial100%
MIT

Code for MuCoS (paper accepted by CIKM2021)

101PythonJan 18, 20215 years agoMIT
code-searchdeep-learningensemble-learning

Similar Papers

Cite this paper

@article{du2021single,
  title  = {Is a Single Model Enough? MuCoS: A Multi-Model Ensemble Learning for Semantic Code Search},
  author = {Lun Du and Xiaozhou Shi and Yanlin Wang and Ensheng Shi and Shi Han and Dongmei Zhang},
  year   = {2021},
  eprint = {2107.04773},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2107.04773}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2107.04773.svg)](https://codeofpaper.com/paper/2107.04773)

Discussion