In short.
Together AI's Rerank API guide is documentation for developers adding document relevance ranking to search or retrieval-augmented generation (RAG) applications. The main catch is that the rerank models it shows run only on dedicated endpoints you must bring up yourself, and the page gives no pricing. A reranker takes a query and a list of documents. It returns a relevancy score and an ordering index for each document, and it can trim the results to the top n. The page documents POST requests to [https://api.together.ai/v1/rerank]. It uses mixedbread-ai/mxbai-rerank-large-v2 for plain-string documents and Salesforce/Llama-Rank-V1 for JSON documents ranked over chosen fields. The page advertises 8K context per document and low latency, but supplies no measured benchmarks, pricing, maximum document count or maximum query length. Setup, runtime behavior, performance and sample-score reproducibility remain unverified.
Researched and written by an AI model and checked by a second AI model. How it works
The scope is the complete selected documentation page at [https://docs.together.ai/docs/inference/embeddings/rerank.md]. Linked pages are excluded. These include the rerank API reference pages [https://docs.together.ai/reference/rerank.md] and [https://docs.together.ai/reference/rerank-1.md], the dedicated endpoints overview [https://docs.together.ai/docs/dedicated-endpoints/overview.md], the endpoint configuration page [https://api.together.ai/endpoints/configure] and the docs index [https://docs.together.ai/llms.txt]. Together AI pricing, terms of service, data handling, model cards and other rerank endpoints are not covered. Setup, runtime behavior, performance and sample-score reproducibility remain unverified. The code samples, the API, the named models and the sample scores are described only as the page states them.
The overview
What this resource is
This is a single documentation page titled Rerank, from Together AI's docs site [https://docs.together.ai/docs/inference/embeddings/rerank.md]. It teaches one feature: using Together's rerank API to reorder retrieved documents by relevance to a query. It is not a library, model or standalone product. It is a guide to calling a hosted API.
The page is hosted on Mintlify, a documentation platform, and sits in the docs under inference and embeddings. It links to the API reference, a dedicated endpoints overview and an index file. Those linked pages are not covered here.
Overall assessment
The page is a short, practical how-to. It explains what reranking is, where it sits in a RAG pipeline, and how to call the endpoint. It has code samples in three languages and one sample response. For a developer who already uses Together AI, or is considering it, it is a clear starting point.
It leaves out much of what you would need to plan a real deployment: pricing, rate limits, maximum documents per request, accuracy figures, supported languages and a full model list. It also leaves one difference unexplained. The string-input examples read response.results, but the only sample response belongs to the separate JSON example and uses a choices array (see limitations). Treat the page as an introduction to the API, not a full specification.
Who it is for
The page suits developers who already have a first-stage retrieval step, such as vector search or keyword search, and want a second stage that reorders the candidates before they go to a language model. The page describes reranking as a quality filter between initial retrieval and final generation.
Beginners can follow the explanation of what a reranker does, but the code samples assume some prior skills, and which ones depend on how you call the API. The cURL route assumes you can send an HTTP request from a shell and pass a Together AI API key as a bearer token from the TOGETHER_API_KEY environment variable. It needs neither SDK. The Python and TypeScript routes assume you can run code in those languages using the packages imported as together and together-ai. For those routes, the page does not show installation or say how the SDKs load your credentials. Whichever route you choose, the page assumes you can bring up a dedicated model endpoint, and it does not explain how that works. It is a poor fit for anyone who needs a serverless, pay-per-request rerank call with no endpoint to manage, because the page says the named rerank models are dedicated-only.
What it covers and what the API can do
According to the page, the rerank API takes a query and a list of documents. It returns a relevancy score and an ordering index for each document, and the top_n parameter can limit the response to the most relevant documents. The page lists two key features: a long 8K context per document (the unit is not stated) and low latency for fast search queries. It gives no latency figures.
Two input styles are documented. The first is a plain list of strings, shown with mixedbread-ai/mxbai-rerank-large-v2. The second is a list of JSON objects with the keys from, to, date, subject and text, shown with Salesforce/Llama-Rank-V1. In the second style, a rank_fields parameter names which keys to rank over and in what order. If rank_fields is left out, the model defaults to the text key. A return_documents option makes the response include each document next to its ranking.
Using it
Requirements
The page shows three ways to call the API. The Python examples import a package named together. The TypeScript examples import a package named together-ai. The cURL example calls the REST endpoint directly and needs neither SDK. All three routes need a Together AI API key, but only the cURL example shows how to supply it: as a bearer token taken from the TOGETHER_API_KEY environment variable. The Python and TypeScript examples create the client with no arguments, and the page does not say how those SDKs load credentials. Installation commands and supported package versions are also not given.
The most important requirement is a dedicated endpoint. A tip on the page says rerank models like mxbai-rerank-large-v2 are only available for dedicated model inference, and that you must bring up a dedicated endpoint to use reranking. A note says the JSON format with rank_fields is only supported on dedicated inference running Salesforce/Llama-Rank-V1. The page does not say how long an endpoint takes to start, what hardware it uses, or what account type or credits you need.
How it works
A reranker is a model that scores each document against a query and returns the scores so the documents can be sorted. In a RAG pipeline, you retrieve a set of candidates, rerank them, keep the most relevant ones, and pass those to the language model. The page presents this as a way to ground the answer in the most relevant context.
The API is a single POST to [https://api.together.ai/v1/rerank] with a bearer token. The request body holds the model name, the query and the documents, plus the optional top_n, return_documents and rank_fields. The page does not explain how the models work internally or how the score is computed. In its sample JSON response, scores are numbers between 0 and 1, and results are listed from highest to lowest score. The page does not formally state the score scale or say whether scores can be compared across queries.
Setup
Based on the page, setup has three parts. First, get a Together AI API key. Second, create a dedicated endpoint for the rerank model you want, using the link the page gives [https://api.together.ai/endpoints/configure]. Third, call the API in one of three ways: client.rerank.create from the Python package imported as together, client.rerank.create from the TypeScript package imported as together-ai, or a cURL POST to [https://api.together.ai/v1/rerank] that passes the key as a bearer token from TOGETHER_API_KEY. For the two SDK routes, the page does not say how the key is supplied, how to install the packages or which versions are supported.
The page does not walk through creating the dedicated endpoint. It points to a dedicated endpoints overview [https://docs.together.ai/docs/dedicated-endpoints/overview.md], but that page is not covered here. The page also does not say whether the model name in the request must match the endpoint's model, or whether endpoints have their own identifiers. Setup, runtime behavior, performance and sample-score reproducibility remain unverified.
Worked example from the page
The first example reranks four short texts about animals (giant panda, llama, wild Bactrian camel and guanaco) against the query What animals can I find near Peru?. It calls client.rerank.create with the model mixedbread-ai/mxbai-rerank-large-v2 and top_n set to 2. It then prints each result's index, the matching document and its relevance_score. The page shows no output for this example.
The second example uses Salesforce/Llama-Rank-V1 to rank six email objects against the query Which pricing did we get from Oracle?. It sets return_documents to true and rank_fields to from, to, date, subject and text. The page includes a sample response for this example. It lists the two Oracle emails first: the original pricing email scores about 0.61 and a later price-adjustment email about 0.51. The two Microsoft emails follow at about 0.23 and 0.22, and the unrelated marketing and airline emails score near zero. In this published sample, the older Oracle pricing email ranks above the later amendment. This does not establish a general recency rule or show which email should determine the current price.
Assessment & evidence
Limitations and caveats
Access is limited. The page says the rerank models it names are only available on dedicated endpoints, and that the JSON format with rank_fields works only with Salesforce/Llama-Rank-V1 on dedicated inference. It says all other rerank endpoints accept documents only as a list of strings, but it does not say which endpoints those are or which models they serve.
The page leaves one difference unexplained. The string-input Python and TypeScript examples use mixedbread-ai/mxbai-rerank-large-v2 and read response.results. The separate Salesforce/Llama-Rank-V1 JSON example prints the whole response, and its sample response has a top-level choices array containing index, document and relevance_score. Different models, input formats or SDK representations could explain the difference, and the page does not show that the two are incompatible. How the SDK response objects map to the HTTP response is unknown. The API reference [https://docs.together.ai/reference/rerank.md] may say more, but it is not covered here.
Other missing details include the maximum number of documents per call, the maximum query length, whether the 8K figure counts tokens, rate limits, supported languages, score calibration, latency numbers and any accuracy comparison. The low-latency and long-context claims come without measurements. The page also gives no guidance on how many candidates to retrieve before reranking or how to choose top_n.
Why the page recommends reranking
The page's case for reranking is that it filters and prioritizes the most relevant results. In RAG pipelines, it places reranking between initial retrieval and final generation as a quality filter. Reranking refines the documents passed to the language model so that the answer is grounded in the most relevant context.
The page presents this purpose without measured evidence. It gives no figures for retrieval quality, answer quality or latency, so any improvement from adding reranking is not established. Setup, runtime behavior, performance and sample-score reproducibility remain unverified.
Alternatives and related options
The page documents two paths. For documents supplied as a list of strings, it shows mixedbread-ai/mxbai-rerank-large-v2. For structured documents, it shows Salesforce/Llama-Rank-V1. That model accepts JSON objects and a rank_fields parameter that names which keys to rank over and in what order. The page says this format is supported only on dedicated inference running that model.
The page's statement that all other rerank endpoints accept documents only as a list of strings is an input-format restriction. It does not describe any further hosting, availability or billing options. The page does not describe or compare external alternatives.
Evidence base
The source is the documentation page at [https://docs.together.ai/docs/inference/embeddings/rerank.md]. It documents POST requests to [https://api.together.ai/v1/rerank] and the parameters model, query, documents, top_n, return_documents and rank_fields. It names two models, mixedbread-ai/mxbai-rerank-large-v2 and Salesforce/Llama-Rank-V1. It gives Python, TypeScript and cURL examples for both string and JSON documents, plus one sample JSON response for the Salesforce/Llama-Rank-V1 email example.
No other source is covered. Setup, runtime behavior, performance and sample-score reproducibility remain unverified.
Access & freshness
Costs
The page states no prices. Request pricing, dedicated endpoint charges, billing units and any free allowances or credits are all unknown from this page. The page also does not explain how dedicated endpoints are billed. Check Together AI's pricing pages before planning a budget.
Rights and licensing
The page shows no licence and no copyright notice for the documentation text or the code samples. It does not state the licences of the two named models (mixedbread-ai/mxbai-rerank-large-v2 and Salesforce/Llama-Rank-V1) or the terms of use for the Together AI service, so those terms are unknown. Check the model cards and Together AI's terms before using the models commercially or sending confidential documents to the API.
The page also does not say how Together AI handles the queries and documents you send, including retention, use for training and where the data is processed. That is unknown. It matters for the email-style example, which suggests sending business correspondence.
Freshness
The page was captured on 15 November 2026. It shows no publication date, last-updated date or version number, so its age is unknown. Model names, endpoint availability and the response format may have changed since the page was written, or may change later. Hosted-model documentation tends to change, so check the live page and the API reference before relying on specific model names or parameters.
Suggested next steps
If you already use Together AI and have a RAG or search pipeline, read this page first. Then read the API reference [https://docs.together.ai/reference/rerank.md] and the dedicated endpoints overview [https://docs.together.ai/docs/dedicated-endpoints/overview.md]. Find out what a dedicated endpoint costs before you commit. Try a small batch of your own queries and documents, and compare the ranking with and without reranking on your own data. For the model and SDK version you choose, inspect the response once to see which fields it contains. The page shows results in the string-input examples and choices in the JSON sample response, and it does not explain why.
If you need a pay-per-request rerank call with no endpoint to run, or need detailed limits and licence terms, this page is not enough on its own.
