Rerank documents
Sort candidate documents by semantic relevance to a query. Returns each
document’s original index plus a 0-1 relevance score (higher = more
relevant). Score is relative to the request and not comparable across
requests.
Built for RAG and search refinement: feed in the top-N hits from your vector store / BM25 / hybrid retriever, and the model returns a tighter, better-ordered shortlist.
Authentication
Pass your EmpirioLabs API key as a bearer token. The Anthropic-style
x-api-key header is also accepted on every endpoint.
Request
Reranking model id, for example qwen3-rerank.
Number of top-ranked documents to return. Defaults to all.
Custom English instruction guiding the sort. Defaults to a Q&A
retrieval policy. Pass "Retrieve semantically similar text." for
similarity sorting.
