Rerank items
Using a reranker to rerank a list of items for a query
This feature is in public preview.
The rerank
endpoint is only available to organizations on the Standard or Enterprise plans.
To use the Inference API with the Python SDK, upgrade the SDK and install the pinecone-plugin-inference
package as follows:
pip install --upgrade pinecone
pip install --upgrade --pre pinecone-plugin-inference==1.1.0.*
Authorizations
An API Key is required to call Pinecone APIs. Get yours from the console.
Body
Model to use for reranking.
The query to rerank documents against.
The number of results to return sorted by relevance. Defaults to the number of inputs.
Whether to return the documents in the response.
The fields to rank the documents by. If not provided the default is text.
The documents to rerank.
Additional model specific parameters for the reranker.
Response
The model used for reranking
The reranked documents
Usage statistics for the inference
Was this page helpful?