From eb03f9dc184d76f8caa613b473f376a046573809 Mon Sep 17 00:00:00 2001 From: Haystack Bot <73523382+HaystackBot@users.noreply.github.com> Date: Tue, 6 Oct 2026 10:02:19 +0200 Subject: [PATCH] docs: sync Haystack API reference on Docusaurus (#13130) Co-authored-by: sjrl <10526848+sjrl@users.noreply.github.com> --- docs-website/reference/haystack-api/rankers_api.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs-website/reference/haystack-api/rankers_api.md b/docs-website/reference/haystack-api/rankers_api.md index 147d9309d6..cb2a3f7188 100644 --- a/docs-website/reference/haystack-api/rankers_api.md +++ b/docs-website/reference/haystack-api/rankers_api.md @@ -16,8 +16,8 @@ The LLM is expected to return a JSON object containing ranked document indices. are kept, so the output can contain fewer than `top_k` documents, or none if the LLM considers none relevant. If the query is empty, or if generation or parsing fails and `raise_on_failure` is `False`, the ranker falls back -to the deduplicated input documents in their original order. `top_k` is not applied to these fallback documents: -the input documents aren't necessarily sorted by relevance, so cutting them off could drop relevant ones. +to the deduplicated input documents, unranked and in their original order. `top_k` is not applied to them, since +cutting off unranked documents could drop relevant ones. Usage example: @@ -89,7 +89,7 @@ Initialize the LLMRanker component. - **top_k** (int) – The maximum number of ranked documents to return. Not applied when the ranker falls back to the input documents. - **raise_on_failure** (bool) – If `True`, raise when generation or response parsing fails. If `False`, log the failure and return all - deduplicated input documents in their original order, without applying `top_k`. + deduplicated input documents unranked, in their original order, without applying `top_k`. **Raises:** @@ -180,7 +180,7 @@ Before ranking, duplicate documents are removed. - dict\[str, list\[Document\]\] – A dictionary with the following key: - `documents`: Up to `top_k` documents the LLM considers relevant, from most to least relevant. If `query` is empty, or if generation or parsing fails and `raise_on_failure` is `False`, all deduplicated - input documents in their original order. + input documents unranked, in their original order. **Raises:** @@ -214,7 +214,7 @@ but can be used with `await` in an async code. If the chat generator only implem - dict\[str, list\[Document\]\] – A dictionary with the following key: - `documents`: Up to `top_k` documents the LLM considers relevant, from most to least relevant. If `query` is empty, or if generation or parsing fails and `raise_on_failure` is `False`, all deduplicated - input documents in their original order. + input documents unranked, in their original order. **Raises:**