Blog

Introducing EmbeddingNandi

Open long-context embedding models for English, Indic and Southeast Asian languages. Two sizes: 150M with a 16K window and 450M with a 32K window, with vectors you can cut down to 128 dimensions.

EmbeddingNandi 150M and 450M: one embedding vector cut to 1024, 768, 512, 256 and 128 dimensions
One EmbeddingNandi vector, cut to 1,024, 768, 512, 256 or 128 dimensions by keeping its first values.

An encoder becomes a search engine once it learns to turn a whole passage into one vector. EmbeddingNandi is that step for NandiBERT: sentence-embedding models for semantic search, retrieval-augmented generation, clustering, deduplication and similarity, in English, 13 Indic languages, romanized Indic text such as Hinglish, Arabic, Indonesian and Malay.

We are releasing two sizes with open weights under Apache 2.0. EmbeddingNandi-150M reads 16,384 tokens and puts out 768-dimensional vectors. EmbeddingNandi-450M reads 32,768 tokens and puts out 1,024-dimensional vectors. Both are trained with Matryoshka Representation Learning, so the same vector can be shortened to 512, 256 or 128 dimensions when storage and speed matter more than the last fraction of a point.

On the benchmarks we report, EmbeddingNandi-450M has the best average across MTEB English, Code and Indic, and leads Code and Indic outright. EmbeddingNandi-150M leads Code and Indic in its class. This post covers how they were built, how to use them, and what Matryoshka truncation costs.

Overview

One Embedding Model, Many Languages

Both models are fine-tuned from the NandiBERT bidirectional encoders, so they inherit its 100K-token multilingual vocabulary, its grouped-query attention and its long context. One model serves queries and documents across every language the encoder covers, including queries and documents in different languages or scripts.

2sizes

146M and 445M parameters, open weights under Apache 2.0

32Kcontext

16,384 tokens for 150M, 32,768 for 450M

128min. dims

Matryoshka sizes down to 128, from 768 or 1,024

16languages

English, 13 Indic, Arabic, Indonesian and Malay

SpecEmbeddingNandi-150MEmbeddingNandi-450M
Base modelNandiBERT-150MNandiBERT-450M
Parameters146M445M
Layers / hidden size28 / 76828 / 1,024
AttentionGrouped-query: 6 query heads, 2 key-value headsGrouped-query: 8 query heads, 2 key-value heads
Embedding dimension768 (Matryoshka: 512, 256, 128)1,024 (Matryoshka: 768, 512, 256, 128)
PoolingMean over all tokens, task prompt includedMean over all tokens, task prompt included
SimilarityCosine on L2-normalized outputCosine on L2-normalized output
Max sequence length16,384 tokens32,768 tokens
Vocabulary100,352 tokens100,352 tokens
Weightsbfloat16bfloat16
LicenseApache 2.0Apache 2.0

Source: the EmbeddingNandi-150M and EmbeddingNandi-450M model cards. Indic languages: Assamese, Bengali, Gujarati, Hindi, Kannada, Malayalam, Marathi, Nepali, Odia, Punjabi, Tamil, Telugu and Urdu.

Training

From Encoder to Embedding Model

A masked-language-model encoder produces contextual representations for each token, but it is not inherently trained to make one vector represent an entire passage for similarity search. Contrastive training adapts it for this: matching texts are brought closer together in the embedding space, while non-matching texts are distinguished from them. We train in three stages on top of the NandiBERT checkpoint.

Stage 1

Weak pairs, huge batches

Weakly supervised pairs are treated as matches based on indirect signals or automatically assigned labels, rather than carefully verified labels for every pair. This makes it possible to collect data at scale, but some pairs may be noisy. We train with batches of 16,384, giving each example a large pool of in-batch negatives.

Stage 2

Curated pairs

We then use a more carefully selected or filtered set of text pairs. Compared with weakly supervised pairs, these examples are intended to provide more reliable matching signals and help refine what the model treats as a match. Curated does not necessarily mean every pair was manually annotated.

Stage 3

Labelled fine-tuning

Retrieval, code, classification, clustering, similarity and bitext data in English and Indic languages, with up to three mined hard negatives per query.

