From 4bcc74d214c1c7d6f1e16b780fa977df75a7ae73 Mon Sep 17 00:00:00 2001 From: imClumsyPanda Date: Wed, 23 Aug 2023 21:52:12 +0800 Subject: [PATCH] update prompt template --- configs/model_config.py.example | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/configs/model_config.py.example b/configs/model_config.py.example index 3e84b8b..0dab00f 100644 --- a/configs/model_config.py.example +++ b/configs/model_config.py.example @@ -143,11 +143,11 @@ SEARCH_ENGINE_TOP_K = 5 NLTK_DATA_PATH = os.path.join(os.path.dirname(os.path.dirname(__file__)), "nltk_data") # 基于本地知识问答的提示词模版(使用Jinja2语法,简单点就是用双大括号代替f-string的单大括号 -PROMPT_TEMPLATE = """【指令】根据已知信息,简洁和专业的来回答问题。如果无法从中得到答案,请说 “根据已知信息无法回答该问题”,不允许在答案中添加编造成分,答案请使用中文。 +PROMPT_TEMPLATE = """<指令>根据已知信息,简洁和专业的来回答问题。如果无法从中得到答案,请说 “根据已知信息无法回答该问题”,不允许在答案中添加编造成分,答案请使用中文。 -【已知信息】{{ context }} +<已知信息>{{ context }} -【问题】{{ question }}""" +<问题>{{ question }}""" # API 是否开启跨域,默认为False,如果需要开启,请设置为True # is open cross domain