Instructions to use sjiang1/codecse with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use sjiang1/codecse with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("feature-extraction", model="sjiang1/codecse")# Load model directly from transformers import GraphCodeBERTForCL model = GraphCodeBERTForCL.from_pretrained("sjiang1/codecse", dtype="auto") - Notebooks
- Google Colab
- Kaggle
Add "feature extraction" as our pipeline
Browse files
README.md
CHANGED
|
@@ -1,12 +1,13 @@
|
|
| 1 |
---
|
| 2 |
-
language:
|
| 3 |
-
|
| 4 |
tags:
|
| 5 |
- code
|
| 6 |
- sentence embedding
|
| 7 |
-
license:
|
| 8 |
datasets:
|
| 9 |
- CodeSearchNet
|
|
|
|
| 10 |
---
|
| 11 |
|
| 12 |
# Model Card for CodeCSE
|
|
@@ -36,4 +37,4 @@ batch = prepare_inputs(nl_json, tokenizer, args)
|
|
| 36 |
nl_inputs = batch[3]
|
| 37 |
with torch.no_grad():
|
| 38 |
nl_vec = model(input_ids=nl_inputs, sent_emb="nl")[1]
|
| 39 |
-
```
|
|
|
|
| 1 |
---
|
| 2 |
+
language:
|
| 3 |
+
- multilingual
|
| 4 |
tags:
|
| 5 |
- code
|
| 6 |
- sentence embedding
|
| 7 |
+
license: mit
|
| 8 |
datasets:
|
| 9 |
- CodeSearchNet
|
| 10 |
+
pipeline_tag: feature-extraction
|
| 11 |
---
|
| 12 |
|
| 13 |
# Model Card for CodeCSE
|
|
|
|
| 37 |
nl_inputs = batch[3]
|
| 38 |
with torch.no_grad():
|
| 39 |
nl_vec = model(input_ids=nl_inputs, sent_emb="nl")[1]
|
| 40 |
+
```
|