/ Модель

Характеристики

Контекст
32 768 токенов
Параметры
495 млн
Лицензия
Apache 2.0
Архитектура
nandi_encoder · dense
Базовая модель
NandiBERT-450M
Библиотека
sentence-transformers
Опубликована
19 ноя 2026

EmbeddingNandi-450M

ЭмбеддингиТекст → embedding10 профессий

Многоязычная модель FrontiersMind для создания текстовых эмбеддингов и семантического поиска по длинным документам.

101скачиваний за 30 дней5лайковвеса обновлены27 ноя 2026

Бенчмарки

Как модель справилась с задачами пользователей ailist и что о ней публикуют открытые лидерборды

Публичные оценки

Из открытых лидербордов. Сравнивайте результаты одного теста при одинаковых условиях — отсутствие оценки не значит, что модель хуже.

В подключённых источниках результатов для этой модели пока нет.

Что умеет модель

Описание составлено по карточке модели и метаданным Hugging Face

EmbeddingNandi-450M — модель плотных текстовых эмбеддингов от FrontiersMind, дообученная на двунаправленном энкодере NandiBERT-450M. Она предназначена для семантического поиска, извлечения документов для RAG, кластеризации и оценки сходства текстов на английском, индийских языках, арабском, индонезийском и малайском; базовый энкодер также поддерживает романизированные индийские тексты, например Hinglish.

Модель содержит около 445 млн параметров, имеет 28 слоёв, размер скрытого состояния 1 024 и контекст до 32 768 токенов. Она выдаёт 1 024-мерные L2-нормализованные векторы с усреднением представлений токенов; благодаря обучению Matryoshka вектор можно сокращать до 768, 512, 256 или 128 измерений. Для настройки представлений под поиск, классификацию, кластеризацию и сходство используются короткие task prompts.

Модель рассчитана на сценарии поиска и сопоставления текстов, включая длинные документы и многоязычные коллекции; поддерживается загрузка через Sentence Transformers и Transformers. README приводит результаты оценки на наборах MTEB для английского, кода и индийских языков, но эти результаты зависят от условий тестирования. Лицензия — Apache-2.0.

Сценарии применения

  • семантический поиск по многоязычной коллекции документов
  • подбор источников для RAG
  • сравнение сходства запросов и документов
  • кластеризация текстов
  • поиск дубликатов и близких текстов
  • поиск по длинным контрактам, отчётам и научным статьям

Ограничения

Векторные представления зависят от корректно выбранного task prompt; сокращение размерности экономит память и ускоряет поиск, но может снизить качество. По README, в тесте MTEB для английской суммаризации модель уступала EmbeddingGemma 2.

Для каких профессий подходит10

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Также подходит для

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

EmbeddingNandi-450M

EmbeddingNandi is a family of open, long-context embedding models for English, Indic, Arabic and Southeast Asian languages, built on the NandiBERT bidirectional encoders. They turn text in English, Indic languages and other widely used languages into dense vectors for semantic search, retrieval-augmented generation, clustering and similarity.

ModelParametersHiddenContextBase encoderDescription
EmbeddingNandi-150M150M76816KNandiBERT-150MCompact long-context embedding model
EmbeddingNandi-450M (this model)450M1,02432KNandiBERT-450MLong-context embedding model

Description

  • One Model. From English to Indic and Beyond: Built on NandiBERT-450M, which covers English, 13 Indic languages in native script, romanized Indic text such as Hinglish, and Arabic, Indonesian and Malay, so a single embedding model serves queries and documents across these languages.
  • 32K context: A 32,768-token window, so full contracts, reports and papers can be embedded in a single pass without chunking, with the 100K-token multilingual vocabulary shared across the NandiBERT family.
  • Deep, with efficient attention: Inherited from NandiBERT-450M: 28 layers at 1,024 hidden size, with QK-norm and SwiGLU. Grouped-query attention with 8 query heads and 2 key-value heads keeps memory low on long inputs. The 100K-token vocabulary is stored as a rank-512 factorized embedding.
  • Embedding output: 1,024-dimensional vectors. Mean pooling over all tokens (task prompt included), then L2 normalization, compared with cosine similarity. Trained with Matryoshka Representation Learning, so vectors can be cut to 768, 512, 256 or 128 dimensions.
  • Task prompts: Short task prompts in the EmbeddingGemma format (for example task: search result | query: ) steer the embedding for search, code search, classification, clustering and similarity.
  • Built for retrieval: A drop-in encoder for semantic search, retrieval-augmented generation, clustering, deduplication and similarity scoring, loadable with Sentence Transformers and Hugging Face transformers.

Benchmark Results

Mean task scores on MTEB(eng, v2) (41 tasks), MTEB(Code, v1) (12 tasks) and MTEB(Indic, v1) (20 tasks). We re-evaluated every model in this table ourselves with the same code, the open-source MTEB library (version 2.26.19), each with its official mteb loader settings and its documented maximum input length: 32,768 tokens for EmbeddingNandi-450M, Qwen3, harrier and pplx, 8,192 for EmbeddingGemma 2, and 512 for multilingual-e5 and LFM2.5. EmbeddingNandi-450M was evaluated with float32 compute (Touche2020 with bfloat16). Average is the mean of the three benchmark scores. Best score in each column is in bold.

