Skip to content

Add reranker #26

@carlosmada22

Description

@carlosmada22

A reranker is a more sophisticated model that takes the smaller list of documents from the retriever and re-scores them based on their actual relevance to the user's specific query

The reranker model (often a "cross-encoder") looks at the user's query and each document at the same time, which allows it to make a much more accurate judgment than the vector search alone.

The new workflow will be:
User Query -> Embed -> Retrieve Top 20 -> Rerank to find the actual Top 5 -> Generate Answer

This adds a small amount of processing time but dramatically increases the chance that the context given to the LLM is the best possible, leading to much better answers.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions