mirror of
http://112.124.100.131/huang.ze/ebiz-dify-ai.git
synced 2025-12-10 03:16:51 +08:00
feat: upgrade langchain (#430)
Co-authored-by: jyong <718720800@qq.com>
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
from llama_index import QueryKeywordExtractPrompt
|
||||
|
||||
CONVERSATION_TITLE_PROMPT = (
|
||||
"Human:{query}\n-----\n"
|
||||
"Help me summarize the intent of what the human said and provide a title, the title should not exceed 20 words.\n"
|
||||
@@ -45,23 +43,6 @@ SUGGESTED_QUESTIONS_AFTER_ANSWER_INSTRUCTION_PROMPT = (
|
||||
"[\"question1\",\"question2\",\"question3\"]\n"
|
||||
)
|
||||
|
||||
QUERY_KEYWORD_EXTRACT_TEMPLATE_TMPL = (
|
||||
"A question is provided below. Given the question, extract up to {max_keywords} "
|
||||
"keywords from the text. Focus on extracting the keywords that we can use "
|
||||
"to best lookup answers to the question. Avoid stopwords."
|
||||
"I am not sure which language the following question is in. "
|
||||
"If the user asked the question in Chinese, please return the keywords in Chinese. "
|
||||
"If the user asked the question in English, please return the keywords in English.\n"
|
||||
"---------------------\n"
|
||||
"{question}\n"
|
||||
"---------------------\n"
|
||||
"Provide keywords in the following comma-separated format: 'KEYWORDS: <keywords>'\n"
|
||||
)
|
||||
|
||||
QUERY_KEYWORD_EXTRACT_TEMPLATE = QueryKeywordExtractPrompt(
|
||||
QUERY_KEYWORD_EXTRACT_TEMPLATE_TMPL
|
||||
)
|
||||
|
||||
RULE_CONFIG_GENERATE_TEMPLATE = """Given MY INTENDED AUDIENCES and HOPING TO SOLVE using a language model, please select \
|
||||
the model prompt that best suits the input.
|
||||
You will be provided with the prompt, variables, and an opening statement.
|
||||
|
||||
Reference in New Issue
Block a user