Details That Matter

  • Similarity data uses CoSENT loss, which teaches the model to rank more similar text pairs above less similar ones, rather than predicting an exact similarity score for each pair.
  • A Matryoshka loss is applied at every supported size: 768, 512, 256 and 128 for the 150M model, and 1,024, 768, 512, 256 and 128 for the 450M model.
  • The 450M model is also trained on documents up to 32K tokens, so its long window is used in training and not only at inference.
  • The released 450M weights are an equal average of two fine-tuning runs.
  • The output is the mean over all tokens, task prompt included, then L2 normalization, compared with cosine similarity.

Prompts

Task Prompts Steer the Embedding

EmbeddingNandi is trained with short task prompts in the EmbeddingGemma format, added in front of the text. The prompts are saved inside the model, so you pass a prompt name and Sentence Transformers adds the text. Using the right one gives the best quality.

There are two kinds of tasks. For asymmetric tasks such as search, queries and documents get different prompts. For symmetric tasks such as classification and similarity, every text gets the same prompt.

Task prompts
Use caseTypePrompt nameQuery promptDocument prompt
Web / document searchAsymmetricSearchQuerytask: search result | query: {query}title: none | text: {content}
Code searchAsymmetricCodeRetrievaltask: code retrieval | query: {query}title: none | text: {code}
Text classificationSymmetricClassificationtask: classification | query: {content}Same prompt for every text
ClusteringSymmetricClusteringtask: clustering | query: {content}Same prompt for every text
Sentence similaritySymmetricSentenceSimilaritytask: sentence similarity | query: {content}Same prompt for every text

encode_query uses the SearchQuery prompt and encode_document uses the Document prompt. The model also holds prompts keyed by MTEB task type, such as Retrieval-query, STS and BitextMining; model.prompts lists them all.

Matryoshka

Matryoshka Dimension Truncation

A normal embedding is all or nothing: you use every dimension, whether the task needs it or not. Matryoshka Representation Learning trains the model so that shorter prefixes of an embedding remain useful on their own. For example, a 1,024-dimensional embedding can be shortened to 512, 256 or 128 dimensions by keeping only its first values. Think of Russian nesting dolls: each smaller representation is contained within the larger one. You do not need to train a separate model for each size.

To make this work, the training loss is applied at each of these sizes at the same time. The early dimensions are pushed to carry the most general meaning, and the later dimensions add finer detail. That is why quality falls gradually as the vector is cut, as the chart below shows.

The supported sizes are the ones the model was trained with: 768, 512, 256 and 128 for EmbeddingNandi-150M, and 1,024, 768, 512, 256 and 128 for EmbeddingNandi-450M. Shorter vectors use less storage and make search faster, at some cost in quality.

What Truncation Costs

We measured EmbeddingNandi-450M at every size on a 28-task subset of the three benchmarks: 13 English, 6 Code and 9 Indic tasks.

Quality Kept at Each Matryoshka Size, EmbeddingNandi-450M

90%92%94%96%98%100%1,024 dimensions · 100% storage100.0%768 dimensions · 75% storage99.8%512 dimensions · 50% storage99.4%256 dimensions · 25% storage98.8%128 dimensions · 12.5% storage97.0%
Average score on the 28-task subset as a share of the 1,024-dimension average. The axis runs from 90% to 100%, so differences read clearly; the full table is below.

Quality Against Embedding Dimension

96%97%98%99%100%128256512768102497.0%98.8%99.4%99.8%100%Embedding dimensionQuality kept (% of 1,024-dim)

Share of the 1,024-dimension quality kept at each Matryoshka size. The axis starts at 96%.

Matryoshka truncation, EmbeddingNandi-450M
DimensionStorageMTEB(eng, v2)MTEB(Code, v1)MTEB(Indic, v1)AverageChange vs 1024
1024100%67.4173.7380.2973.810.00
76875%67.2373.5680.0973.63-0.18
51250%66.9973.2079.8973.36-0.45
25625%66.8072.6079.3372.91-0.90
12812.5%65.8670.8978.0571.60-2.21

