VoyageAI by MongoDB: rerank-3
Voyage rerank-3 is the quality-focused Rerank 3 edition for scoring query-document relevance. It reorders retrieved text candidates, supports natural-language relevance instructions and handles 32,000-token pairs for long-document, code and knowledge-base search.
About the model
This description covers the model’s capabilities. Available in Ailoot inputs, outputs and options are listed for the selected method below.
Voyage rerank-3 is a text reranker designed to improve the quality of retrieved evidence. Given a query and a list of candidate documents, it jointly examines each pair and returns the candidates ordered by relevance. Embeddings and keyword search can first narrow a large collection to a manageable shortlist; rerank-3 then applies more detailed relevance assessment to that shortlist. Its output is scored search evidence for an application to display or pass into a separate answer-generation step.
Quality-focused Rerank 3 The maker positions rerank-3 as the accuracy-focused edition and rerank-3-lite as the edition for latency-sensitive search. The third generation updates the backbone and training mixture, with particular improvements on long-document and source-code retrieval compared with the corresponding 2.5 predecessors. The producer evaluates it across technical documentation, code, multilingual material and other document domains. Those results support its retrieval role; select the edition using the questions and candidate documents that matter to your own collection.
Long documents with enough context A long candidate can contain useful context well beyond its opening paragraph. Supply a coherent section or document with its title and relevant surrounding material, so the model can assess how the actual question relates to the content. For a product-policy search, preserve headings and exceptions around the passage of interest. If several retrieved sections come from the same source, retain their document and section identifiers; the application can then show where the selected evidence originated.
The context window is shared by the query and each candidate. The current maker guide specifies 32,000 tokens for that pair, including a query of at most 8,000 tokens. A 3,000-token query therefore leaves at most 29,000 tokens for each document. Prepare the input so its essential content fits, particularly when a long preamble or repeated boilerplate would otherwise consume the window. The documented truncation option defaults to enabled and can shorten oversized query or document text before scoring. Inspect what is retained when passage placement matters.
Code and technical retrieval For a coding assistant’s retrieval stage, candidates can contain function implementations, API documentation or technical explanations as text. Include the symbols, signatures and context needed to distinguish similar candidates. A query such as “Find the function that normalizes paths while preserving a trailing separator” gives a concrete behaviour to match. Attach any relevant language, platform or version constraints. After ranking, examine the selected code and its dependencies before using it as context; a relevance score does not prove that an implementation satisfies every stated requirement.
Instructions define relevance The model retains the instruction-following reranking capability introduced in Rerank 2.5. Prepend or append a concise instruction to the query when the user’s intent needs clarification. For research-document search, explain whether the focus is the title, a particular method or an application domain. For an internal catalogue, specify whether the request concerns installation, troubleshooting or compatibility. Keep that instruction aligned with the question; extra preferences that conflict with the main request can change what the ranking is trying to optimize.
Prepare candidate documents and budgets The input is a list of text strings. Extract usable text from source documents, preserve meaningful section boundaries and keep an ordered record map alongside the list. The maker allows up to 1,000 documents in one request. It also specifies an aggregate input ceiling of 600,000 tokens: query tokens multiplied by the number of documents, plus the sum of all document tokens. This differs from the per-pair context limit. Reducing redundant query text can preserve both pair capacity and the overall request budget.
Count tokens for the relevant model, rather than assuming that a word or character count is a token count. For large candidates, select coherent passages or divide the material by useful headings while retaining parent-source information. Reranking is most useful after the first search has already surfaced plausible candidates: it cannot rank a missing source that never entered the list.
Ranked results and downstream use The result contains relevance scores and indices referring to the original input documents, sorted in descending relevance order. The top_k option limits the number of ranked results returned; otherwise all input candidates are returned. The maker’s REST interface also allows the document text to be included. Use each original index to recover the title, source identifier and any metadata your application needs, then present the selected items or pack the relevant text into an answer’s evidence context.
Inspect the top results against the question and keep source identity visible. A high relative rank does not verify a document’s factual accuracy, and a shortlist containing only poor candidates will still have a first item. Separate relevance selection from deciding whether the selected evidence is sufficient to answer the user.
Edition migration The maker describes rerank-3 as a drop-in successor to rerank-2.5, with the same API semantics and scores calibrated to its corresponding predecessor’s distribution. That compatibility supports retaining an existing retrieval stage and record mapping. Compare meaningful result orderings and any score cutoff on the current corpus before relying on the migration. Keep rerank-3 and rerank-3-lite as distinct choices: shared limits and instruction following do not make their quality and latency priorities identical.
Ailoot Ultra · Rerank POST /v1/rerank voyageai/rerank-3
voyageai/rerank-3Overview
Voyage rerank-3 is the quality-focused Rerank 3 edition for scoring query-document relevance. It reorders retrieved text candidates, supports natural-language relevance instructions and handles 32,000-token pairs for long-document, code and knowledge-base search.
- Accepted inputs
- Text
- Results
- Ranked results
Available in Ailoot · inputs & methods
Ailoot Ultra · Rerank POST /v1/rerank
- Input types
text- Output types
rerank- Output format
- json
| Field | Type | Requirement | Values & limits | Default |
|---|---|---|---|---|
Fielddocuments | Typearray | RequirementRequired | Values & limits | Default— |
Fieldmodel | Typestring | RequirementRequired | Values & limits voyageai/rerank-3 | Default— |
Fieldprovider | Typeschema | RequirementOptional | Values & limits | Default— |
Fieldquery | Typestring | RequirementRequired | Values & limits | Default— |
Fieldsession_id | Typestring | RequirementOptional | Values & limits | Default— |
Fieldtop_n | Typeinteger | RequirementOptional | Values & limits Minimum: 1 | Default— |
Fieldtrace | Typeschema | RequirementOptional | Values & limits | Default— |
Fielduser | Typestring | RequirementOptional | Values & limits | Default— |
Fielddocuments[].text | Typestring | RequirementOptional | Values & limits | Default— |
Fielddocuments[].image | Typestring | RequirementOptional | Values & limits | Default— |
Input material combinations
text_rerank · Required: query, documents array with minItems1
Method parameters and lifecycle
| Parameter | Contract |
|---|---|
Parametercontent_type | Contractapplication/json |
Parameterrequired | Contractmodel, query, documents |
Parametermaterial_types | Contracttext |
Parameteroptional_controls | Contractprovider, session_id, top_n, trace, user |
Parametermultimodal_input_binding | Contractnull |
Lifecycle: synchronous
Send the exact model ID and retain the complete native response.
Pricing
Tariff references do not add request options. Supported parameters are listed for the selected method.
- Fast mode
- Not specified When fast mode is selected
- Flex mode
- Not specified When flex mode is selected
- Maximum reasoning effort
- Not specified When maximum reasoning effort uses the default adjustment
Ailoot rates
Prices by configuration
Match each charge to the conditions shown. Use one rate for each set of alternative configurations.
| Configuration | Rate schedule | Billing unit | Charge |
|---|---|---|---|
| ConfigurationBase token rates | Rate scheduleBase rate | Billing unit— | Charge Input · Input tokens — / 1K tokens Output · Output tokens — / 1K tokens Input · Cache read — / 1K tokens Input · Cache write — / 1K tokens Input · Cache write, 1 hour — / 1K tokens |
| ConfigurationUltra | Rate schedule— | Billing unit/ 1K tokens | Charge Input · input token $0.0001 / 1K tokens |
Ailoot reserves an estimated amount before a request. After the result, it settles the final charge from measured usage. Streaming settlement uses the final usage record. How reservation and settlement work →
Example requests
Ailoot Ultra · Rerank
{
"documents": [
"Paris is the capital of France.",
"Berlin is the capital of Germany."
],
"model": "voyageai/rerank-3",
"query": "What is the capital of France?",
"top_n": 3
}set -eu
: "${AILOOT_API_KEY:?Set your Ailoot API key}"
: "${AILOOT_REQUEST_FILE:?Set your actual JSON request file}"
export AILOOT_REQUEST_FILE
python3 - <<'PY_REQUEST'
import json,os
from pathlib import Path
p=json.loads(Path(os.environ['AILOOT_REQUEST_FILE']).read_text(encoding='utf-8'))
if not isinstance(p,dict): raise SystemExit('Request must be a JSON object')
p['model']='voyageai/rerank-3'
Path('request.json').write_text(json.dumps(p,ensure_ascii=False),encoding='utf-8')
PY_REQUEST
curl --fail-with-body --silent --show-error https://api.ailoot.ai/v1/rerank \
-H "Authorization: Bearer $AILOOT_API_KEY" -H 'Content-Type: application/json' \
--data-binary @request.json -D response-headers.txt -o result.json
python3 - <<'PY_RESULT'
import json
from pathlib import Path
print(json.dumps(json.loads(Path('result.json').read_text()),ensure_ascii=False,indent=2))
PY_RESULT
Receive and save results
Ailoot Ultra · Rerank
json
Keep all completed results
Keep every complete returned response, file and content part.
Every actual result index, finite relevance_score and original document object is retained. Indices bind the original document array. Entire original JSON is stored and returned only after settlement.
If the original response needs checking
Preserve original operation and full/partial reply; do not replay POST.
Response fields
| Field | Type |
|---|---|
Fieldmodel | Typestring |
Fieldid | Typestring |
Fieldprovider | Typestring |
Fieldresults[].index | Typeinteger |
Fieldresults[].relevance_score | Typenumber |
Fieldresults[].document.text | Typestring |
Fieldresults[].document.image | Typestring |
Fieldusage.search_units | Typeinteger |
Fieldusage.total_tokens | Typeinteger |
Fieldusage.cost | Typenumber |
Errors and next steps
| Response | Condition | Next step |
|---|---|---|
Response400 · invalid_request_error | ConditionInvalid required field, representation or value | Next stepCorrect the indicated request field. |
Aliases
Model aliases
Ailoot Ultra voyageai/rerank-3
Method path aliases
Use the method paths shown above.
Related caller IDs
FAQ · VoyageAI by MongoDB: rerank-3
- What inputs and results are available?
POST /v1/rerank·voyageai/rerank-3:text→rerank- Which fields does the request use?
POST /v1/rerank·voyageai/rerank-3:documents,model,provider,query,session_id,top_n,trace,user- What limits apply?
POST /v1/rerank·voyageai/rerank-3:top_n.minimum:1