From 72d4a8eeed8e428cd718073a39125a1f5a6c7376 Mon Sep 17 00:00:00 2001 From: Bagatur <22008038+baskaryan@users.noreply.github.com> Date: Tue, 21 May 2024 11:01:28 -0700 Subject: [PATCH] community[patch]: AzureSearch dont overwrite default async (#21989) --- .../vectorstores/azuresearch.py | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) diff --git a/libs/community/langchain_community/vectorstores/azuresearch.py b/libs/community/langchain_community/vectorstores/azuresearch.py index 75d30e9cb32..a49bf03984a 100644 --- a/libs/community/langchain_community/vectorstores/azuresearch.py +++ b/libs/community/langchain_community/vectorstores/azuresearch.py @@ -21,10 +21,7 @@ from typing import ( ) import numpy as np -from langchain_core.callbacks import ( - AsyncCallbackManagerForRetrieverRun, - CallbackManagerForRetrieverRun, -) +from langchain_core.callbacks import CallbackManagerForRetrieverRun from langchain_core.documents import Document from langchain_core.embeddings import Embeddings from langchain_core.pydantic_v1 import root_validator @@ -802,13 +799,3 @@ class AzureSearchVectorStoreRetriever(BaseRetriever): else: raise ValueError(f"search_type of {self.search_type} not allowed.") return docs - - async def _aget_relevant_documents( - self, - query: str, - *, - run_manager: AsyncCallbackManagerForRetrieverRun, - ) -> List[Document]: - raise NotImplementedError( - "AzureSearchVectorStoreRetriever does not support async" - )