28-task subset (13 English, 6 Code and 9 Indic tasks), bfloat16, inputs up to 1,024 tokens, vectors re-normalized after truncation. These scores come from a subset and a shorter input length, so they are not comparable to the full benchmark numbers later in this post.

Halving the vector costs 0.45 points on average, and cutting it to a quarter costs 0.90. Even at 128 dimensions, one eighth of the storage, the model keeps 97% of its 1,024-dimension average.

What It Means for Storage

At float32, a million 1,024-dimensional vectors take about 4.1 GB. The same million at 256 dimensions take about 1.0 GB, and at 128 dimensions about 0.5 GB. For the 150M model, 768 dimensions is about 3.1 GB per million. Smaller vectors also mean faster nearest-neighbor search and less memory for the index, which is where most of the cost of a retrieval system lives.

Two Rules for Truncating

Why re-normalize? The full embedding is L2-normalized, so its length is 1. Truncation removes some values and usually changes that length. If you then compare truncated vectors with a dot product, their lengths affect the score as well as their directions. Re-normalizing the shortened vectors brings their lengths back to 1, making the dot product equivalent to cosine similarity. Cosine similarity itself already accounts for vector length, so re-normalization is not mathematically required when you use cosine similarity directly. In our checks, using dot product on truncated vectors without re-normalizing reduced scores by 0.5 to 2 points.

  • Re-normalize after truncating. Normalize the shortened query and document vectors before storing them or comparing them with a dot product.
  • Queries and documents must use the same size. If your document index uses 256-dimensional vectors, encode queries at 256 dimensions too. The vectors must have matching dimensions and use the same model and compatible embedding setup.

Pass truncate_dim and normalize_embeddings=True and Sentence Transformers does both for you:

query_embs = model.encode_query(queries, truncate_dim=256, normalize_embeddings=True)
doc_embs = model.encode_document(documents, truncate_dim=256, normalize_embeddings=True)
print(query_embs.shape)   # (3, 256)

Or set the size once when loading the model. The vectors are then cut after the model's own normalization step, so they are no longer unit length. Pass normalize_embeddings=True when you store them or compare them with a dot product; model.similarity uses cosine, so its scores are not affected.

model_256 = SentenceTransformer(
    "FrontiersMind/EmbeddingNandi-450M", trust_remote_code=True, truncate_dim=256
)
query_embs = model_256.encode_query(queries, normalize_embeddings=True)

Long Context

Whole Documents in One Embedding

A contract, a court judgment or a research paper rarely fits in 512 tokens, and cutting it into chunks loses the context that ties it together. EmbeddingNandi-150M embeds up to 16,384 tokens in one pass and EmbeddingNandi-450M embeds up to 32,768, so a full document can become a single vector.

150M

16,384 tokens

Long documents without chunking, from a compact 146M-parameter model that is fast to serve.

450M

32,768 tokens

Full contracts, reports and papers in one pass, with grouped-query attention keeping memory low on long inputs.

Texts longer than model.max_seq_length are truncated. Long inputs need more memory and time, so for short texts or limited memory you can lower the limit:

model.max_seq_length = 1024   # default is 16384 (150M) or 32768 (450M)

Benchmarks

Strongest on Indic and Code

We report mean task scores on three MTEB suites: MTEB(eng, v2) with 41 tasks, MTEB(Code, v1) with 12 tasks and MTEB(Indic, v1) with 20 tasks. All numbers come from the open-source MTEB library, version 2.26.19, at each model's maximum input length.

The 450M Class

We re-evaluated every model in this comparison ourselves with the same code, each with its official MTEB loader settings and documented maximum input length. EmbeddingNandi-450M was run with float32 compute, except Touche2020, which used bfloat16.

Average of Three Benchmarks, 450M Class

