Update README.md
Browse files
README.md
CHANGED
@@ -3,4 +3,25 @@ license: apache-2.0
|
|
3 |
pipeline_tag: sentence-similarity
|
4 |
---
|
5 |
|
6 |
-
ONNX port of [BAAI/bge-large-en-v1.5](https://huggingface.co/BAAI/bge-large-en-v1.5) text classification and similarity searches.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
pipeline_tag: sentence-similarity
|
4 |
---
|
5 |
|
6 |
+
Quantized ONNX port of [BAAI/bge-large-en-v1.5](https://huggingface.co/BAAI/bge-large-en-v1.5) text classification and similarity searches.
|
7 |
+
|
8 |
+
### Usage
|
9 |
+
|
10 |
+
Here's an example of performing inference using the model with [FastEmbed](https://github.com/qdrant/fastembed).
|
11 |
+
|
12 |
+
```py
|
13 |
+
from fastembed import TextEmbedding
|
14 |
+
|
15 |
+
documents = [
|
16 |
+
"You should stay, study and sprint.",
|
17 |
+
"History can only prepare us to be surprised yet again.",
|
18 |
+
]
|
19 |
+
|
20 |
+
model = TextEmbedding(model_name="BAAI/bge-large-en-v1.5")
|
21 |
+
embeddings = list(model.embed(documents))
|
22 |
+
|
23 |
+
# [
|
24 |
+
# array([1.96449570e-02, 1.60677675e-02, 4.10149433e-02...]),
|
25 |
+
# array([-1.56669170e-02, -1.66313536e-02, -6.84525725e-03...])
|
26 |
+
# ]
|
27 |
+
```
|