mirror of
https://git.mirrors.martin98.com/https://github.com/langgenius/dify.git
synced 2025-08-11 03:29:02 +08:00
question classifier prompt optimization (#3479)
This commit is contained in:
parent
22994a6d14
commit
fd90d99cd0
@ -211,7 +211,7 @@ class QuestionClassifierNode(LLMNode):
|
||||
model_mode = ModelMode.value_of(node_data.model.mode)
|
||||
classes = node_data.classes
|
||||
class_names = [class_.name for class_ in classes]
|
||||
class_names_str = ','.join(class_names)
|
||||
class_names_str = ','.join(f'"{name}"' for name in class_names)
|
||||
instruction = node_data.instruction if node_data.instruction else ''
|
||||
input_text = query
|
||||
memory_str = ''
|
||||
|
@ -35,7 +35,7 @@ QUESTION_CLASSIFIER_USER_PROMPT_2 = """
|
||||
|
||||
QUESTION_CLASSIFIER_ASSISTANT_PROMPT_2 = """
|
||||
{"keywords": ["bad service", "slow", "food", "tip", "terrible", "waitresses"],
|
||||
"categories": ["Experience""]}```
|
||||
"categories": ["Experience"]}```
|
||||
"""
|
||||
|
||||
QUESTION_CLASSIFIER_USER_PROMPT_3 = """
|
||||
|
Loading…
x
Reference in New Issue
Block a user