Reranker API is live
Amanai now supports query-document reranking through POST /v1/rerank. Send a query and a candidate list, then receive the strongest matches in descending relevance order.
What changed
amanai/bge-reranker-base. top_n result limit. Using reranking
Pass your AmanAI API key with a JSON request:
curl https://api.amanai.dev/v1/rerank \
-H "Authorization: Bearer $AMANAI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "amanai/bge-reranker-base",
"query": "best way to learn Indonesian",
"documents": [
"Practice with native speakers every day.",
"A guide to baking sourdough bread.",
"Build vocabulary with spaced repetition."
],
"top_n": 2
}' The response contains each selected document's original array index and a relevance score, ordered from highest to lowest.
Limits & languages
| Field | Limit |
|---|---|
query | 2,048 characters |
documents | 1–100 strings |
| Each document | 8,192 characters |
| Request body | 1 MiB |
Language guidance. The model performs best when the query and documents use the same language, including Indonesian or English. For mixed-language corpora, retrieve candidates with amanai/bge-m3 first and validate ranking quality on your own data.
Billing
BGE reranking now costs 0.25 credit per token across the query and all candidate documents, with a 250-credit minimum per successful request. Quote an estimated token count with GET /calculate?model=amanai/bge-reranker-base&input=N. See current rerank rates for updates.
Requests rejected before a result is delivered are not charged. Reranking currently requires an eligible paid credit balance.
Availability
Discover the model with GET /v1/models?type=rerank using an API key. See the dedicated Rerank guide, Billing & pricing, credit calculator, and status page for details.
amanai/bge-reranker-base