Skip to main content
Rerank v5.0 Pro sorts retrieved documents by relevance to a query. Use it for quality-critical retrieval and complex queries before passing selected passages to an LLM. Retrieve candidate documents first, then rerank them. The response contains relevance scores and original document indexes, not generated answers or embedding vectors. Send requests to /v1/rerank on MixRoute.

Model information

The provider context window is 32,768 tokens for each query/document pair, not for the whole document list. Effective request limits depend on the MixRoute route.

Request fields

Request examples

Set MIXROUTE_API_KEY. The Python example uses the requests package.

Response fields

results[].index is the zero-based position in your original documents array. results[].relevance_score is the relevance score; larger values indicate a stronger match. Read results[].document.text only when document text is returned.

Usage and billing

Use usage.prompt_tokens and usage.total_tokens for the reported token usage. Reranking does not generate answer text, so usage.completion_tokens can be 0. Other generic token fields are not a substitute for these fields. Prices and available routes are listed in the Model Marketplace. The console Usage Logs show the charge for each request; use those records for billing reconciliation rather than treating the usage object as a dollar amount. Complete request format.