Model reference · open weights
LaSER-Qwen3 is an open-weight embedding model from Alibaba. LaSER-Qwen3-8B (FP16) weighs 16.4 GB; the smallest configuration that runs it is RTX 4090 24 GB.
Summary of the Alibaba-NLP/LaSER-Qwen3-0.6B model card, 2026-10-01. The estimate below is for another build of the family.
What it is
| Released by | Alibaba |
|---|---|
| Released | 2026-03-31 |
| Parameters | 596M |
| VRAM | 16.4 GB for the weights |
What it runs on
| Card | Runs | Memory |
|---|---|---|
| RTX 3060 12 GB … RTX 4060 Ti 16 GB | does not fit | |
| RTX 3090 24 GB | fits | 23.4 GB |
| RTX 4090 24 GB | fits | 23.4 GB |
| RTX 5090 32 GB | fits | 31.0 GB |
| L40S 48 GB | fits | 44.0 GB |
| A100 80 GB | fits | 78.2 GB |
| H100 80 GB | fits | 78.1 GB |
| RTX PRO 6000 Blackwell 96 GB | fits | 93.8 GB |
| DGX Spark (GB10) 128 GB unified | fits | 107 GB |
| H200 141 GB | fits | 138 GB |
| B200 180 GB | fits | 176 GB |
Builds
| Build | Params | Precision | Weights | Smallest setup |
|---|---|---|---|---|
| LaSER-Qwen3-0.6B ↗ | 596M | FP16 | 1.2 GB | RTX 3060 12 GB |
| LaSER-Qwen3-8B (above) ↗ | 8.2B | FP16 | 16.4 GB | RTX 4090 24 GB |
| LaSER-Qwen3-4B ↗ | 4.0B | FP16 | 8.0 GB | RTX 3060 12 GB |
From the model card
LaSER (Latent Space Explicit Reasoning) is a self-distillation framework that internalizes explicit Chain-of-Thought reasoning into the latent space of dense retrievers, enabling the model to "think silently" through continuous latent tokens.
LaSER-Qwen3-0.6B is a 0.6B-parameter dense retriever built on Qwen/Qwen3-0.6B.
📄 Paper: LaSER: Internalizing Explicit Reasoning into Latent Space for Dense Retrieval
| Attribute | Detail |
|---|---|
| Model Type | Dense Retriever with Latent Thinking |
| Base Model | Qwen/Qwen3-0.6B |
| Parameters | 0.6B |
| Embedding Dimension | 1024 |
| Max Sequence Length | 8192 (training: 512) |
| Similarity Function | Cosine Similarity |
| Latent Thinking Steps (K) | 3 (default) |
| Training Data | 81K examples from ReasonEmb |
| License | MIT |
Unlike standard dense retrievers that encode queries in a single forward pass, LaSER generates K continuous latent thinking tokens autoregressively in the embedding space:
This enables complex reasoning while maintaining the inference efficiency of standard dense retrievers (~1.7× latency overhead, only ~0.3% of rewrite-then-retrieve pipelines).
import torch
import torch.nn.functional as F
from transformers import AutoModelForCausalLM, AutoTokenizer
def laser_encode(model, tokenizer, texts, max_length=512, num_thinking_steps=3):
"""Encode texts using LaSER's latent thinking mechanism."""
device = next(model.parameters()).device
batch = tokenizer(texts, padding=True, truncation=True, max_length=max_length, return_tensors="pt").to(device)
input_ids, attention_mask = batch["input_ids"], batch["attention_mask"]
batch_size = input_ids.size(0)
thinking_slots = num_thinking_steps - 1
eos_id = tokenizer.eos_token_id
if thinking_slots > 0:
eos_padding = torch.full((batch_size, thinking_slots), eos_id, dtype=input_ids.dtype, device=device)
mask_padding = torch.ones((batch_size, thinking_slots), dtype=attention_mask.dtype, device=device)
input_ids = torch.cat([input_ids, eos_padding], dim=1)
attention_mask = torch.cat([attention_mask, mask_padding], dim=1)
input_embeds = model.get_input_embeddings()(input_ids)
embedding_table = model.get_input_embeddings().weight
base_seq_len = input_embeds.size(1) - thinking_slots
past_key_values = None
hidden_steps = []
for step_idx in range(thinking_slots):
pos = base_seq_len + step_idx
step_embeds = input_embeds[:, :pos, :] if past_key_values is None else input_embeds[:, pos-1:pos, :]
step_mask = attention_mask[:, :pos]
outputs = model(inputs_embeds=step_embeds, attention_mask=step_mask,
output_hidden_states=True, past_key_values=past_key_values,
use_cache=True, return_dict=True)
hidden_steps.append(outputs.hidden_states[-1][:, -1, :])
token_probs = torch.softmax(outputs.logits[:, -1, :], dim=-1)
new_embed = token_probs @ embedding_table
past_key_values = outputs.past_key_values
pre = input_embeds[:, :pos, :]
post = input_embeds[:, pos+1:, :]
input_embeds = torch.cat([pre, new_embed.unsqueeze(1), post], dim=1)
final_embeds = input_embeds[:, -1:, :] if past_key_values else input_embeds
outputs = model(inputs_embeds=final_embeds, attention_mask=attention_mask,
output_hidden_states=True, past_key_values=past_key_values,
use_cache=True, return_dict=True)
hidden_steps.append(outputs.hidden_states[-1][:, -1, :])
embeddings = torch.stack(hidden_steps, dim=1).mean(dim=1)
return F.normalize(embeddings, p=2, dim=-1)
# Load model
model_name = "Alibaba-NLP/LaSER-Qwen3-0.6B"
tokenizer = AutoTokenizer.from_pretrained(model_name, trust_remote_code=True)
tokenizer.padding_side = "left"
if tokenizer.pad_token_id is None:
tokenizer.pad_token = tokenizer.eos_token
model = AutoModelForCausalLM.from_pretrained(
model_name, torch_dtype=torch.float16, trust_remote_code=True
).cuda().eval()
# Encode queries and documents
with torch.inference_mode():
query_emb = laser_encode(model, tokenizer, ["why is the sky blue"], num_thinking_steps=3)
doc_emb = laser_encode(model, tokenizer, ["Rayleigh scattering makes short wavelengths scatter more strongly"], num_thinking_steps=3)
# Compute similarity
similarity = (query_emb @ doc_emb.T).item()
print(f"Cosine similarity: {similarity:.4f}")
queries = [
"What causes tides in the ocean?",
"How does photosynthesis convert light to energy?",
"Why do metals conduct electricity?",
]
with torch.inference_mode():
query_embeddings = laser_encode(model, tokenizer, queries, num_thinking_steps=3)
print(f"Batch embeddings shape: {query_embeddings.shape}") # (3, 1024)
| Model | Size | Avg. |
|---|---|---|
| Qwen3-Embedding | 0.6B | 14.4 |
| Fair Baseline (Qwen3-0.6B) | 0.6B | 18.3 |
| Rewrite-then-Retrieve (Qwen3-0.6B) † | 0.6B | 22.4 |
| GIRCSE (Qwen3-0.6B) | 0.6B | 19.1 |
| LaSER-Qwen3-0.6B (Ours) | 0.6B | 23.1 |
| Model | Follow
Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.