Skip to content

Feature: Add a post-processing hook for cross-encoder reranking #226

Description

@jamie-ons

Description

We should add a custom search_postprocess hook to allow reranking of retrieved results using a Hugging Face cross-encoder.

While the standard bi-encoder VectorStore.search() is fast, we can get much higher accuracy by passing the top retrieved results through a cross-encoder model that scores the query and document together.

Specifically, we want to try out huggingface models such as BAAI/bge-reranker-v2-m3. It has excellent benchmark performance and has very low compute requirements.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions