BGE-M3
BGE-M3 is an open-weights embedding model from the Beijing Academy of Artificial Intelligence (BAAI), described in the paper BGE M3-Embedding (February 2024). Its name stands for multi-functionality, multi-linguality and multi-granularity: one model that produces dense, sparse and multi-vector (ColBERT-style) representations, supports more than 100 working languages, and accepts inputs up to 8192 tokens. The weights are published on the BAAI/bge-m3 Hugging Face card under the MIT license.
Key Features
- Three retrieval modes in one model: dense retrieval, sparse retrieval (lexical weights) and multi-vector retrieval, which can be combined for hybrid search.
- Multilingual: according to the model card, it supports more than 100 working languages.
- Long inputs: up to 8192 tokens per input, with a 1024-dimensional dense embedding.
- No query instruction needed: unlike earlier BGE models, queries do not need an instruction prefix.
- MIT license: weights can be used commercially and self-hosted.
The card evaluates the model on MIRACL (multilingual retrieval), MKQA (cross-lingual retrieval) and MLDR and NarrativeQA (long-document retrieval). Results are shown as charts, so this page does not quote individual scores.
Use Cases
- Multilingual semantic search and retrieval-augmented generation (RAG) pipelines.
- Hybrid retrieval that mixes dense and sparse signals, which the card recommends together with a re-ranker.
- Long-document retrieval where 512-token embedders truncate too much.
Limitation: BGE-M3 is a 2024 model. Newer embedders exist, so run it on your own corpus before choosing it.
Pricing
The weights are free under the MIT license. There is no official hosted API listed on the model card, so you pay only for your own compute, or for whatever third-party host you pick. Pricing from third-party hosts is not covered here.
Getting Started
- Install the library:
pip install -U FlagEmbedding, then loadBGEM3FlagModel("BAAI/bge-m3")to get dense, sparse and multi-vector output. - Or load it with Sentence Transformers:
SentenceTransformer("BAAI/bge-m3")for dense embeddings only. - For hybrid retrieval, combine dense and sparse scores, then re-rank the top results. See BGE Reranker v2.5 Gemma2 Lightweight for a BAAI reranker.
Frequently Asked Questions
What embedding size and input length does BGE-M3 support?
The Hugging Face card lists a 1024-dimensional embedding and a maximum input of 8192 tokens.
Is BGE-M3 free for commercial use?
The card lists the MIT license, so the weights can be used commercially.
Does BGE-M3 need an instruction prefix for queries?
No. The card states that queries no longer need an instruction, unlike earlier BGE models.
Can I use BGE-M3 for hybrid search?
Yes. It outputs dense, sparse and multi-vector representations from one model, and the card recommends hybrid retrieval plus re-ranking.
Alternatives
- text-embedding-3-large: OpenAI's hosted embedding model with 3072 default dimensions.
- Qwen3 Embedding: an open multilingual embedding family from Alibaba's Qwen team.
- Jina Embeddings v4: Jina AI's multilingual embedding model.
Conclusion
BGE-M3 remains a practical open choice when you need multilingual, long-input embeddings with dense, sparse and multi-vector output under an MIT license. Start from the Hugging Face card and the paper, and compare it with a newer embedder on your own data.
Sources
Comments
No comments yet. Be the first to comment!