inference4j/gte-base
By inference4j · ↓ 0 · ♥ 0 · Updated 2026-03-02
What's in this repo
This page lists the files in inference4j/gte-base, including model.onnx.
- 1 ONNX models (.onnx files)
- 4 files, including 1 .md, 1 .onnx, 1 .txt
- Last updated 2026-03-02
ONNX files
| File | Size | Download |
|---|---|---|
| model.onnx | — | Download |
How to use
These ONNX files can be loaded with ONNX Runtime. To inspect a model graph, upload the file to the Netron viewer. Download links point to the original files on Hugging Face.
README
GTE Base — ONNX
ONNX export of thenlper/gte-base, an English embedding model from Alibaba. Maps sentences to 768-dimensional dense vectors using CLS pooling with L2 normalization.
Mirrored for use with inference4j, an inference-only AI library for Java.
Original Source
- Repository: thenlper/Alibaba (ONNX by Xenova)
- License: mit
Usage with inference4j
try (SentenceTransformerEmbedder model = SentenceTransformerEmbedder.builder()
.modelId("inference4j/gte-base")
.poolingStrategy(PoolingStrategy.CLS)
.normalize()
.build()) {
float[] embedding = model.encode("Hello, world!");
System.out.println("Dimension: " + embedding.length); // 768
}
Model Details
| Property | Value |
|---|---|
| Architecture | BERT Base (12 layers, 768 hidden) |
| Task | Sentence embeddings / semantic similarity |
| Output dimension | 768 |
| Pooling | CLS |
| Normalization | L2 |
| Max sequence length | 512 |
| Original framework | PyTorch (HuggingFace Transformers) |
License
This model is licensed under the MIT License. Original model by thenlper/Alibaba, ONNX export by Xenova.
Model info
Created: 2026-03-02
Updated: 2026-03-02
View on Hugging Face