michaelfeil
commited on
Commit
•
88dbdd2
1
Parent(s):
7fc0678
Update README.md
Browse files
README.md
CHANGED
@@ -4716,6 +4716,15 @@ print(scores.tolist())
|
|
4716 |
# [[0.301699697971344, 0.7503870129585266, 0.32030850648880005]]
|
4717 |
```
|
4718 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
4719 |
### Use with custom code to get dense embeddigns and sparse token weights
|
4720 |
```python
|
4721 |
# You can find the script gte_embedding.py in https://huggingface.co/Alibaba-NLP/gte-multilingual-base/blob/main/scripts/gte_embedding.py
|
|
|
4716 |
# [[0.301699697971344, 0.7503870129585266, 0.32030850648880005]]
|
4717 |
```
|
4718 |
|
4719 |
+
### Use with infinity
|
4720 |
+
|
4721 |
+
Usage via docker and [infinity](https://github.com/michaelfeil/infinity), MIT Licensed.
|
4722 |
+
```
|
4723 |
+
docker run --gpus all -v $PWD/data:/app/.cache -p "7997":"7997" \
|
4724 |
+
michaelf34/infinity:0.0.69 \
|
4725 |
+
v2 --model-id Alibaba-NLP/gte-multilingual-base --revision "main" --dtype float16 --batch-size 32 --device cuda --engine torch --port 7997
|
4726 |
+
```
|
4727 |
+
|
4728 |
### Use with custom code to get dense embeddigns and sparse token weights
|
4729 |
```python
|
4730 |
# You can find the script gte_embedding.py in https://huggingface.co/Alibaba-NLP/gte-multilingual-base/blob/main/scripts/gte_embedding.py
|