michael-guenther
commited on
Commit
•
cf2e535
1
Parent(s):
7597002
Update README.md
Browse files
README.md
CHANGED
@@ -2732,7 +2732,7 @@ from sentence_transformers import SentenceTransformer
|
|
2732 |
from sentence_transformers.util import cos_sim
|
2733 |
|
2734 |
model = SentenceTransformer(
|
2735 |
-
"jinaai/jina-embeddings-v2-base-
|
2736 |
trust_remote_code=True
|
2737 |
)
|
2738 |
|
@@ -2741,7 +2741,7 @@ model.max_seq_length = 1024
|
|
2741 |
|
2742 |
embeddings = model.encode([
|
2743 |
'How is the weather today?',
|
2744 |
-
'
|
2745 |
])
|
2746 |
print(cos_sim(embeddings[0], embeddings[1]))
|
2747 |
```
|
|
|
2732 |
from sentence_transformers.util import cos_sim
|
2733 |
|
2734 |
model = SentenceTransformer(
|
2735 |
+
"jinaai/jina-embeddings-v2-base-en", # switch to en/zh for English or Chinese
|
2736 |
trust_remote_code=True
|
2737 |
)
|
2738 |
|
|
|
2741 |
|
2742 |
embeddings = model.encode([
|
2743 |
'How is the weather today?',
|
2744 |
+
'What is the current weather like today?'
|
2745 |
])
|
2746 |
print(cos_sim(embeddings[0], embeddings[1]))
|
2747 |
```
|