From b3a267cc2b0365b1d7e61a08053c3af2bf57b503 Mon Sep 17 00:00:00 2001 From: Louis Guitton Date: Wed, 7 Feb 2024 18:31:24 +0100 Subject: [PATCH 1/2] Update summarize_cypher_result.py --- api/src/components/summarize_cypher_result.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/src/components/summarize_cypher_result.py b/api/src/components/summarize_cypher_result.py index 5b0d7a3..b8adec4 100644 --- a/api/src/components/summarize_cypher_result.py +++ b/api/src/components/summarize_cypher_result.py @@ -4,7 +4,7 @@ from llm.basellm import BaseLLM system = f""" -You are an assistant that helps to generate text to form nice and human understandable answers based. +You are an assistant that helps to generate text to form nice and human understandable answers. The latest prompt contains the information, and you need to generate a human readable response based on the given information. Make the answer sound as a response to the question. Do not mention that you based the result on the given information. Do not add any additional information that is not explicitly provided in the latest prompt. From 800e31793dd69586c09b0fc34b72459e9530d13a Mon Sep 17 00:00:00 2001 From: Louis Guitton Date: Wed, 7 Feb 2024 18:46:12 +0100 Subject: [PATCH 2/2] fix typo system prompt disambiguation --- api/src/components/data_disambiguation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/src/components/data_disambiguation.py b/api/src/components/data_disambiguation.py index b0509c9..4c9c115 100644 --- a/api/src/components/data_disambiguation.py +++ b/api/src/components/data_disambiguation.py @@ -10,7 +10,7 @@ def generate_system_message_for_nodes() -> str: - return """Your task is to identify if there are duplicated nodes and if so merge them into one nod. Only merge the nodes that refer to the same entity. + return """Your task is to identify if there are duplicated nodes and if so merge them into one node. Only merge the nodes that refer to the same entity. You will be given different datasets of nodes and some of these nodes may be duplicated or refer to the same entity. The datasets contains nodes in the form [ENTITY_ID, TYPE, PROPERTIES]. When you have completed your task please give me the resulting nodes in the same format. Only return the nodes and relationships no other text. If there is no duplicated nodes return the original nodes.