4050607080EmbeddingNandi-450M74.2EmbeddingGemma 271.4Qwen3-Embedding-0.6B69.7pplx-embed-v1-0.6b67.0harrier-oss-v1-270m66.0multilingual-e5-large-instruct64.6LFM2.5-Embedding-350M46.5
Mean of MTEB(eng, v2), MTEB(Code, v1) and MTEB(Indic, v1).
Three MTEB benchmarks, 450M class
ModelParamsMTEB(eng, v2)MTEB(Code, v1)MTEB(Indic, v1)Average (all three)
EmbeddingNandi-450M445M67.6178.4276.6274.22
EmbeddingGemma 2271M67.5378.2768.3971.40
Qwen3-Embedding-0.6B596M70.0974.8864.1069.69
pplx-embed-v1-0.6b596M62.0175.2163.8367.02
harrier-oss-v1-270m268M67.1962.9867.9966.05
multilingual-e5-large-instruct560M65.7458.4969.6464.62
LFM2.5-Embedding-350M354M60.3344.2734.9446.51

Average is the mean of the three benchmark scores. Best score in each column is in bold. Qwen3-Embedding-0.6B, pplx-embed-v1-0.6b and multilingual-e5-large-instruct are larger models, at 596M, 596M and 560M parameters.

EmbeddingNandi-450M has the highest average, 74.22, ahead of EmbeddingGemma 2 at 71.40 and Qwen3-Embedding-0.6B at 69.69. It leads Code at 78.42 and Indic at 76.62, where it is 8.2 points ahead of EmbeddingGemma 2. In English it scores 67.61, level with EmbeddingGemma 2 at 67.53 and behind Qwen3-Embedding-0.6B at 70.09, which is a larger model.

MTEB(Indic, v1), 450M Class

304050607080EmbeddingNandi-450M76.6multilingual-e5-large-instruct69.6EmbeddingGemma 268.4harrier-oss-v1-270m68.0Qwen3-Embedding-0.6B64.1pplx-embed-v1-0.6b63.8LFM2.5-Embedding-350M34.9
Mean over 20 Indic tasks. harrier-oss-v1-270m shown here as in the main table.

MTEB(Code, v1), 450M Class

304050607080EmbeddingNandi-450M78.4EmbeddingGemma 278.3pplx-embed-v1-0.6b75.2Qwen3-Embedding-0.6B74.9harrier-oss-v1-270m63.0multilingual-e5-large-instruct58.5LFM2.5-Embedding-350M44.3
Mean over 12 code tasks.
MTEB(Indic, v1) by task type
MTEB(Indic, v1) by task type, 450M class
ModelMean (20)Bitext Mining (2)Classification (12)Clustering (1)Pair Classification (1)Reranking (1)Retrieval (2)STS (1)
EmbeddingNandi-450M76.6288.8573.6658.6485.1987.0390.8958.04
EmbeddingGemma 268.3962.8870.4631.6575.1485.3483.8436.81
LFM2.5-Embedding-350M34.943.7347.103.5351.8445.6716.11-7.06
Qwen3-Embedding-0.6B64.1067.1862.7140.3775.8583.8678.2538.57
pplx-embed-v1-0.6b63.8368.6062.9126.5664.3486.3083.5440.22
harrier-oss-v1-270m67.9977.8465.9147.3977.5483.0576.9951.19
harrier-oss-v1-0.6b70.6480.3268.5951.4579.5082.4881.2353.26
multilingual-e5-large-instruct69.6480.2566.6251.4174.5485.8984.5151.94
MTEB(eng, v2) by task type
MTEB(eng, v2) by task type, 450M class
ModelMean (41)Classification (8)Clustering (8)Pair Classification (3)Reranking (2)Retrieval (10)STS (9)Summarization (1)
EmbeddingNandi-450M67.6189.4453.5583.4847.7152.2981.4426.20
EmbeddingGemma 267.5388.8251.7386.3945.9651.3582.7435.02
LFM2.5-Embedding-350M60.3369.9440.9380.4445.1854.4276.2324.41
Qwen3-Embedding-0.6B70.0985.6053.9685.3347.3359.5586.4532.89
pplx-embed-v1-0.6b62.0169.2236.0682.8046.9359.9680.7132.00
harrier-oss-v1-270m67.1985.7453.5880.8945.6153.2182.9128.21
multilingual-e5-large-instruct65.7475.2851.6586.2046.5353.6584.5630.59
MTEB(Code, v1) by task
MTEB(Code, v1) by task, 450M class
ModelMean (12)AppsCodeEdit SearchCodeFeedback MTCodeFeedback STCSN-CCCodeSearchNetTransOcean ContestTransOcean DLCosQACOIR CSNStackOverflow QAText2SQL
EmbeddingNandi-450M78.4280.9780.8994.9888.7292.1589.4285.8736.3643.1185.8492.9869.76
EmbeddingGemma 278.2789.2780.5088.2382.1596.6490.7883.6736.3651.4086.8987.3865.96
LFM2.5-Embedding-350M44.276.7946.4331.8769.5335.2672.4856.9022.3329.1437.9481.6040.95
Qwen3-Embedding-0.6B74.8875.9463.3790.4286.5085.0789.9586.2133.2340.6584.1989.2373.85
pplx-embed-v1-0.6b75.2179.0376.3685.5884.7088.0889.8086.3536.8343.6082.3890.6959.12
harrier-oss-v1-270m62.9817.8053.3589.1381.7749.5482.7581.0536.1034.9275.4289.0864.79
multilingual-e5-large-instruct58.4929.3154.8140.6575.7357.8685.2974.7331.0936.3662.3391.1162.56

