alt.freeweights.embed / harrier-oss-v1-27b
From: microsoft <huggingface.co/microsoft>Newsgroups: alt.freeweights.embedSubject:

harrier-oss-v1-27b

Date: 2026-11-15Commit: 0c0fc62Signed: 2DC28CC7B26A283B ✓

Feature extraction model with 27B parameters. Safetensors weights, 54.1 GB in all. Published by microsoft under MIT.

27B params54.1GBharrier-oss-v1-27bsafetensorspermissive
FactsParams27BSize54.1 GBFormatssafetensorsTaskfeature extractionLicenseMITFrom sourcepermissive
$ fw get microsoft/harrier-oss-v1-27b
# manifest sha256 5d33d400f53e… · 54.1 GB · 22 files
$ fw verify ./harrier-oss-v1-27b microsoft/harrier-oss-v1-27b
From sourceHosted (signed)microsoft/harrier-oss-v1-27bLast check: 2026-11-15 02:47 UTC

Get help: custom fine-tune or private deploy. We review your setup before we quote.

Works with

Evaluate with

Overview

Size
54.1 GB
Weights
54.0 GB (safetensors)
Parameters
27B
Formats
safetensors
Task
feature extraction
License
MIT (permissive)
Files
22, each with a sha256
Publisher
microsoft
Added
2026-11-15
Section
alt.freeweights.embed
Lineage

Original release from the publisher.

Where these bytes come from
Publisher at the pinned commit→You

Sources are tried in order. A file counts only when its size and sha256 match the manifest. Sources are checked when you ask for them, not on a timer.

Sources
BadgeHostLast checkResult
From sourcehuggingface.co2026-11-15 02:47 UTCpassed

Model card

From the publisher at commit 0c0fc62. Shown as plain text with links; images open at the publisher.

harrier-oss-v1#

harrier-oss-v1 is a family of multilingual text embedding models developed by Microsoft. The models use decoder-only architectures with last-token pooling and L2 normalization to produce dense text embeddings. They can be applied to a wide range of tasks, including but not limited to retrieval, clustering, semantic similarity, classification, bitext mining, and reranking. The models achieve state-of-the-art results on the Multilingual MTEB v2 benchmark as of the release date.

ModelParametersEmbedding DimensionMax TokensMTEB v2 Score
harrier-oss-v1-270m270M64032,76866.5
harrier-oss-v1-0.6b0.6B1,02432,76869.0
harrier-oss-v1-27b27B5,37632,76874.3

Training#

All models are trained with contrastive learning objectives on a large-scale mixture of multilingual datasets covering diverse tasks. The 270m and 0.6b variants are additionally trained with knowledge distillation from larger embedding models.

Usage#

Below is an example to encode queries and passages from the MS-MARCO passage ranking dataset.

Sentence Transformers#
from sentence_transformers import SentenceTransformer

model = SentenceTransformer("microsoft/harrier-oss-v1-27b", model_kwargs={"dtype": "auto"})

queries = [
    "how much protein should a female eat",
    "summit define",
]
documents = [
    "As a general guideline, the CDC's average requirement of protein for women ages 19 to 70 is 46 grams per day. But, as you can see from this chart, you'll need to increase that if you're expecting or training for a marathon. Check out the chart below to see how much protein you should be eating each day.",
    "Definition of summit for English Language Learners. : 1  the highest point of a mountain : the top of a mountain. : 2  the highest level. : 3  a meeting or series of meetings between the leaders of two or more governments."
]

query_embeddings = model.encode(queries, prompt_name="web_search_query")
document_embeddings = model.encode(documents)

scores = (query_embeddings @ document_embeddings.T) * 100
print(scores.tolist())

Have a look at config_sentence_transformers.json for the prompts that are pre-configured, such as web_search_query, sts_query, and bitext_query. You can also use a custom instruction directly via e.g. model.encode(queries, prompt="Instruct: Retrieve semantically similar text\nQuery: ").

Transformers#
import torch
import torch.nn.functional as F

