published fresh until

Weaviate: rerank vector results with a local model

Summary As of November 2026, enable reranker-transformers on a self-hosted instance, configure the collection, then pass Rerank(prop="question", query="publication") to near_text. The rerank query defaults to the retrieval query when omitted. Begin with ENABLE_MODULES=reranker-transformers.

Not for Weaviate Cloud using reranker-transformers, or Boost v1.38 filter/value biasing.

For your agent
claude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp

Read-only, no account. Sign-in is only for trial reports: /connect.md

What this thread does

Do first: On a self-hosted Weaviate instance, enable reranker-transformers and its model container; configure the collection before adding Rerank(...) to a vector query.

Short answer

As of November 2026, Weaviate reranks an initial retrieval result set with a second model. The concrete route below uses a local Transformers reranker with Python. This integration is unavailable on Weaviate Cloud because it needs a separate model container. Rerankers can also follow BM25 or hybrid retrieval.

What to do

For Docker, add the documented settings to docker-compose.yml; keep any other modules your instance already needs enabled.

SettingDocumented value / action
Weaviate ENABLE_MODULESEnable reranker-transformers
Weaviate RERANKER_INFERENCE_APIhttp://reranker-transformers:8080 in the documented Docker layout
Inference service namereranker-transformers
Inference service imagecr.weaviate.io/semitechnologies/reranker-transformers:cross-encoder-ms-marco-MiniLM-L-6-v2
Inference ENABLE_CUDADocker example uses 0; set 1 to enable GPU usage
Model choiceSelect the model through the container image
Listed model IDscross-encoder/ms-marco-MiniLM-L-6-v2, cross-encoder/ms-marco-MiniLM-L-2-v2, cross-encoder/ms-marco-TinyBERT-L-2-v2
Python collection configurationImport Configure from weaviate.classes.config; supply reranker_config=Configure.Reranker.transformers() to client.collections.create(...)
Existing collection updatesReranker model configuration is mutable from v1.25.23, v1.26.8 and v1.27.1 in the respective release lines; release dates are not stated
Multiple rerankersSelect the module in the schema's moduleConfig

With an already connected client and a configured, populated JeopardyQuestion collection, the search page's Python example can be expressed as:

from weaviate.classes.query import Rerank
collection = client.collections.use("JeopardyQuestion")
response = collection.query.near_text(query="flying", limit=10, rerank=Rerank(prop="question", query="publication"))
Query itemMeaning / action
near_text(query="flying")Initial retrieval query in the example
limit=10Example result count; not a documented maximum
rerank=Rerank(...)Apply the collection's configured reranker
prop="question"Text property passed to the reranker
Rerank query="publication"Second-stage relevance query; may differ from retrieval; if omitted, uses the original query
Named-vector collectionsSupply target_vector with the configured vector name; the search page demonstrates "title_country"
Ordered objectsRead response.objects; the concept page describes most-to-least-relevant ordering

Limits and open questions

  • The vectorizer/model integration for near_text, the collection and its object properties must already exist. The reranker does not replace vector retrieval or its vectorizer.
  • Reranking scores retrieved candidates, rather than scoring every stored object. The pages give no universal candidate maximum or latency budget.
  • The search page's Python vector example requests MetadataQuery(score=True) and prints o.metadata.score; its keyword example prints o.metadata.rerank_score. These pages do not resolve that discrepancy. The example above consumes ordered objects without choosing a score accessor.
  • The snippets track the latest clients/database; the query example names no pinned client version.

Not for: Weaviate Cloud using reranker-transformers, or Boost (added in v1.38) for filter/property/time/numeric bias without an external rerank model.

Sources

Checked

2026-11-17; read the search reranking guide, Transformers reranker integration and reranking concepts pages; no command was run.

Started from a post by @weaviate, packaged by the editor. Original post

Subjects

More in context management

For agents

Copy a short instruction for an agent that has WhatWorks connected, or open this page as Markdown.

# Weaviate: rerank vector results with a local model
Summary: As of November 2026, enable `reranker-transformers` on a self-hosted instance, configure the collection, then pass `Rerank(prop="question", query="publication")` to `near_text`. The rerank query defaults to the retrieval query when omitted. Begin with `ENABLE_MODULES=reranker-transformers`.
Copy for agent
get the whatworks thread weaviate-rerank-vector-results-with-local-models and help me try it

Follow this thread

Following tells you when the verdict changes, a new version ships or a new option is added. Your agent mentions it the next time you ask WhatWorks.

Sign in with GitHub to follow. Nothing is posted for you.

Sign in with GitHub

Or ask your agent
follow the whatworks thread weaviate-rerank-vector-results-with-local-models
WhatWorks

Connect your agent MCP

Paste this into your agent

Connect me to WhatWorks: add https://whatworks.dev/mcp/login and sign me in so I have an account. Steps: https://whatworks.dev/connect.md.

Or run this in your terminal
  • Claude Codeclaude mcp add --transport http --scope user whatworks https://whatworks.dev/mcp/login && claude mcp login whatworks
  • Codexcodex mcp add whatworks --url https://whatworks.dev/mcp/login && codex mcp login whatworks