The 150M Class

EmbeddingNandi-150M was evaluated at its maximum input length of 16,384 tokens with float32 compute. Scores for the other models are published MTEB results, except the MTEB(Indic, v1) scores of granite-embedding-125m-english, which we ran ourselves with the same MTEB version at 512 tokens in float32.

Average of Three Benchmarks, 150M Class

4050607080EmbeddingNandi-150M72.0harrier-oss-v1-270m66.7bekko-embedding-v1-a25m62.6UltraBERT-Embed-150M60.90multilingual-e5-small58.5granite-embedding-english-r250.97granite-embedding-125m-english49.95
Mean of the three benchmarks for every model in the 150M comparison.

Average Against Parameters

4050607080100200300400500600700EmbeddingNandi-450MEmbeddingNandi-150MEmbeddingGemma 2Qwen3-Embedding-0.6Bpplx-embed-v1-0.6bmultilingual-e5-large-instructLFM2.5-Embedding-350Mbekko-embedding-v1-a25mmultilingual-e5-smallgranite-embedding-125m-englishUltraBERT-Embed-150Mgranite-embedding-english-r2Parameters (millions)Average of three benchmarks

Average of the three benchmarks against model parameters, for models with all three scores. Orange points are EmbeddingNandi.

Three MTEB benchmarks, models up to about 270M parameters
ModelParamsMTEB(eng, v2)MTEB(Code, v1)MTEB(Indic, v1)Average (all three)
EmbeddingNandi-150M146M65.8575.8074.3371.99
UltraBERT-Embed-150M151M67.2473.3042.1660.90
granite-embedding-english-r2149M62.8457.2232.8550.97
granite-embedding-125m-english125M62.1053.3034.4649.95
bekko-embedding-v1-a25m123M62.2560.2765.4362.65
multilingual-e5-small118M59.6953.5362.1558.46
harrier-oss-v1-270m268M67.1962.9869.8166.66

EmbeddingNandi-150M leads Code at 75.80 and Indic at 74.33, and its average of 71.99 is the highest of any model that has all three scores, ahead of harrier-oss-v1-270m at 66.66, which has nearly twice the parameters. In English it scores 65.85, behind UltraBERT-Embed-150M at 67.24 and harrier-oss-v1-270m at 67.19, and ahead of the granite, bekko and multilingual-e5-small models.

MTEB(Code, v1), 150M Class

