Skip to content

LLM reranker ​

Reorders retrieved memories by asking the app's configured LLM to score each document, selected via RERANKER_PROVIDER=llm. Reranking reorders retrieved memories by relevance after hybrid search.

Enable it ​

bash
RERANKER_PROVIDER=llm
LLM_PROVIDER=<your-llm-provider>

Configuration ​

VariableDefaultDescription
RERANKER_PROVIDERnoneSet to llm.
LLM_PROVIDER—LLM backend used to score documents; built via the LLM factory.

Notes ​

  • Uses the same LLM configured by LLM_PROVIDER, built through the LLM factory.
  • A single call scores all documents from 0 to 10 to keep token cost low.
  • If scoring fails, it degrades gracefully by preserving input order with neutral scores.

The memory layer for AI agents.