Downloads · 30 days
98
2% of all-time downloads
microsoft/reacc-py-retriever
reacc-py-retriever is a feature extraction model from microsoft. Use it when you need embeddings to search or compare text. It is set up for transformers. The card lists the license as mit.
This is the retrieval model for ReACC: A Retrieval-Augmented Code Completion Framework.
Downloads · 30 days
98
2% of all-time downloads
All-time downloads
5.3K
Public
Repo size
993 MB
Likes
4
Public
Click a slice to open those files.
.bin496 MB · 100%
From the Hugging Face model README
This is the retrieval model for ReACC: A Retrieval-Augmented Code Completion Framework.
In this paper, the model is used to retrieve similar codes given an incompletion code snippet as query. The model can be also used for incomplete code-to-code search, code clone detection.
py-retriever is BERT-like encoder consisting of 12 transformer layers. It is continual pre-trained on GraphCodeBERT with contrastive learning in Python programming language. More details can be found in our paper.
Note that the format of input codes is different from original source code. We normalize the source codes to better capture information from line break and indention in Python. An example of input is:
sum = 0<endofline>for val in numbers:<endofline><INDENT>sum = sum+val
To get more information about how to convert source codes into this format, please refer to ReACC GitHub repo.