ModelMTEB(eng, v2)MTEB(Code, v1)MTEB(Indic, v1)Average (all three)
EmbeddingNandi-450M (445M)67.6178.4276.6274.22
EmbeddingGemma 2 (271M)67.5378.2768.3971.40
LFM2.5-Embedding-350M (354M)60.3344.2734.9446.51
Qwen3-Embedding-0.6B (596M)70.0974.8864.1069.69
pplx-embed-v1-0.6b (596M)62.0175.2163.8367.02
harrier-oss-v1-270m (268M)67.1962.9867.9966.05
multilingual-e5-large-instruct (560M)65.7458.4969.6464.62
ModelMean (20)Bitext Mining (2)Classification (12)Clustering (1)Pair Classification (1)Reranking (1)Retrieval (2)STS (1)
EmbeddingNandi-450M (445M)76.6288.8573.6658.6485.1987.0390.8958.04
EmbeddingGemma 2 (271M)68.3962.8870.4631.6575.1485.3483.8436.81
LFM2.5-Embedding-350M (354M)34.943.7347.103.5351.8445.6716.11-7.06
Qwen3-Embedding-0.6B (596M)64.1067.1862.7140.3775.8583.8678.2538.57
pplx-embed-v1-0.6b (596M)63.8368.6062.9126.5664.3486.3083.5440.22
harrier-oss-v1-270m (268M)67.9977.8465.9147.3977.5483.0576.9951.19
harrier-oss-v1-0.6b (596M)70.6480.3268.5951.4579.5082.4881.2353.26
multilingual-e5-large-instruct (560M)69.6480.2566.6251.4174.5485.8984.5151.94
ModelMean (41)Classification (8)Clustering (8)Pair Classification (3)Reranking (2)Retrieval (10)STS (9)Summarization (1)
EmbeddingNandi-450M (445M)67.6189.4453.5583.4847.7152.2981.4426.20
EmbeddingGemma 2 (271M)67.5388.8251.7386.3945.9651.3582.7435.02
LFM2.5-Embedding-350M (354M)60.3369.9440.9380.4445.1854.4276.2324.41
Qwen3-Embedding-0.6B (596M)70.0985.6053.9685.3347.3359.5586.4532.89
pplx-embed-v1-0.6b (596M)62.0169.2236.0682.8046.9359.9680.7132.00
harrier-oss-v1-270m (268M)67.1985.7453.5880.8945.6153.2182.9128.21
multilingual-e5-large-instruct (560M)65.7475.2851.6586.2046.5353.6584.5630.59
ModelMean (12)AppsRetrievalCodeEditSearchRetrievalCodeFeedbackMTCodeFeedbackSTCodeSearchNetCCRetrievalCodeSearchNetRetrievalCodeTransOceanContestCodeTransOceanDLCosQACOIRCodeSearchNetRetrievalStackOverflowQASyntheticText2SQL
EmbeddingNandi-450M (445M)78.4280.9780.8994.9888.7292.1589.4285.8736.3643.1185.8492.9869.76
EmbeddingGemma 2 (271M)78.2789.2780.5088.2382.1596.6490.7883.6736.3651.4086.8987.3865.96
LFM2.5-Embedding-350M (354M)44.276.7946.4331.8769.5335.2672.4856.9022.3329.1437.9481.6040.95
Qwen3-Embedding-0.6B (596M)74.8875.9463.3790.4286.5085.0789.9586.2133.2340.6584.1989.2373.85
pplx-embed-v1-0.6b (596M)75.2179.0376.3685.5884.7088.0889.8086.3536.8343.6082.3890.6959.12
harrier-oss-v1-270m (268M)62.9817.8053.3589.1381.7749.5482.7581.0536.1034.9275.4289.0864.79
multilingual-e5-large-instruct (560M)58.4929.3154.8140.6575.7357.8685.2974.7331.0936.3662.3391.1162.56

Quick Start

Install Sentence Transformers (tested with sentence-transformers 6.1.0 and transformers 5.20.2):

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

The model uses custom code, so pass trust_remote_code=True. For search, encode_query and encode_document add the query and document prompts for you. Queries and documents can be in English, an Indic script or romanized text, in any mix:

from sentence_transformers import SentenceTransformer

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))
# tensor([[0.7564, 0.0961, 0.1738, 0.1838],
#         [0.1359, 0.8079, 0.0362, 0.2289],
#         [0.1872, 0.0741, 0.5996, 0.0011]])

Best Practices

1. Task Prompts

EmbeddingNandi-450M is trained with short task prompts added in front of the text. The prompts are saved in the model, so you only pass prompt_name and Sentence Transformers adds the prompt text. Using the right prompt gives the best quality.

