🦞 Give OpenClaw superpowered memory with one command
Install Skill
All Integrations

Cohere

Search Result Reranking

Cohere's reranking models improve search relevance by reordering results using cross-encoder scoring. Get the most relevant results at the top.

99+
Languages
~$1.00
Per 1K Docs
Top-N
Selection
0-1
Relevance Score
# Configure in your environment
export COHERE_API_KEY=...

What is Reranking?

Reranking is a two-stage retrieval technique that improves search quality beyond initial vector similarity.

1

Initial Retrieval

The Searcher agent uses embeddings to find candidates quickly.

Query: "authentication problems"
Login timeout issue 0.89
JWT token expired 0.87
Session cookie settings 0.85
Password reset flow 0.84
2

Cohere Reranking

Cross-encoder analyzes query-document pairs for true relevance.

Reranked Results:
JWT token expired 0.94
Login timeout issue 0.91
Session cookie settings 0.72
Password reset flow 0.45

Why Two Stages?

Embeddings are fast but approximate. Cross-encoders are slow but precise. By using embeddings to narrow down candidates (100 -> 20) and then reranking the top results, you get the best of both worlds: speed AND accuracy.

Available Models

rerank-english-v3.0

Default

Optimized for English language content. Best performance for English-only knowledge bases.

  • Highest accuracy for English
  • Faster inference
  • Recommended for most users

rerank-multilingual-v3.0

Optional

Supports 100+ languages. Use for multilingual knowledge bases or non-English content.

  • 100+ language support
  • Cross-lingual matching
  • Same pricing as English

How It Works

# Reranking API call example
{
  "query": "authentication problems",
  "documents": [
    "Login timeout issue in production",
    "JWT token expired after 24 hours",
    "Session cookie settings guide",
    "Password reset flow documentation"
  ],
  "top_n": 3,
  "model": "rerank-english-v3.0"
}
# Response with relevance scores
{
  "results": [
    {
      "index": 1,
      "relevance_score": 0.94,
      "document": "JWT token expired after 24 hours"
    },
    {
      "index": 0,
      "relevance_score": 0.91,
      "document": "Login timeout issue in production"
    },
    {
      "index": 2,
      "relevance_score": 0.72,
      "document": "Session cookie settings guide"
    }
  ]
}

Configuration

Settings

Default Model
rerank-english-v3.0
Default Top-N
10 results
Return Documents
true (optional)

Environment Variables

# Required for reranking
COHERE_API_KEY=...
# Optional: Use multilingual model
COHERE_MODEL=rerank-multilingual-v3.0

Optional Enhancement

Cohere reranking is optional. If no API key is configured, search results will use embedding similarity scores only. Add Cohere when you want to improve result quality.

Pricing

~$1.00
per 1,000 documents reranked
10
searches
~$0.01
100
searches
~$0.10
1,000
searches
~$1.00

Based on reranking 10 documents per search. Actual cost depends on documents per query.

Quick Setup

1

Get an API Key

Create an account at dashboard.cohere.com and generate an API key.

2

Configure Onelist

# Add to your .env file
COHERE_API_KEY=...
3

Restart Onelist

docker-compose restart

Search with Better Results

All semantic searches now use Cohere reranking automatically.

Improve Your Search Quality

Add Cohere reranking to get the most relevant results first.