from torch import Tensor
from transformers import AutoTokenizer, AutoModel


def last_token_pool(last_hidden_states: Tensor, attention_mask: Tensor) -> Tensor:
    left_padding = (attention_mask[:, -1].sum() == attention_mask.shape[0])
    if left_padding:
        return last_hidden_states[:, -1]
    else:
        sequence_lengths = attention_mask.sum(dim=1) - 1
        batch_size = last_hidden_states.shape[0]
        return last_hidden_states[torch.arange(batch_size, device=last_hidden_states.device), sequence_lengths]


def get_detailed_instruct(task_description: str, query: str) -> str:
    return f'Instruct: {task_description}\nQuery: {query}'


# Each query must come with a one-sentence instruction that describes the task
task = 'Given a web search query, retrieve relevant passages that answer the query'
queries = [
    get_detailed_instruct(task, 'how much protein should a female eat'),
    get_detailed_instruct(task, 'summit define')
]
# No need to add instruction for retrieval documents
documents = [
    "As a general guideline, the CDC's average requirement of protein for women ages 19 to 70 is 46 grams per day. But, as you can see from this chart, you'll need to increase that if you're expecting or training for a marathon. Check out the chart below to see how much protein you should be eating each day.",
    "Definition of summit for English Language Learners. : 1  the highest point of a mountain : the top of a mountain. : 2  the highest level. : 3  a meeting or series of meetings between the leaders of two or more governments."
]
input_texts = queries + documents

tokenizer = AutoTokenizer.from_pretrained('microsoft/harrier-oss-v1-27b')
model = AutoModel.from_pretrained('microsoft/harrier-oss-v1-27b', dtype='auto')
model.eval()
model.cuda()

max_length = 32768
# Tokenize the input texts
batch_dict = tokenizer(input_texts, max_length=max_length, padding=True, truncation=True, return_tensors='pt')
batch_dict = {k: v.cuda() for k, v in batch_dict.items()}

outputs = model(**batch_dict)
embeddings = last_token_pool(outputs.last_hidden_state, batch_dict['attention_mask'])

# normalize embeddings
embeddings = F.normalize(embeddings, p=2, dim=1)
scores = (embeddings[:2] @ embeddings[2:].T) * 100
print(scores.tolist())

Supported Languages#

The models are trained on multilingual data and support a wide range of languages, including but not limited to: Arabic, Bulgarian, Catalan, Czech, Danish, German, Greek, English, Spanish, Estonian, Persian, Finnish, French, Hebrew, Hindi, Croatian, Hungarian, Indonesian, Italian, Japanese, Korean, Lithuanian, Latvian, Macedonian, Malay, Dutch, Norwegian, Polish, Portuguese, Romanian, Russian, Slovak, Slovenian, Albanian, Serbian, Swedish, Thai, Turkish, Ukrainian, Urdu, Vietnamese, and Chinese.

Evaluation#

Please follow the mteb repository on how to reproduce our scores. The evaluation prompts used for each task are also available at mteb_v2_eval_prompts.json.

FAQ#

1. Do I need to add instructions to the query?

Yes, this is how the model is trained, otherwise you will see a performance degradation. The task definition should be a one-sentence instruction that describes the task. This is a way to customize text embeddings for different scenarios through natural language instructions.

On the other hand, there is no need to add instructions to the document side.

2. Why are my reproduced results slightly different from reported in the model card?

Different versions of transformers and pytorch could cause negligible but non-zero performance differences.

3. What pooling strategy does this model use?

The model uses last-token pooling — the embedding of the last non-padding token is used as the sentence representation. The embedding is then L2-normalized. This is handled automatically when using Sentence Transformers.

Files

