From 8971ac65b5162dc6e5a8c6d9123c7282811ee80f Mon Sep 17 00:00:00 2001 From: Will Tai Date: Mon, 28 Oct 2024 15:16:58 +0000 Subject: [PATCH] Add warning in get_search_query --- src/neo4j_graphrag/neo4j_queries.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/neo4j_graphrag/neo4j_queries.py b/src/neo4j_graphrag/neo4j_queries.py index 8a3ff535..5cb9652a 100644 --- a/src/neo4j_graphrag/neo4j_queries.py +++ b/src/neo4j_graphrag/neo4j_queries.py @@ -14,6 +14,7 @@ # limitations under the License. from __future__ import annotations +import warnings from typing import Any, Optional from neo4j_graphrag.filters import get_metadata_filter @@ -201,6 +202,11 @@ def get_search_query( tuple[str, dict[str, Any]]: query and parameters """ + warnings.warn( + "The default returned 'id' field in the search results will be renamed to 'node_id' in a future version.", + DeprecationWarning, + stacklevel=2, + ) if search_type == SearchType.HYBRID: if filters: raise Exception("Filters are not supported with Hybrid Search")