EmbeddingGemma 2: An open, lightweight multimodal embedding model
TL;DR Highlight
One open 740M model embeds text, images, audio and video into a single shared vector space
Who Should Read
Backend or app developers building on-device or self-hosted RAG who need to search images, audio and video as well as text
Core Mechanics
- Text, images, audio and video share one space
- EmbeddingGemma 2 maps code, images, video and audio into a shared embedding space.
- It is built on the Gemma 4 architecture and released under Apache 2.0.
- It has 740M parameters in total.
- Load only the encoders you need
- Text-only workloads need as little as 270M parameters.
- Vision (170M) and audio (300M) encoders are optional add-ons.
- MRL cuts vector storage up to 6x
- Matryoshka Representation Learning (MRL, training so the first part of a vector still works when truncated) lets you cut 768 dims to 512, 256 or 128.
- Local vector DB storage and memory drop by up to 6x.
- Code retrieval score up 9.92 points
- On MTEB Code it went from 68.76 to 78.68 versus EmbeddingGemma 1.
- Multilingual text performance is said to match EmbeddingGemma.
Community Reactions
- Apache 2.0 matters for embedding models, one commenter argued
- Proprietary hosted models can be retired, forcing you to re-embed millions of stored vectors.
- The commenter prefers paying a host while keeping open weights as a fallback.
- Text-only users may see no gain, per commenters
- One commenter noted the text benchmarks are identical to the first EmbeddingGemma.
- Another tested with Claude and found it neither better nor faster for text retrieval or clustering.
- They said MuQ-MuLan still seems better for music audio.
- MRL doesn't shrink the model weights, one commenter pointed out
- Unlike earlier on-device MatFormers models, only the dimensions shrink, not the weights.
- Commenters wanted more comparisons
- Some asked for comparisons with Voyage AI for text and SigLIP2 for images.
- One said they found Voyage models better than Qwen ones.
How to Apply
- Compare the text-only path on your existing corpus
- Today, load the 270M text path with sentence-transformers and run the same 20 queries you use now.
- If your service is text-only, check first whether there is any gain.
- Shrink vectors with MRL dimensions
- Index 256 or 128 dims instead of 768 in your vector DB and measure the quality change.
- Rebuild the index at the smallest dimension that stays acceptable.
- Try it on codebase search
- Plug it into your coding agent's code retrieval and compare hit rate against your current model.
- Add encoders only where you need them
- Add the audio (300M) or vision (170M) encoder if you need voice memo or video search.
- Otherwise keep text-only to save memory.
Try It
# Run in terminal (the source only says sentence-transformers is supported; check and replace the model ID below)
pip install -U sentence-transformers
# Save as a Python file and run
from sentence_transformers import SentenceTransformer
MODEL_ID = "{{EmbeddingGemma 2 model ID on Hugging Face}}"
model = SentenceTransformer(MODEL_ID, truncate_dim=256) # MRL: 768 -> 256 dims
docs = ["{{doc1}}", "{{doc2}}", "{{doc3}}"]
query = "{{question}}"
d = model.encode(docs, normalize_embeddings=True)
q = model.encode([query], normalize_embeddings=True)
print(q @ d.T)
# Next: change truncate_dim to 512, 256, 128 and see how the ranking shiftsTerminology
Related Papers
You could have invented transformers from memory
Viewing linear, MLP and attention layers as memory stores: capacity goes ~64 to ~2,700 to over a million
Pointing AI at archives found a forgotten meteorite, lost rhinos, and more
Embedding search plus a cheap filter model surfaced unrecorded events in 400 years of archives
RAG-NAROK: Retrieval-Aware Knowledge Corpus Poisoning in RAG with Source-specific Refutation
Refutation documents targeting retrieved sources took top rank and evaded anomaly detectors up to 88.37%.
Text, Pixels, or Both? Evaluating Input Representations for Multimodal Document QA
Page images beat OCR text on accuracy but cost more; a question-only router cut latency 30%.
Microsoft exec called AI scraping 'the largest theft of labor in human history'
NYT lawsuit unredacted filings reveal Microsoft and OpenAI internal views on scraping
Harnessing the Universal Geometry of Embeddings
Translating embeddings between models without paired data exposes vector database security risks