From 98380cff9b0a7ca576567d5e312995a257e15cc6 Mon Sep 17 00:00:00 2001 From: Maxime Perrin <63123596+maximeperrindev@users.noreply.github.com> Date: Fri, 1 Mar 2024 21:05:09 +0100 Subject: [PATCH] community[patch]: removing "response_mode" parameter in llama_index retriever (#18180) - **Description:** Removing this line ```python response = index.query(query, response_mode="no_text", **self.query_kwargs) ``` to ```python response = index.query(query, **self.query_kwargs) ``` Since llama index query does not support response_mode anymore : ``` | TypeError: BaseQueryEngine.query() got an unexpected keyword argument 'response_mode'```` - **Twitter handle:** @maximeperrin_ --------- Co-authored-by: Maxime Perrin --- libs/community/langchain_community/retrievers/llama_index.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/community/langchain_community/retrievers/llama_index.py b/libs/community/langchain_community/retrievers/llama_index.py index 49d7e242e37..9106c058d75 100644 --- a/libs/community/langchain_community/retrievers/llama_index.py +++ b/libs/community/langchain_community/retrievers/llama_index.py @@ -30,7 +30,7 @@ class LlamaIndexRetriever(BaseRetriever): ) index = cast(BaseGPTIndex, self.index) - response = index.query(query, response_mode="no_text", **self.query_kwargs) + response = index.query(query, **self.query_kwargs) response = cast(Response, response) # parse source nodes docs = []