Choose a profile for your hardware and documents. See what the models can do, what this stack actually uses, and where text can be lost before a result reaches you.
This page illustrates shipped settings. It never detects hardware, reads configuration or changes the stack. All CPU/GPU limits ↓
01 / Before the model names
One switch. Three jobs to fill.
A profile is a fixed set of models that together do everything the stack needs from machine learning. Both profiles fill the same three roles.
Role 1 / Dense embedding
Turn a passage into meaning.
The dense model reads a passage and produces one fixed-length vector of 1024 numbers. The model is trained to place related texts close together, including texts that share no words; relevance still needs evaluation on your corpus. Your question is embedded the same way, so “rotate the credential” may find “replace the token”.
Stored in Qdrant as the dense vectorRole 2 / Sparse embedding
Keep lexical evidence.
The sparse model produces a vector of weights over a vocabulary: non-zero entries carry lexical evidence, and the remaining entries are zero. This can help retrieve variable names, error codes and rare jargon, but tokenization and learned weights do not guarantee literal matching. The two profiles fill this role differently. BGE-M3 weights the tokens that actually appear in the text. MILCO projects the text onto an English pivot vocabulary and can also weight terms the text never spells out, a learned expansion that helps across languages. Neither is an exact-match filter; for hard constraints on metadata, use payload filters.
Stored in Qdrant as the sparse vectorRole 3 / Reranking
Give the shortlist a second look.
After Qdrant fuses the dense and sparse candidates, the reranker reads your question together with each candidate passage and scores the pair. It is slower per passage, so it only sees the shortlist; it never touches the whole collection.
Runs at query time only; nothing is stored
Why the profile is chosen once.
One line in .env.SMART_EMBEDDER_PROFILE is basic or advanced. Any other value stops Smart Embedder at startup instead of guessing. The shipped template selects advanced; basic is what the server falls back to when the variable is absent.
Read at process start. The models load once and stay resident. There is no runtime switch: changing the family means restarting the stack, which the CLI guide walks through.
Stamped at creation. When the app creates a collection it records an embedding-contract fingerprint of the active profile in the collection’s metadata, before any vector is written. Every vector that later lands there is shaped by exactly these models, and only these models can search them. See what that means for you ↓.
A text journey / Illustrative, no model calls
Same question. Different evidence.
Query · Italian Come risolvo ERR_AUTH_401 dopo la rotazione del token?
Three authored candidates below illustrate why matching a term and answering a question are different jobs. They have no measured model weights, similarities or ranking.
A · Identifier and remedy
After token rotation, ERR_AUTH_401 means the client still uses the previous credential. Update the client token and retry.
Exact identifier visible in the text. A tokenizer may split it into multiple pieces.
B · Remedy in German
Nach dem Wechsel des API-Schlüssels muss der Client den neuen Schlüssel senden. Sonst wird die Anfrage abgewiesen.
Related meaning across languages; the error identifier is absent.
C · Error-code catalogue
The dashboard lists ERR_AUTH_401, ERR_RATE_429 and ERR_TIMEOUT_504. Export the error-code catalogue as CSV.
The identifier appears, but this passage gives no token-rotation remedy.
A contains the identifier and a remedy; B describes the remedy in another language; C only lists the code.
BGE sparse
Weights observed vocabulary tokens. Shared identifier pieces may contribute for A and C; their mere presence does not guarantee a match or a higher score.
MILCO sparse
Can add English pivot features such as “credential” or “replace”, alongside source-language evidence. Those words illustrate possible concepts, not the model’s output for these passages.
Dense
Represents the query and passages separately. Cross-language training may connect the Italian question with B’s German remedy; no distance or ordering is computed here.
Reranker
Reads the query with each shortlisted passage. It can assess whether the passage answers the question, provided that evidence survives the input limits.
Admission: body, entry count and request budgets can reject work before inference.
Embedding: each backend applies its own tokenizer and window. The dense and sparse cut points can differ.
Retrieval: Qdrant returns candidate payload text; the embedding window does not shorten the stored payload.
Reranking: the middleware trims surrounding whitespace, then takes the first 1000 Unicode characters of each candidate by default. The reranker then tokenizes the query and candidate within its own window.
The bars use independent, invented token counts for each backend to explain window limits. They are not tokenizations of A, B or C, are not aligned word positions, and do not predict an accepted request. No character-to-token conversion runs in this browser.
Dense tokenizer
Sparse tokenizer
Reranker tokenizer
Illustrative formatted pair, after the character cut; includes query/template overhead.
Reading example: advanced on CPU allows 2048 dense tokens and 8192 MILCO tokens. A long passage may therefore contribute sparse evidence that the dense vector never saw. Token positions across these models cannot be lined up word for word.
A real character cut, without a tokenizer
This authored passage places its remedy at the end. The browser reproduces only the middleware’s character slicing; it does not run a model. Moving the remedy to the front shows how text order changes what reaches reranking.
🔑 The client reports ERR_AUTH_401 after a credential change. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. The incident log records the timestamp, request path and retry count. Remedy: update the client to send the new token, then retry.
Sent onward to the reranker
Removed before reranking
The full passage remains in the stored payload. Character retention alone cannot promise that the model’s later tokenization retains the remedy.
Chunk documents around useful units of meaning, then inspect input_truncated warnings and retrieval failures. Raising a model limit alone does not remove the middleware character cut, admission budgets or memory constraints.
02 / The basic profile
Basic. One family does everything.
Two model repositories from the Beijing Academy of Artificial Intelligence. One encoder produces every vector type; a sibling reranker built on the same encoder scores the shortlist.
When you would choose it
A useful baseline for a first run or a policy that forbids custom model-repository Python. One encoder supplies both retrieval vectors. CPU startup uses a smaller embedding window; memory needs also depend on batch size, input length and concurrency. See the recorded hardware evidence below.
SMART_EMBEDDER_PROFILE=basic
Dense + sparse / Roles 1 and 2
BAAI/bge-m3
One encoding, two retrieval signals.
Model capability
A multilingual encoder can produce dense, lexical sparse and token-level ColBERT representations from one forward pass.
Used in this stack
The middleware requests dense and sparse vectors, returned as 1024 numbers and sparse indices/values. It disables ColBERT. The embedding window follows the CPU/GPU defaults.
Practical impact
Both retrieval branches see the same admitted, tokenized input. Sparse evidence comes from observed tokens; it is not a literal identifier filter.
Specifications and pinned source
Architecture
Encoder from the XLM-RoBERTa-large family, extended to long inputs and fine-tuned for retrieval
Parameters
About 0.57 billion
Dense output
1024 numbers per text
Sparse output
Lexical weights over the model’s own multilingual vocabulary
A multilingual cross-encoder produces one relevance logit per query–passage pair. Optional sigmoid normalization maps the score to 0–1.
Used in this stack
By default the middleware requests sigmoid-normalized 0–1 scores (rerank_normalize=true); a caller gets raw logits only by turning that off. It trims candidate text before sending the pair to the reranker; the model then applies its own token window.
Practical impact
The reranker can reorder candidates but cannot recover a passage absent from the shortlist, or evidence already removed from its input.
Specifications and pinned source
Architecture
Cross-encoder fine-tuned from BGE-M3
Output
One raw relevance logit per pair; a sigmoid maps it to 0–1
Context
Query + passage, up to 8192 tokens; BAAI suggests 1024 for practical use
ColBERT keeps a vector for each token and compares the query and passage through late interaction. BGE-M3 can produce it; the middleware always sends return_colbert: false.
This project uses dense + sparse retrieval followed by a reranker. Storing token vectors would add storage and a separate scoring path. The project has not measured a ColBERT quality gain over this pipeline on its own corpora.
Why this choice, and how to request ColBERT
Qdrant documents a multi-stage design that retrieves candidates cheaply, then rescores with multivectors. Token vectors in that design can omit HNSW indexing. This supports a storage and complexity tradeoff, not a claim that ColBERT is worse than a cross-encoder. Qdrant: multivectors and late interaction ↗.
For your own integration, call Smart Embedder’s POST /embeddings/ directly under basic with return_colbert: true. Publish its host port, provide its bearer token when authentication is enabled, and handle storage/search yourself. Advanced rejects return_colbert: true.
{
"sentences": ["Rotate the API token every 90 days."],
"return_dense": true,
"return_sparse": true,
"return_colbert": true,
"sparse_as_indices": true
}
A direct request in the basic profile. The app itself always sends return_colbert: false.
sparseWeighted terms · indices + valuesstored · searched · fused
colbertOne 1024-number vector per tokenavailable on direct call · not stored · not searched
03 / The advanced profile
Advanced. Three specialists, one roster.
A Qwen3 encoder for meaning, a research model for multilingual sparse retrieval, and a Qwen3 reranker that judges each pair. Each was chosen for one job.
When you would choose it
The shipped template’s default, worth evaluating for multilingual retrieval and longer dense inputs on GPU. On CPU its dense context is capped while MILCO retains a larger sparse window. MILCO executes pinned custom model code. The launcher’s automatic choice is a hardware heuristic, not a quality or memory guarantee.
SMART_EMBEDDER_PROFILE=advanced
Dense / Role 1
Qwen/Qwen3-Embedding-0.6B
Long context, when the runtime allows it.
Model capability
A 0.6B Qwen3 model supports 32K input tokens, task instructions and Matryoshka Representation Learning (MRL): output dimensions from 32 to 1024.
Used in this stack
The stack always keeps 1024 dimensions. A search query is embedded with the model’s own query instruction; stored text carries none. GPU defaults allow the full window; CPU defaults cap it. MRL is not exposed as a setting.
Practical impact
A long model context is not the CPU input limit. Published evaluations do not establish this stack’s quality; compare the actual pipeline on your data.
Specifications and pinned source
Architecture
Qwen3 transformer, 28 layers, adapted for embedding
Parameters
0.6 billion
Dense output
32–1024 dimensions supported upstream; 1024 used here
MILCO combines a multilingual encoder, a connector and an English lexical head. Learned expansion can give weight to English terms absent from the original text; LexEcho adds a source-language view.
Used in this stack
MILCO_SOURCE_VIEW=true includes source-language evidence; MILCO_TOP_K=0 retains all non-zero weights. Its sparse window stays at the shipped limit on both CPU and GPU.
Practical impact
This is worth testing for cross-language questions and rare terms. English pivot terms are retrieval features, not a translation or guaranteed output. Under advanced on CPU, sparse may see text beyond the dense window.
Specifications and pinned source
Architecture
Multilingual encoder (BAAI/bge-m3-unsupervised) + linear connector + lexical head borrowed from an English SPLADE model
Parameters
About 0.65 billion
Sparse output
Weights over an English pivot vocabulary, plus a source-language view
Cross-language retrieval; evaluate your language pairs on your corpus
License
Apache-2.0 on its model card, but its lexical head (about 4% of the weights) derives from naver/splade-v3, licensed CC BY-NC-SA 4.0 for non-commercial use: see the licensing note
trust_remote_code executes custom model-repository Python. The revision is pinned and serving is non-root with a read-only filesystem; those controls do not audit that code. Use basic if custom model code is outside your policy.
Reranker / Role 3
Qwen/Qwen3-Reranker-0.6B
Score a yes/no relevance judgment.
Model capability
A 0.6B Qwen3 language model reads an instruction, query and passage and scores the yes/no alternatives.
Used in this stack
The relevance instruction is fixed. The middleware trims each candidate by characters first; the reranker’s CPU/GPU token limit then bounds the formatted input.
Practical impact
Its score scale differs from a BGE logit and is not a calibrated probability that an answer is correct. Compare ranked results and relevance judgments across profiles.
Specifications and pinned source
Architecture
Qwen3 causal language model, 28 layers, scored through a yes/no instruction prompt
Model repositories are downloaded from Hugging Face once, at the pinned commit, into the local smart-embedder-hf-cache volume. After that first preparation, embedding and reranking need no network. The full revisions live in server-embedder-reranker/model_revisions.py; a model update is a deliberate revision bump followed by the smoke tests, never a moving branch.
04 / Side by side
Same roles. Different answers.
Use this table to decide, then evaluate on your own documents. Neither profile wins every collection.
What each profile brings to the three roles, and what it asks of your machine. Defaults are the shipped ones; the CPU values are the Compose safety caps.
MILCO loads with trust_remote_code, pinned and contained
Memory footprint
Recorded BASIC run on an 8 GB GPU; workload-dependent peak
Separate models and workloads need measured headroom
CPU
Supported; autotuned runtime with ONNX candidates
Supported; conservative defaults, measure latency
Licenses
MIT (encoder) · Apache-2.0 (reranker)
Apache-2.0 on all three model cards, but MILCO’s lexical head derives from naver/splade-v3 (CC BY-NC-SA 4.0, non-commercial) · MIT (BAAI/bge-m3-unsupervised, fetched for its tokenizer only)
Selected by
basic, or the fallback when the variable is absent
advanced, the shipped template value; automatic selection follows the GPU rule below
What the shipped runtime actually accepts
These are model token windows after request admission, not guarantees that a request will be admitted. CPU values include Compose overrides. Your environment or runtime may differ; inspect GET /models for the running configuration.
Tokens per model input. Reranker windows include the query and formatted pair. Each model uses its own tokenizer.
Setup
Dense tokens
Sparse tokens
Reranker tokens
basic · CPU
2048
2048
8192
basic · GPU
8192
8192
8192
advanced · CPU
2048
8192
2048
advanced · GPU
32768
8192
32768
Source: Compose CPU/GPU settings, maintained with the embedder configuration reference. Admission also checks body size, entry count and work/output budgets; a request can receive HTTP 413 before any tokenizer truncation or model inference.
Choose basic when
You want the simplest trustworthy start.
A first run, a smaller GPU or none at all, or a policy that forbids third-party model code. One family and native architecture support. Measure its recall, latency and memory as your baseline.
On GPU, the larger dense window can help with long inputs, while MILCO adds a shared lexical space across languages. On CPU, dense still has the smaller cap. Measure whether these differences help your queries.
up auto inspects local NVIDIA devices and applies one threshold to the selected GPU: the one named with --gpu-device or STACK_GPU_DEVICE, otherwise the one with the most total memory. 7680 MiB or more picks advanced, less picks basic, and no device means CPU. A model named on the command line always wins over the automatic result. This total-memory threshold does not measure free VRAM or predict retrieval quality.
Guide facts checked . Scope: the pinned model revisions and repository defaults, not a new retrieval-quality benchmark.
Upstream specification
The model cards above link to immutable README revisions. They support architecture, dimensions and declared capabilities. Their benchmark results describe their own evaluation setup.
The embedder’s recorded hardware baselines report particular machines and workloads. They do not prove a universal VRAM bound or that one profile retrieves better.
Teaching examples
The passages and token-window bars on this page are illustrative. Only the character-cut demonstration computes a transformation of its displayed text.
Compare the profiles on your own corpus
Freeze the task. Use identical source texts, chunk boundaries, metadata and filters. Prepare a small pilot of representative questions with human relevance judgments, including identifiers, paraphrases, your language pairs and long-passage failures. Reserve held-out questions before tuning.
Build separate collections. Import the same chunks under each profile and record their fingerprints. Keep retrieval depth, fusion, rerank window, character cap and Qdrant settings equal for the first comparison.
Measure both stages. Record candidate Recall@k (relevant passages retrieved divided by all judged relevant passages) before reranking, then nDCG@10 (graded relevance discounted by position, normalized to the ideal ranking) after reranking. Report the cutoff, relevance scale, unanswered queries and judgment coverage. A reranker cannot repair missing candidates.
Measure cost separately. Report warm p50/p95 end-to-end query latency, ingest throughput and peak memory under a fixed concurrency and input-length distribution. Separate cold preparation from warm serving. Record hardware, model revisions, runtime, precision, limits and truncation warnings.
Choose from the tradeoff. Inspect failures per language and query type, not only an overall mean. Tune on the development questions, freeze settings, then evaluate once on the held-out set. A small pilot is a starting point, not statistical proof of a winner.
The embedder benchmark measures service performance; it does not supply corpus relevance judgments or this end-to-end retrieval evaluation. Keep the questions, judgments, configuration and results together so someone else can repeat your comparison.
Model licenses are separate from the application’s AGPL-3.0 license; consult the terms for each model you deploy. MILCO, in the advanced profile, contains weights derived from a non-commercial model, so check those terms before any commercial use. Read the licensing note ↗.
05 / One contract per collection
The vectors remember who made them.
Switching profiles is a restart away. Making an existing collection follow is not, and the app refuses to pretend otherwise.
The stamp. Smart Embedder reports an embedding_contract_fingerprint for the active profile. The middleware writes it into the collection’s metadata when it creates the collection, before the first vector arrives.
The check. Import, vector upsert and search compare the running profile with the collection’s stamp. A mismatch is refused with an HTTP 409 embedding-contract error. Results are never silently mixed across vector spaces. Re-embed is the migration path: its preflight checks whether the existing collection can be regenerated for the active target contract. The job keeps that target stable and updates the collection’s contract after regeneration and verification.
Three ways forward. Restart the stack under the collection’s original profile, which touches no data. Regenerate every vector under the new profile with Collections → Re-embed Vectors in the console, when its read-only preflight says the collection is ready. Or create a new collection under the new profile and import the source texts again, often the clearest route when the preflight says no.
06 / Common questions
Answers about the models themselves.
For startup errors, use the CLI guide. For search quality, use the hybrid search guide. These questions are about what the models are and do.
Can I plug in a different model?
Not through configuration. The two profiles are fixed rosters, pinned to exact Hugging Face commits, and the autotuner, the request limits and the embedding contract are all built around them. A different model is a code change to Smart Embedder with a new pinned revision and a new smoke-test pass, not a setting.
What you can choose is the profile, the hardware and the runtime controls listed in the basic and advanced configuration references.
Do my documents or questions leave my machine?
Not for embedding or reranking. Every model on this page runs inside the Smart Embedder container on your CPU or GPU, and the only network the models need is the first download of the pinned weights from Hugging Face into the local cache volume.
Storage is a separate question. Your passages, their payloads and their vectors are sent to the Qdrant instance named in QDRANT_URL. If that is a remote or cloud Qdrant, they leave your machine at that step even though the embedding itself stayed local. Likewise, if you connect an AI agent that uses a cloud model, your questions and the returned passages can cross that boundary on the agent’s side. A local Qdrant and a local agent are what keep the whole flow on your own infrastructure; the architecture guide shows where the line sits.
Can I get ColBERT vectors for my own project?
Yes, in the basic profile, by calling Smart Embedder directly with return_colbert: true. You need the published host port, a Smart Embedder bearer token when authentication is enabled, and your own storage; the middleware and the console will not store or search those vectors. Read why the stack leaves them out ↑.
Why did my scores change after switching profile?
Because the rerankers speak different languages. The BGE reranker scores with a logit, sigmoid-normalized to 0–1 by default; the Qwen reranker returns a yes-probability. Both can read 0–1, but they are not on a shared scale. Fused retrieval scores also come from different vector spaces. Compare rankings and the passages they surface, not the numbers between profiles.
Both profiles produce 1024 numbers. Are they compatible?
No. Equal length is a coincidence of two model designs, not a shared geometry. A collection stamped by one profile is refused by the other with a 409 error until you restore its profile or complete a compatible re-embed migration; a new collection and reimport is another route. The contract section explains the three ways forward.
What happens to a passage longer than the model’s context?
Once a request is admitted, a passage over the context limit is truncated to it, and the response carries a structured input_truncated warning naming the passage and how much was cut. Admission comes first: a request body over the size cap, too many entries, or a batch whose estimated work exceeds the request budget is refused with HTTP 413 before any model runs. The limits are per model, not per profile. On CPU the shipped Compose caps the dense encoders at 2048 tokens in both profiles (set in .env by BGE_EMBED_CPU_MAX_LENGTH and QWEN_EMBED_CPU_MAX_LENGTH, not by the GPU-side *_EMBED_MAX_LENGTH), while MILCO’s sparse branch keeps MILCO_MAX_LENGTH at 8192, so under advanced the two vectors of one passage can be cut at different points. For search quality, split long documents into passages well below the smallest limit before import.
The first start is slow. Is that the models?
Mostly. The first preparation downloads the selected profile’s pinned snapshots, then the autotuner measures runtime candidates on your hardware and saves a decision. Later starts reuse both. The CLI guide explains the preparation pause and the quick, full and off calibration modes.
What does “trust remote code” mean for MILCO?
The MILCO repository ships Python that defines its architecture, and loading it executes that code inside the Smart Embedder container. The stack contains the risk: the snapshot is pinned to one immutable commit, model preparation refuses any snapshot whose revision differs, and the container runs read-only as a non-root user. The basic profile has no such path. If your policy rules out third-party model code, that is the deciding factor, not performance. Read the full note ↗.
07 / Keep going
From the models to the results.
You now know who produces the vectors. These guides show how they are searched and where they run.
Next / Hybrid Search
From a question to relevance.
Follow the dense and sparse vectors from your question through fusion to the reranked shortlist, then compare settings in the ranking lab.
The HTTP contract, the configuration surface and the autotuner belong to server-embedder-reranker/README.md; its capabilities and limits section answers “can it do X?”. Model facts on this page come from the model cards linked above.