Compare model versions
Earlier snapshot
Snapshot #339
Repository revision
7f5fab1 (opens in a new tab)
Recorded at 04 Sep 2026, 14:07 UTC
Unchanged through 14 Sep 2026, 07:02 UTC
Later snapshot
Snapshot #5644
Repository revision
b711680 (opens in a new tab)
Recorded at 16 Sep 2026, 06:38 UTC
Unchanged through 05 Nov 2026, 09:26 UTC
Summary
Licence
UnchangedNo change
MIT
MIT
PinDiff reports the declared licence and licence files. It does not interpret licence terms.
Weights
UnchangedNo change
Remote code / configuration
UnchangedNo change
Remote code
Yes
Yes
config.json Unchanged
Access / gating
UnchangedNo change
Public
Public
Model card
ChangedModel card modified (3 sections)
Usage Changed +8 −2
Diff
⋯ 55 unchanged lines
vLLM serves this model as an embedding model using its native Qwen3 implementation. Bidirectional attention is enabled with `is_causal=false`; no custom code is required on the vLLM side.
Added: + Install the latest vLLM release from PyPI:
Added: +
Added: + ```bash
Added: + pip install --upgrade vllm
Added: + ```
Added: +
```python
from vllm import LLM
from vllm.config import PoolerConfig
⋯ 20 unchanged lines
vllm serve ai-sage/Giga-Embeddings-instruct-3B-0826 \
--runner pooling --convert embed \
--hf-overrides '{"is_causal": false, "architectures": ["Qwen3ForCausalLM"]}' \
Removed: - --override-pooler-config '{"pooling_type": "MEAN", "use_activation": true}' \
Added: + --pooler-config '{"pooling_type": "MEAN", "use_activation": true}' \
--trust-remote-code
```
Removed: - \* this example is for latest vllm=0.26.0 release, for older vllm versions you might need to change pooler config argument from **use_activation** to **normalize**
Added: + The examples use `--pooler-config` and `use_activation=True` for mean pooling with L2 normalization.
</details>
Before
<details>
<summary>Sentence Transformers</summary>
```python
from sentence_transformers import SentenceTransformer
model = SentenceTransformer(
"ai-sage/Giga-Embeddings-instruct-3B-0826",
trust_remote_code=True, # needed for the bidirectional modeling code
)
instruction = "Given a query, retrieve relevant passages"
queries = [f"Instruct: {instruction}\nQuery: Где столица России?"]
documents = ["Москва — столица Российской Федерации.",
"Париж — столица Франции."]
q_emb = model.encode(queries, normalize_embeddings=True)
d_emb = model.encode(documents, normalize_embeddings=True)
print(model.similarity(q_emb, d_emb))
```
</details>
<details>
<summary>Transformers (manual mean pooling)</summary>
```python
import torch
import torch.nn.functional as F
from transformers import AutoModel, AutoTokenizer
path = "ai-sage/Giga-Embeddings-instruct-3B-0826"
tok = AutoTokenizer.from_pretrained(path, trust_remote_code=True)
model = AutoModel.from_pretrained(path, trust_remote_code=True,
dtype=torch.bfloat16).cuda().eval()
def encode(texts):
enc = tok(texts, return_tensors="pt", padding=True, truncation=True, max_length=512)
enc = {k: v.cuda() for k, v in enc.items()}
with torch.no_grad():
hidden = model(**enc).last_hidden_state
mask = enc["attention_mask"].unsqueeze(-1).to(hidden.dtype)
emb = (hidden * mask).sum(1) / mask.sum(1).clamp(min=1e-6) # mean pool
return F.normalize(emb, dim=-1) # L2 normalize
instr = "Given a query, retrieve relevant passages"
q = encode([f"Instruct: {instr}\nQuery: Где столица России?"])
d = encode(["Москва — столица Российской Федерации.", "Париж — столица Франции."])
print((q @ d.T).cpu())
```
</details>
<details>
<summary>vLLM</summary>
vLLM serves this model as an embedding model using its native Qwen3 implementation. Bidirectional attention is enabled with `is_causal=false`; no custom code is required on the vLLM side.
```python
from vllm import LLM
from vllm.config import PoolerConfig
llm = LLM(
model="ai-sage/Giga-Embeddings-instruct-3B-0826",
runner="pooling",
convert="embed",
hf_overrides={"is_causal": False, "architectures": ["Qwen3ForCausalLM"]},
pooler_config=PoolerConfig(pooling_type="MEAN", use_activation=True),
trust_remote_code=True,
)
instr = "Given a query, retrieve relevant passages"
outs = llm.encode([f"Instruct: {instr}\nQuery: Где столица России?",
"Москва — столица Российской Федерации."],
pooling_task="embed")
embs = [o.outputs.data for o in outs]
```
Or via the OpenAI-compatible server:
26 more lines not shown.
After
<details>
<summary>Sentence Transformers</summary>
```python
from sentence_transformers import SentenceTransformer
model = SentenceTransformer(
"ai-sage/Giga-Embeddings-instruct-3B-0826",
trust_remote_code=True, # needed for the bidirectional modeling code
)
instruction = "Given a query, retrieve relevant passages"
queries = [f"Instruct: {instruction}\nQuery: Где столица России?"]
documents = ["Москва — столица Российской Федерации.",
"Париж — столица Франции."]
q_emb = model.encode(queries, normalize_embeddings=True)
d_emb = model.encode(documents, normalize_embeddings=True)
print(model.similarity(q_emb, d_emb))
```
</details>
<details>
<summary>Transformers (manual mean pooling)</summary>
```python
import torch
import torch.nn.functional as F
from transformers import AutoModel, AutoTokenizer
path = "ai-sage/Giga-Embeddings-instruct-3B-0826"
tok = AutoTokenizer.from_pretrained(path, trust_remote_code=True)
model = AutoModel.from_pretrained(path, trust_remote_code=True,
dtype=torch.bfloat16).cuda().eval()
def encode(texts):
enc = tok(texts, return_tensors="pt", padding=True, truncation=True, max_length=512)
enc = {k: v.cuda() for k, v in enc.items()}
with torch.no_grad():
hidden = model(**enc).last_hidden_state
mask = enc["attention_mask"].unsqueeze(-1).to(hidden.dtype)
emb = (hidden * mask).sum(1) / mask.sum(1).clamp(min=1e-6) # mean pool
return F.normalize(emb, dim=-1) # L2 normalize
instr = "Given a query, retrieve relevant passages"
q = encode([f"Instruct: {instr}\nQuery: Где столица России?"])
d = encode(["Москва — столица Российской Федерации.", "Париж — столица Франции."])
print((q @ d.T).cpu())
```
</details>
<details>
<summary>vLLM</summary>
vLLM serves this model as an embedding model using its native Qwen3 implementation. Bidirectional attention is enabled with `is_causal=false`; no custom code is required on the vLLM side.
Install the latest vLLM release from PyPI:
```bash
pip install --upgrade vllm
```
```python
from vllm import LLM
from vllm.config import PoolerConfig
llm = LLM(
model="ai-sage/Giga-Embeddings-instruct-3B-0826",
runner="pooling",
convert="embed",
hf_overrides={"is_causal": False, "architectures": ["Qwen3ForCausalLM"]},
pooler_config=PoolerConfig(pooling_type="MEAN", use_activation=True),
trust_remote_code=True,
)
instr = "Given a query, retrieve relevant passages"
outs = llm.encode([f"Instruct: {instr}\nQuery: Где столица России?",
"Москва — столица Российской Федерации."],
32 more lines not shown.
Requirements Changed +2 −3
Diff
```bash
Removed: - # ms-swift from main — the current PyPI release does not yet contain the
Removed: - # SentenceTransformer full-parameter save fix.
Removed: - pip install "git+https://github.com/modelscope/ms-swift.git"
Added: + # Install the latest ms-swift release from PyPI.
Added: + pip install --upgrade ms-swift
# sentence-transformers pinned to 5.3.0.
pip install "sentence-transformers==5.3.0"
Before
```bash # ms-swift from main — the current PyPI release does not yet contain the # SentenceTransformer full-parameter save fix. pip install "git+https://github.com/modelscope/ms-swift.git" # sentence-transformers pinned to 5.3.0. pip install "sentence-transformers==5.3.0" ``` torch and transformers are pulled in automatically. A CUDA GPU is required for training. For **full-parameter finetuning of the 10B MoE model** (multi-GPU, DeepSpeed ZeRO-3), also install DeepSpeed: ```bash pip install deepspeed ``` ---
After
```bash # Install the latest ms-swift release from PyPI. pip install --upgrade ms-swift # sentence-transformers pinned to 5.3.0. pip install "sentence-transformers==5.3.0" ``` torch and transformers are pulled in automatically. A CUDA GPU is required for training. For **full-parameter finetuning of the 10B MoE model** (multi-GPU, DeepSpeed ZeRO-3), also install DeepSpeed: ```bash pip install deepspeed ``` ---
Troubleshooting Changed +3 −2
Diff
Removed: - - **`AttributeError: 'NoneType' object has no attribute 'items'` during save** — you're
Removed: - on the PyPI release of ms-swift; install from `main` (see Requirements).
Added: + - **`AttributeError: 'NoneType' object has no attribute 'items'` during save** — upgrade
Added: + ms-swift with `pip install --upgrade ms-swift` to get the SentenceTransformer
Added: + full-parameter save fix (see Requirements).
- **Reloaded model gives base-model quality / "missing keys" on load after full
finetuning** — your `sentence-transformers` is newer than 5.3; pin `==5.3.0`.
- **Model downloads from ModelScope instead of HuggingFace (or is not found)** — add
Before
- **`AttributeError: 'NoneType' object has no attribute 'items'` during save** — you're on the PyPI release of ms-swift; install from `main` (see Requirements). - **Reloaded model gives base-model quality / "missing keys" on load after full finetuning** — your `sentence-transformers` is newer than 5.3; pin `==5.3.0`. - **Model downloads from ModelScope instead of HuggingFace (or is not found)** — add `--use_hf true`. </details> [Paper](https://arxiv.org/abs/2608.23806)
After
- **`AttributeError: 'NoneType' object has no attribute 'items'` during save** — upgrade ms-swift with `pip install --upgrade ms-swift` to get the SentenceTransformer full-parameter save fix (see Requirements). - **Reloaded model gives base-model quality / "missing keys" on load after full finetuning** — your `sentence-transformers` is newer than 5.3; pin `==5.3.0`. - **Model downloads from ModelScope instead of HuggingFace (or is not found)** — add `--use_hf true`. </details> [Paper](https://arxiv.org/abs/2608.23806)
24 other sections unchanged.
Repository status
ChangedRepository revision moved
- Earlier
-
Revision
7f5fab1(opens in a new tab) · 13 files · 6.31 GB - Later
-
Revision
b711680(opens in a new tab) · 13 files · 6.31 GB
A new revision does not by itself mean files changed; the categories above show what differs.
Files
UnchangedNo change
Evidence observed by PinDiff from the Hugging Face API and stored when recorded. PinDiff compares stored metadata, hashes and text files; it does not download weight files. Change events recorded between these snapshots