Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Add reranking configuration guide #2489

Merged
merged 1 commit into from
Apr 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions docs/configuring/reranking.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
title: Reranking
description: Learn how to configure reranking in Quivr.
---

Quivr uses its own reranking service to improve the quality of search results. This guide will show you how to configure the reranking service in Quivr.

## Reranking Configuration

We are using FlashrankRerank from [Flashrank](https://github.com/PrithivirajDamodaran/FlashRank) to improve the quality of search results.
It is a reranking open-source library that uses deep learning models to rerank search results.

## Use Cohere ReRanker

To use the Cohere ReRanker, you need to configure the following environment variables in your `.env` file:

```bash
COHERE_API_KEY=your-cohere-api-key
```

By default, the `COHERE_API_KEY` variable is not set. If you want to use the Cohere ReRanker, you need to set it to your Cohere API key.

## Configuration

By default the Ranker outputs the best 5 results.

We only use the Cohere ReRanker to improve the quality of search results. We do not collect any personal data or sensitive information.

28 changes: 23 additions & 5 deletions docs/mint.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,23 +60,41 @@
{
"group": "Configuring",
"icon": "gear",
"pages": ["configuring/authentication", "configuring/new-model", "configuring/increase-user-usage", "configuring/resend-emails", "configuring/environment-variables", "configuring/telemetry"]
"pages": [
"configuring/authentication",
"configuring/new-model",
"configuring/increase-user-usage",
"configuring/resend-emails",
"configuring/reranking",
"configuring/environment-variables",
"configuring/telemetry"
]
},
"tech-design",
"contact-us"
]
},
{
"group": "Deploy Quivr",
"pages": ["deployment/porter", "deployment/aws", "deployment/digital_ocean"]
"pages": [
"deployment/porter",
"deployment/aws",
"deployment/digital_ocean"
]
},
{
"group": "Brains",
"pages": [ "brains/docs-and-urls","brains/gpt4", "brains/sql"]
"pages": [
"brains/docs-and-urls",
"brains/gpt4",
"brains/sql"
]
},
{
"group": "Assistants",
"pages": ["agents/summary"]
"pages": [
"agents/summary"
]
}
],
"footerSocials": {
Expand All @@ -103,4 +121,4 @@
"apiHost": "https://us.posthog.com"
}
}
}
}