22 files · 54.1 GBWeights 54.0 GB (safetensors). Sizes and sha256 from the signed manifest.
Show all 22 files with their sha256
FileSizesha256
.gitattributes1.57 KB34448b82c17d60fec9b65b1f093c115ddbaadc04beb1b0140b6bfed2e012a930
1_Pooling/config.json297 B723365174afc1bd276bf8a51fe5560701e008f55c33917a72dc7036b317ab6b1
README.md7.60 KB6c42cc4b3926576c61b804ec9592d25bf0576243d421aee656c4d31eef58d110
config.json2.47 KB7a3f1a062ea71b0ecb52dc604e1722ca532e7268ca8dc767d355d25f96dd90a6
config_sentence_transformers.json351 Bad2096929147368b5d0ba5322ea394d50911be4d348091c9f3b0ad06c3763d91
model-00001-of-00011.safetensors4.83 GB5c7cc040810e2994fa58c16cf29f96846f17f1ccfa3125848f5f62d5a13c4f50
model-00002-of-00011.safetensors4.95 GB9f153ade385724aed38bfb51f215a11f8e5917b31a7465763d981c577f2f631a
model-00003-of-00011.safetensors4.95 GBd30eaed8bf16634212a503aa4bebed123c9aa7659a09bfafea4451925684039f
model-00004-of-00011.safetensors4.95 GB1c01153a5117b0b8917e1b0f9c95fe1f6f823233186ca6251cf4ca77fbf34aab
model-00005-of-00011.safetensors4.95 GBe4f886c44e783873c20c10d2b918c5e609d38c5f4fd518630739d61c9a5eda90
model-00006-of-00011.safetensors4.95 GB70cc07b65d54b8b9ecd12633a72623fe6a43748b8210acbd3165117ca66b168a
model-00007-of-00011.safetensors4.95 GBba2f97f98867817e2c0491d6fda9fdd9550e69a654e4b3d382b69eb4474e627c
model-00008-of-00011.safetensors4.95 GBb8b8331a8055e5297103bd0c4bf24a40832060222344192ad66b5ecf8cb7fbe0
model-00009-of-00011.safetensors4.95 GBb39feeff69c38c85f2ec0de17361a8ebd5b22b68c5106610b48850ecd8ea400e
model-00010-of-00011.safetensors4.95 GB93319f3f0cee7cd9e4fe055536f62264727448b115cd97962c09ebdaf71530d5
model-00011-of-00011.safetensors4.59 GB7a81a29e9308d283cc32135827910c5f719a3af69eed4ac104b96a3fa22c9f28
model.safetensors.index.json63.1 KB2c9c6996b0fa80ca50f28c2641a6b3cbc9f05563033417b5ac55dbfc430e0dce
modules.json349 B84e40c8e006c9b1d6c122e02cba9b02458120b5fb0c87b746c41e0207cf642cf
mteb_v2_eval_prompts.json11.9 KB08aaf10dc3d61ac54af15027d3a491ea06b2ed3edcb06dc05584539f5555fe51
special_tokens_map.json662 B2f7b0adf4fb469770bb1490e3e35df87b1dc578246c5e7e6fc76ecf33213a397
tokenizer.json33.4 MB6852f8d561078cc0cebe70ca03c5bfdd0d60a45f9d2e0e1e4cc05b68e9ec329e
tokenizer_config.json1.16 MB5a03f65eb2b1cac59ed9879f125ce27561d3e03d7cfa2a60ce3d20b56bc270d3
VersionsEach time the pinned upstream commit or file list changed in this repo. Newest first.
Upstream commitDateContents
0c0fc62f6d pinned now2026-11-15 02:47 UTC22 files · 54.1 GB

Use it