304050607080EmbeddingNandi-150M75.8UltraBERT-Embed-150M73.3harrier-oss-v1-270m63.0bekko-embedding-v1-a25m60.3granite-embedding-english-r257.2multilingual-e5-small53.5granite-embedding-125m-english53.3
Mean over 12 code tasks, for models that report a Code mean.
MTEB(Indic, v1) by task type
MTEB(Indic, v1) by task type, 150M class
ModelMean (20)Bitext Mining (2)Classification (12)Clustering (1)Pair Classification (1)Reranking (1)Retrieval (2)STS (1)
EmbeddingNandi-150M74.3384.3672.1954.3282.5786.0787.4053.95
granite-embedding-125m-english34.465.5444.683.0451.7549.2317.942.07
bekko-embedding-v1-a25m65.4375.2564.4527.8369.6483.6676.9649.63
multilingual-e5-small62.1573.3867.0026.3973.3272.2076.8245.93
harrier-oss-v1-270m69.8181.5470.8452.5180.1261.9066.3875.35
MTEB(eng, v2) by task type
MTEB(eng, v2) by task type, 150M class
ModelMean (41)Classification (8)Clustering (8)Pair Classification (3)Reranking (2)Retrieval (10)STS (9)Summarization (1)
EmbeddingNandi-150M65.8587.7850.5482.4346.5249.7581.1524.95
UltraBERT-Embed-150M67.2481.7449.7085.3347.5057.2083.0334.89
granite-embedding-english-r262.8470.7147.2079.3449.1056.4378.1229.31
granite-embedding-125m-english62.1068.3047.3079.6049.4055.7077.6029.30
bekko-embedding-v1-a25m62.2574.7044.6483.5745.6049.7480.6832.34
multilingual-e5-small59.6970.6941.3684.0943.1946.4379.8429.22
harrier-oss-v1-270m67.1985.7453.5880.8945.6153.2182.9128.21
MTEB(Code, v1) by task
MTEB(Code, v1) by task, 150M class
ModelMean (12)AppsCodeEdit SearchCodeFeedback MTCodeFeedback STCSN-CCCodeSearchNetTransOcean ContestTransOcean DLCosQACOIR CSNStackOverflow QAText2SQL
EmbeddingNandi-150M75.8070.6577.5793.8487.5188.4088.5483.1035.6940.1384.4491.5168.20
UltraBERT-Embed-150M73.3068.5062.2184.3786.4093.7390.0388.0837.2336.2982.2392.4358.05
granite-embedding-english-r257.2213.9659.3552.5477.1847.6780.7977.0735.0337.0164.6591.8049.55
granite-embedding-125m-english53.3011.8058.8042.1075.3047.6076.9066.7029.6036.6055.1089.8048.70
harrier-oss-v1-270m62.9817.8053.3589.1381.7749.5482.7581.0536.1034.9275.4289.0864.79

Run

Run It Yourself

The architecture is custom, so loading needs trust_remote_code=True. Install Sentence Transformers 6.1.0 or newer with Transformers 5.20.2 or newer (the versions we tested):

pip install -U "sentence-transformers>=6.1.0" "transformers>=5.20.2"

For search, encode_query and encode_document add the right prompts for you. Queries and documents can be in English, an Indic script or romanized text, in any mix.

from sentence_transformers import SentenceTransformer

# use "FrontiersMind/EmbeddingNandi-150M" for the 150M model
model = SentenceTransformer("FrontiersMind/EmbeddingNandi-450M", trust_remote_code=True)

queries = [
    "What causes the northern lights?",
    "फ्रांस की राजधानी क्या है?",
    "phone ki battery jaldi khatam kyun hoti hai",
]
documents = [
    "The northern lights are caused by charged particles from the sun hitting the Earth's atmosphere.",
    "पेरिस फ्रांस की राजधानी और सबसे बड़ा शहर है।",
    "Phone batteries drain quickly when many apps run in the background and the screen is very bright.",
    "The Amazon is the largest rainforest in the world.",
]

query_embs = model.encode_query(queries)
doc_embs = model.encode_document(documents)
print(query_embs.shape, doc_embs.shape)   # (3, 1024) (4, 1024)
print(model.similarity(query_embs, doc_embs))

This is the similarity matrix EmbeddingNandi-450M produces for those inputs. Each query finds its own answer, whether the query is English, Hindi or Hinglish.

Cosine similarity between three queries and four documents, EmbeddingNandi-450M
QueryNorthern lights (English)पेरिस फ्रांस की राजधानी… (Hindi)Phone batteries drain… (English)The Amazon rainforest (English)
What causes the northern lights?0.7560.0960.1740.184
फ्रांस की राजधानी क्या है?0.1360.8080.0360.229
phone ki battery jaldi khatam kyun hoti hai0.1870.0740.6000.001