There are two kinds of tasks:

  • Asymmetric tasks (for example search): use the query prompt for queries and the document prompt for the texts being searched.
  • Symmetric tasks (for example classification, similarity): use the same prompt for all texts being compared.
Use CaseTask TypePrompt NameQuery PromptDocument Prompt (prompt_name="Document")
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}N/A
ClusteringSymmetricClusteringtask: clustering | query: {content}N/A
Sentence similaritySymmetricSentenceSimilaritytask: sentence similarity | query: {content}N/A

Pass the prompt name to encode. 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))
# tensor([[0.5554, 0.2409]])

For a symmetric task, use the same prompt for every text:

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))
# tensor([[1.0000, 0.7536, 0.2031],
#         [0.7536, 1.0000, 0.0294],
#         [0.2031, 0.0294, 1.0000]])

encode_query uses the query prompt (same text as SearchQuery) and encode_document uses the document prompt (same text as Document). The model also holds prompts keyed by MTEB task type (for example Retrieval-query, Retrieval-document, STS, BitextMining), so MTEB picks the right prompt for each task. model.prompts lists all of them.

2. Matryoshka Dimension Truncation

EmbeddingNandi-450M is trained with Matryoshka Representation Learning, so the 1,024-dimensional vector can be shortened by keeping only its first values. The supported sizes are 1024, 768, 512, 256 and 128 (the sizes the model was trained with; use one of these). Shorter vectors use less storage and make search faster, at some cost in quality.

Scores at each size on a 28-task subset of the three benchmarks (13 English, 6 Code and 9 Indic tasks; bfloat16, inputs up to 1,024 tokens, vectors re-normalized after truncation):

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
  • Re-normalize after truncating when using dot product: truncation changes the vector's norm. Re-normalizing the shortened vectors makes the dot product equivalent to cosine similarity. If you use cosine similarity directly, explicit re-normalization is not necessary.
  • Queries and documents must use the same size.

Pass truncate_dim and normalize_embeddings=True to let Sentence Transformers do both:

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 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)
print(query_embs.shape)
# (3, 256)

3. Long Inputs

The model takes inputs of up to 32,768 tokens, and model.max_seq_length is 32768 by default, so long documents are embedded whole. Texts longer than model.max_seq_length tokens are truncated. Longer inputs need more memory and time, so for short texts or limited memory you can lower the limit:

model.max_seq_length = 1024

4. Numerical Precision

Run inference in bfloat16 or float32. The weights are stored in bfloat16. Use float32 on CPU and for very long inputs (16K tokens or more).

import torch

if torch.cuda.is_available():
    dtype = torch.bfloat16 if torch.cuda.is_bf16_supported(including_emulation=False) else torch.float16
else:
    dtype = torch.float32

model = SentenceTransformer(
    "FrontiersMind/EmbeddingNandi-450M",
    trust_remote_code=True,
    model_kwargs={"dtype": dtype},
)

Usage with Transformers

EmbeddingNandi-450M also loads with Hugging Face transformers using trust_remote_code=True for both the tokenizer and the model. Add the task prompt in front of each text, take the mean over all tokens (prompt tokens included) and L2 normalize. This gives the same embeddings as Sentence Transformers, up to tiny bfloat16 rounding differences.

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 + text for text 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)


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.",
]

scores = embed(queries, QUERY_PROMPT) @ embed(documents, DOCUMENT_PROMPT).T  # cosine similarity
print(scores)
# tensor([[0.7565, 0.0961, 0.1738, 0.1837],
#         [0.1358, 0.8079, 0.0361, 0.2288],
#         [0.1873, 0.0740, 0.5995, 0.0010]])

Model Description

Base modelNandiBERT-450M
Parameters445M
Layers / hidden size28 / 1,024
AttentionGrouped-query, 8 query heads and 2 key-value heads
Embedding dimension1,024 (Matryoshka: 768, 512, 256, 128)
PoolingMean over all tokens, task prompt included
SimilarityCosine (L2-normalized output)
Max sequence length32,768 tokens
Vocabulary100,352 tokens
Weightsbfloat16
Prompt formattask: {task} | query: {text} for queries and symmetric tasks, title: none | text: {text} for documents
LanguagesEnglish; 13 Indic languages in native script (Assamese, Bengali, Gujarati, Hindi, Kannada, Malayalam, Marathi, Nepali, Odia, Punjabi, Tamil, Telugu, Urdu) and romanized Indic text such as Hinglish; Arabic, Indonesian, Malay
LicenseApache 2.0

Citation

@misc{frontiersmind2026embeddingnandi,
  title        = {EmbeddingNandi: Open Long-Context Embedding Models for English, Indic and Southeast Asian Languages},
  author       = {{FrontiersMind}},
  year         = {2026},
  howpublished = {\url{https://huggingface.co/FrontiersMind/EmbeddingNandi-450M}}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · sentence-transformers

Нельзя запустить

Модели нужен код из репозитория; запуск откроется после проверки совместимости.

Класс архитектуры
NandiEncoderModel
Ревизия весов
93a4a23

0 моделей