Upload all-MiniLM-L6-v2 ONNX model
Browse files- README.md +46 -0
- model.onnx +3 -0
- vocab.txt +0 -0
README.md
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
library_name: onnx
|
| 3 |
+
tags:
|
| 4 |
+
- sentence-transformers
|
| 5 |
+
- sentence-similarity
|
| 6 |
+
- feature-extraction
|
| 7 |
+
- onnx
|
| 8 |
+
- inference4j
|
| 9 |
+
license: apache-2.0
|
| 10 |
+
pipeline_tag: sentence-similarity
|
| 11 |
+
---
|
| 12 |
+
|
| 13 |
+
# all-MiniLM-L6-v2 — ONNX
|
| 14 |
+
|
| 15 |
+
ONNX export of [all-MiniLM-L6-v2](https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2), a sentence-transformers model that maps sentences to a 384-dimensional dense vector space. Fine-tuned on a 1B+ sentence pairs dataset using a self-supervised contrastive learning objective.
|
| 16 |
+
|
| 17 |
+
Mirrored for use with [inference4j](https://github.com/inference4j/inference4j), an inference-only AI library for Java.
|
| 18 |
+
|
| 19 |
+
## Original Source
|
| 20 |
+
|
| 21 |
+
- **Repository:** [sentence-transformers](https://huggingface.co/sentence-transformers/all-MiniLM-L6-v2)
|
| 22 |
+
- **License:** apache-2.0
|
| 23 |
+
|
| 24 |
+
## Usage with inference4j
|
| 25 |
+
|
| 26 |
+
```java
|
| 27 |
+
try (SentenceTransformer model = SentenceTransformer.fromPretrained("models/all-MiniLM-L6-v2")) {
|
| 28 |
+
float[] embedding = model.encode("Hello, world!");
|
| 29 |
+
System.out.println("Dimension: " + embedding.length); // 384
|
| 30 |
+
}
|
| 31 |
+
```
|
| 32 |
+
|
| 33 |
+
## Model Details
|
| 34 |
+
|
| 35 |
+
| Property | Value |
|
| 36 |
+
|----------|-------|
|
| 37 |
+
| Architecture | MiniLM-L6 (6 layers, 384 hidden) |
|
| 38 |
+
| Task | Sentence embeddings / semantic similarity |
|
| 39 |
+
| Output dimension | 384 |
|
| 40 |
+
| Max sequence length | 256 |
|
| 41 |
+
| Training data | 1B+ sentence pairs |
|
| 42 |
+
| Original framework | PyTorch (sentence-transformers) |
|
| 43 |
+
|
| 44 |
+
## License
|
| 45 |
+
|
| 46 |
+
This model is licensed under the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0). Original model by [sentence-transformers](https://huggingface.co/sentence-transformers).
|
model.onnx
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:6fd5d72fe4589f189f8ebc006442dbb529bb7ce38f8082112682524616046452
|
| 3 |
+
size 90405214
|
vocab.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|