Reranker Node

Overview

The Reranker Node optimizes document retrieval by reordering a set of documents based on their relevance to a specific query. It uses specialized reranking models to improve the accuracy and relevance of search results by considering semantic similarity and contextual information.

Usage cost: 1 credit

Configuration

Settings

  1. Model Selection

    • Reranker Model*: Select the reranking model to use

    • Top K: Number of documents to return after reranking (default: 3)

    • Query*: The search query used to rerank documents

    • Documents*: List of documents to be reranked

Output Ports

  • reranked_documents (Document[]): Array of reranked documents ordered by relevance

Best Practices

  1. Document Preparation

    • Keep document segments concise and focused

    • Ensure documents contain meaningful content

    • Remove duplicate or near-duplicate content

  2. Query Optimization

    • Use specific, targeted queries

    • Include key terms and concepts

    • Consider query expansion when needed

    • Use consistent query formatting

  3. Performance Tuning

    • Adjust Top K based on use case requirements

    • Consider document batch size

  4. Integration Tips

    • Place after retrieval nodes

    • Connect to document transformation nodes when needed

Last updated