From 1e43025bf5c7e05ad6231c0ef8b81de702e46556 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Konstantin=20Spie=C3=9F?= Date: Mon, 13 Nov 2023 20:04:11 +0100 Subject: [PATCH] Fix serialization issue in Matching Engine Vector Store (#13266) - **Description:** Fixed a serialization issue in the add_texts method of the Matching Engine Vector Store caused by a typo, leading to an attempt to serialize the json module itself. - **Issue:** #12154 - **Dependencies:** ./. - **Tag maintainer:** --- libs/langchain/langchain/vectorstores/matching_engine.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/langchain/langchain/vectorstores/matching_engine.py b/libs/langchain/langchain/vectorstores/matching_engine.py index a852a5bc5e8..630be56df3f 100644 --- a/libs/langchain/langchain/vectorstores/matching_engine.py +++ b/libs/langchain/langchain/vectorstores/matching_engine.py @@ -137,7 +137,7 @@ class MatchingEngine(VectorStore): json_: dict = {"id": id, "embedding": embedding} if metadatas is not None: json_["metadata"] = metadatas[idx] - jsons.append(json) + jsons.append(json_) self._upload_to_gcs(text, f"documents/{id}") logger.debug(f"Uploaded {len(ids)} documents to GCS.")