Cohere Rerank API for Production RAG
Boost RAG accuracy by 40% with Cohere's Rerank API: simple integration, multilingual support, production-ready.
Why Cohere Rerank?
- ✅ 40% accuracy improvement over bi-encoders
- ✅ 100+ languages supported
- ✅ Hosted API (no model hosting)
- ✅ Fast (< 200ms for 100 docs)
Quick Start
DEVELOPERpythonimport cohere co = cohere.Client('YOUR_API_KEY') def rerank_with_cohere(query, documents): results = co.rerank( model='rerank-v3.5', # unified multilingual model query=query, documents=documents, top_n=10 ) return [doc['text'] for doc in results.results] # Use it retrieved_docs = vector_search(query, k=100) reranked = rerank_with_cohere(query, retrieved_docs)
Models (November 2025)
rerank-v3.5 (data: July 2026)
- Unified multilingual (replaces the separate v3.0 English/multilingual models)
- 100+ languages
- $1 per 1000 searches
- 4k token context
rerank-v4.0-fast / rerank-v4.0-pro
- Newest generation, 100+ languages
- Larger 32k token context
- $2 / $2.50 per 1000 searches
The rerank-english-v3.0 and rerank-multilingual-v3.0 models are still available but are now superseded by the unified rerank-v3.5 multilingual model.
With Metadata
DEVELOPERpythonresults = co.rerank( query=query, documents=[ {"text": doc, "metadata": {"source": "wiki", "date": "2025"}} for doc in documents ], top_n=10, return_documents=True ) for r in results.results: print(f"Score: {r.relevance_score}") print(f"Text: {r.document['text']}") print(f"Metadata: {r.document['metadata']}")
Cost Optimization
DEVELOPERpython# Only rerank if initial score is low def smart_rerank(query, initial_results, threshold=0.7): # If top result has high confidence, skip reranking if initial_results[0]['score'] > threshold: return initial_results[:10] # Otherwise, rerank return rerank_with_cohere(query, [r['text'] for r in initial_results])
Cohere Rerank is the easiest way to dramatically improve RAG accuracy. Just plug it in after retrieval.
Tags
Related Posts
Reranking for RAG: +40% Accuracy with Cross-Encoders (2025 Guide)
Boost RAG accuracy by 40% using reranking. Complete guide to cross-encoders, Cohere Rerank API, and ColBERT for production retrieval systems.
LLM Reranking: Using LLMs to Reorder Your Results
LLMs can rerank search results with deep contextual understanding. Learn when and how to use this expensive but powerful technique.
Cross-Encoder Reranking for RAG Precision
Achieve 95%+ precision: use cross-encoders to rerank retrieved documents and eliminate false positives.