$ fw get microsoft/harrier-oss-v1-27b
# manifest sha256 5d33d400f53e… · 54.1 GB · 22 files
$ fw verify ./harrier-oss-v1-27b microsoft/harrier-oss-v1-27b
fw.pyChecks the signature and every sha256, tries each source in order, resumes.
$ python3 fw.py get https://freeweights.allternit.com/manifests/microsoft/harrier-oss-v1-27b.json --dir ./harrier-oss-v1-27b $ python3 fw.py verify ./harrier-oss-v1-27b ./microsoft__harrier-oss-v1-27b.json
hfThe Hugging Face CLI with one setting. Same repo id.
$ HF_ENDPOINT=https://freeweights.allternit.com hf download microsoft/harrier-oss-v1-27b --revision 0c0fc62f6d8af9e8604cb818c412301b103a0093 --local-dir ./harrier-oss-v1-27b
transformersLoad the weights in Python.
import os os.environ["HF_ENDPOINT"] = "https://freeweights.allternit.com" from transformers import AutoModel, AutoTokenizer tok = AutoTokenizer.from_pretrained("microsoft/harrier-oss-v1-27b", revision="0c0fc62f6d8af9e8604cb818c412301b103a0093") model = AutoModel.from_pretrained("microsoft/harrier-oss-v1-27b", revision="0c0fc62f6d8af9e8604cb818c412301b103a0093", device_map="auto")
sentence-transformersEmbed text with sentence-transformers.
import os os.environ["HF_ENDPOINT"] = "https://freeweights.allternit.com" from sentence_transformers import SentenceTransformer model = SentenceTransformer("microsoft/harrier-oss-v1-27b", revision="0c0fc62f6d8af9e8604cb818c412301b103a0093") vectors = model.encode(["Hello"])

License

Name
MIT License
Id
MIT
Class
Permissive
Redistribution
yes
Listing
Hosted (signed)
Decided
License as declared by the publisher. No person read it. 2026-11-15
Text in
README.md
Text sha256
6c42cc4b3926576c61b804ec9592d25bf0576243d421aee656c4d31eef58d110
Terms gate
No extra terms beyond the license.

Read the license text

Licenses are checked against the license table. A custom license passes only after a person reads it.

Provenance

From: microsoft <huggingface.co/microsoft>Newsgroups: alt.freeweights.embedSubject: harrier-oss-v1-27bDate: 2026-11-15Commit: 0c0fc62Signed: 2DC28CC7B26A283B ✓
Upstream
microsoft/harrier-oss-v1-27b
Pinned commit
0c0fc62f6d8af9e8604cb818c412301b103a0093
Manifest
harrier-oss-v1-27b.json · .minisig
Manifest sha256
5d33d400f53eae0f8676439dcde1bd46c406a6fb44072753542cdd58bcba15cc
Signature
minisign, Ed25519, key 2DC28CC7B26A283B
Created
2026-11-15 02:47 UTC
Generator
freeweights-manifest/0.1.0
Takedowns
None.

How to verify

$ curl -O https://freeweights.allternit.com/manifests/microsoft/harrier-oss-v1-27b.json $ curl -O https://freeweights.allternit.com/manifests/microsoft/harrier-oss-v1-27b.json.minisig $ minisign -Vm harrier-oss-v1-27b.json -P RWQ7KGqyx4zCLXtUFOqvfv8L3g+8fpKJ1FsuxPyOYMF+4KufbUxKq1Oq $ shasum -a 256 <file> # compare with the Files tab

A manifest whose signature fails must be rejected. A file whose size or sha256 does not match must be discarded. Verify a download

Model tree

No related models in this catalog.Nothing here lists this model as its parent, and it names no parent.
Get it
Download
$ HF_ENDPOINT=https://freeweights.allternit.com hf download microsoft/harrier-oss-v1-27b
Open in Freeweights Studio

Pull, verify and run it in the Allternit app on Desktop, web or phone.

Signed manifest
minisign, key 2DC28CC7B26A283B. harrier-oss-v1-27b.json. Provenance. Takedown history: none.
From: sentence-transformers <huggingface.co/sentence-transformers>Subject: all-MiniLM-L6-v1
From: unsloth <huggingface.co/unsloth>Subject: all-MiniLM-L6-v2
From: mlx-community <huggingface.co/mlx-community>Subject: all-MiniLM-L6-v2-4bit
From: sentence-transformers <huggingface.co/sentence-transformers>Subject: all-mpnet-base-v1
From: sentence-transformers <huggingface.co/sentence-transformers>Subject: allenai-specter
From: sentence-transformers <huggingface.co/sentence-transformers>Subject: bert-base-nli-max-tokens