ONNX Model Zoo

lmo3/multilingual-e5-large-instruct

By lmo3 · ↓ 3 · ♥ 0 · Updated 2026-02-11

What's in this repo

This page lists the files in lmo3/multilingual-e5-large-instruct, including model.onnx, model_fp16.onnx, model_quantized.onnx.

  • 3 ONNX models (.onnx files)
  • 15 files, including 8 .json, 3 .onnx, 1 .md, 1 .onnx_data, 1 .model
  • Last updated 2026-02-11

ONNX files

File Size Download
onnx/model.onnx — Download
onnx/model_fp16.onnx — Download
onnx/model_quantized.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

multilingual-e5-large-instruct (ONNX)

ONNX export of intfloat/multilingual-e5-large-instruct with fp16 and int8 quantized variants.

Compatible with both @huggingface/transformers (JavaScript) and sentence-transformers (Python).

Available Models

File Format Size Description
onnx/model.onnx + model.onnx_data fp32 2.1 GB Full precision, external data format
onnx/model_fp16.onnx fp16 1.0 GB Half precision, negligible quality loss
onnx/model_quantized.onnx int8 535 MB Dynamic quantization, smallest size

Usage with Transformers.js

import { pipeline } from "@huggingface/transformers";

const extractor = await pipeline(
  "feature-extraction",
  "lmo3/multilingual-e5-large-instruct",
  { dtype: "fp16" } // or "q8" for int8, omit for fp32
);

// Queries use the instruct format
const query = "Instruct: Retrieve semantically similar text.\nQuery: How is the weather today?";
const queryEmbedding = await extractor(query, { pooling: "mean", normalize: true });

// Documents are embedded as-is (no prefix)
const docEmbedding = await extractor("It is sunny outside", { pooling: "mean", normalize: true });

Usage with sentence-transformers (Python)

from sentence_transformers import SentenceTransformer

model = SentenceTransformer("lmo3/multilingual-e5-large-instruct")

# Queries use the instruct format
queries = ["Instruct: Retrieve semantically similar text.\nQuery: How is the weather today?"]
docs = ["It is sunny outside"]

query_embeddings = model.encode(queries)
doc_embeddings = model.encode(docs)

Key Differences from Base E5

This is the instruct variant of multilingual-e5-large. The key difference:

  • Queries must be prefixed with Instruct: <task description>\nQuery:
  • Documents are embedded as-is, with no prefix

The instruction tells the model what retrieval task you're performing, improving embedding quality. See the original model card for task-specific instructions and benchmark results.

Export Details

  • Exported via Optimum with ONNX opset 18
  • fp16 quantized via onnxruntime.transformers.optimizer
  • int8 quantized via onnxruntime.quantization.quantize_dynamic
  • config.json patched with transformers.js_config for automatic external data handling

Original Model

This is a conversion of intfloat/multilingual-e5-large-instruct:

  • Architecture: XLM-RoBERTa Large (24 layers, 1024 hidden, 16 heads)
  • Embedding dimension: 1024
  • Languages: 100+ languages
  • License: MIT

Model info

feature-extraction transformers.js
transformers.js onnx xlm-roberta feature-extraction sentence-transformers sentence-similarity mteb e5 multilingual base_model:intfloat/multilingual-e5-large-instruct base_model:quantized:intfloat/multilingual-e5-large-instruct license:mit
↓ 3 ♥ 0

Created: 2026-02-11

Updated: 2026-02-11

View on Hugging Face

Files (15)

.gitattributes
1_Pooling/config.json
README.md
config.json
config_sentence_transformers.json
modules.json
onnx/model.onnx ONNX
onnx/model.onnx_data
onnx/model_fp16.onnx ONNX
onnx/model_quantized.onnx ONNX
sentence_xlm-roberta_config.json
sentencepiece.bpe.model
special_tokens_map.json
tokenizer.json
tokenizer_config.json

Related models