Code Search and Similarity

For code search, encode the queries with CodeRetrieval and the code with Document:

code_queries = ["reverse a string in python"]
code_docs = ["def reverse(s):\n    return s[::-1]", "def add(a, b):\n    return a + b"]

q = model.encode(code_queries, prompt_name="CodeRetrieval")
d = model.encode(code_docs, prompt_name="Document")
print(model.similarity(q, d))

For a symmetric task, use the same prompt for every text. Here the Hinglish sentence lands next to its English meaning (0.75 on the 450M model) and far from the unrelated one (0.03):

texts = ["This phone is really good", "Yeh phone bahut accha hai", "My order was delivered late"]
embs = model.encode(texts, prompt_name="SentenceSimilarity")
print(model.similarity(embs, embs))

Numerical Precision

Run inference in bfloat16 or float32; the weights are stored in bfloat16. Use float32 on CPU, where it runs faster, and for long inputs: 4K tokens or more for the 150M model, 16K tokens or more for the 450M model. On GPU, bfloat16 uses much less memory.

import torch

dtype = torch.bfloat16 if torch.cuda.is_bf16_supported() else torch.float32
model = SentenceTransformer(
    "FrontiersMind/EmbeddingNandi-450M",
    trust_remote_code=True,
    model_kwargs={"dtype": dtype},
)
Use it with plain Transformers
import torch
import torch.nn.functional as F
from transformers import AutoModel, AutoTokenizer

model_id = "FrontiersMind/EmbeddingNandi-450M"
device = "cuda" if torch.cuda.is_available() else "cpu"
tokenizer = AutoTokenizer.from_pretrained(model_id, trust_remote_code=True)
model = AutoModel.from_pretrained(model_id, trust_remote_code=True).to(device).eval()

QUERY_PROMPT = "task: search result | query: "
DOCUMENT_PROMPT = "title: none | text: "

def embed(texts, prompt, max_length=32768, dim=None):
    inputs = tokenizer([prompt + t for t in texts], padding=True, truncation=True,
                       max_length=max_length, return_tensors="pt").to(device)
    with torch.no_grad():
        hidden = model(**inputs).last_hidden_state
    # mean pooling over all tokens, prompt tokens included
    mask = inputs["attention_mask"].unsqueeze(-1).to(hidden.dtype)
    emb = (hidden * mask).sum(dim=1) / mask.sum(dim=1).clamp(min=1e-9)
    if dim is not None:          # Matryoshka: keep the first `dim` values
        emb = emb[:, :dim]
    return F.normalize(emb.float(), dim=-1)

scores = embed(queries, QUERY_PROMPT) @ embed(documents, DOCUMENT_PROMPT).T

This gives the same embeddings as Sentence Transformers, up to tiny bfloat16 rounding differences.

Family

The EmbeddingNandi Family

Both models are on Hugging Face with open weights.

Embedding

EmbeddingNandi-150M

146M parameters, 768 dimensions and a 16K window, for fast multilingual retrieval and low-cost serving.

Embedding

EmbeddingNandi-450M

445M parameters, 1,024 dimensions and a 32K window, for long documents and the strongest Indic and Code results.

Fit

Where EmbeddingNandi Fits

Reach for EmbeddingNandi-150M when latency, memory and serving cost matter: high-volume search, deduplication and clustering on hardware you own. Reach for EmbeddingNandi-450M when documents are long or Indic and code retrieval quality matter most. Either way, pick a Matryoshka size to fit your index: start at full size, then step down until quality starts to slip on your own data.

Use the task prompts, because the models are trained with them. And only the sizes listed above are supported for truncation, so pick one of them.

The Takeaway

EmbeddingNandi is one embedding model for English, Indic, Bahasa Indonesia, Malay and Arabic. It leads on Indic and Code, embeds whole documents up to 32K tokens, and gives you one vector you can shrink to 128 dimensions with a small, measured cost. The weights are open for you to run on your own infrastructure. That is where Sovereign Superintelligence starts.