The agent engineering platform.
Python agentsaiai-agentsanthropicchatgptdeepagentsenterpriseframeworkgeminigenerative-ailangchainlanggraphllmmultiagentopen-sourceopenaipydanticpythonragtypescript
fixed an UnboundLocalError when no documents are found (#12995)
Leonid Kuliginf3fcdea57471
diff --git a/libs/langchain/langchain/retrievers/google_vertex_ai_search.py b/libs/langchain/langchain/retrievers/google_vertex_ai_search.pyindex 8dc8cd6d8b..0e0c165c53 100644--- a/libs/langchain/langchain/retrievers/google_vertex_ai_search.py+++ b/libs/langchain/langchain/retrievers/google_vertex_ai_search.py@@ -160,6 +160,7 @@ class _BaseGoogleVertexAISearchRetriever(BaseModel):from google.protobuf.json_format import MessageToDictdocuments: List[Document] = []+ chunk_type = "extractive_answers"for result in results:document_dict = MessageToDict(