Update README.md
Browse files
README.md
CHANGED
@@ -33,7 +33,7 @@ Then you can use the model like this:
|
|
33 |
from sentence_transformers import SentenceTransformer
|
34 |
sentences = ["こんにちは、世界!", "文埋め込み最高!文埋め込み最高と叫びなさい", "極度乾燥しなさい"]
|
35 |
|
36 |
-
model = SentenceTransformer("unsup-simcse-ja-base")
|
37 |
embeddings = model.encode(sentences)
|
38 |
print(embeddings)
|
39 |
```
|
@@ -56,8 +56,8 @@ def cls_pooling(model_output, attention_mask):
|
|
56 |
sentences = ['This is an example sentence', 'Each sentence is converted']
|
57 |
|
58 |
# Load model from HuggingFace Hub
|
59 |
-
tokenizer = AutoTokenizer.from_pretrained("unsup-simcse-ja-base")
|
60 |
-
model = AutoModel.from_pretrained("unsup-simcse-ja-base")
|
61 |
|
62 |
# Tokenize sentences
|
63 |
encoded_input = tokenizer(sentences, padding=True, truncation=True, return_tensors='pt')
|
|
|
33 |
from sentence_transformers import SentenceTransformer
|
34 |
sentences = ["こんにちは、世界!", "文埋め込み最高!文埋め込み最高と叫びなさい", "極度乾燥しなさい"]
|
35 |
|
36 |
+
model = SentenceTransformer("cl-nagoya/unsup-simcse-ja-base")
|
37 |
embeddings = model.encode(sentences)
|
38 |
print(embeddings)
|
39 |
```
|
|
|
56 |
sentences = ['This is an example sentence', 'Each sentence is converted']
|
57 |
|
58 |
# Load model from HuggingFace Hub
|
59 |
+
tokenizer = AutoTokenizer.from_pretrained("cl-nagoya/unsup-simcse-ja-base")
|
60 |
+
model = AutoModel.from_pretrained("cl-nagoya/unsup-simcse-ja-base")
|
61 |
|
62 |
# Tokenize sentences
|
63 |
encoded_input = tokenizer(sentences, padding=True, truncation=True, return_tensors='pt')
|