chore/ 删除无用文件
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
"""
|
||||
用户基础资料收集提示词
|
||||
"""
|
||||
|
||||
from typing import Dict, List, Optional
|
||||
|
||||
|
||||
@@ -14,7 +15,9 @@ PROFILE_FIELD_NAMES = {
|
||||
|
||||
def get_profile_greeting_prompt(missing_fields: List[str], nickname: str = "") -> str:
|
||||
"""生成初次见面、收集基础资料的引导提示词"""
|
||||
missing_names = [PROFILE_FIELD_NAMES[f] for f in missing_fields if f in PROFILE_FIELD_NAMES]
|
||||
missing_names = [
|
||||
PROFILE_FIELD_NAMES[f] for f in missing_fields if f in PROFILE_FIELD_NAMES
|
||||
]
|
||||
missing_str = "、".join(missing_names)
|
||||
name_part = f",{nickname}" if nickname else ""
|
||||
|
||||
@@ -54,7 +57,9 @@ def get_profile_extraction_prompt(
|
||||
recent_dialogue: Optional[str] = None,
|
||||
) -> str:
|
||||
"""从用户回答中提取基础资料信息(可包含最近几轮对话,避免漏提)"""
|
||||
missing_names = {f: PROFILE_FIELD_NAMES[f] for f in missing_fields if f in PROFILE_FIELD_NAMES}
|
||||
missing_names = {
|
||||
f: PROFILE_FIELD_NAMES[f] for f in missing_fields if f in PROFILE_FIELD_NAMES
|
||||
}
|
||||
|
||||
dialogue_section = ""
|
||||
if recent_dialogue and recent_dialogue.strip():
|
||||
@@ -93,7 +98,9 @@ def get_profile_followup_prompt(
|
||||
nickname: str = "",
|
||||
) -> str:
|
||||
"""在收集资料过程中的跟进提问"""
|
||||
missing_names = [PROFILE_FIELD_NAMES[f] for f in missing_fields if f in PROFILE_FIELD_NAMES]
|
||||
missing_names = [
|
||||
PROFILE_FIELD_NAMES[f] for f in missing_fields if f in PROFILE_FIELD_NAMES
|
||||
]
|
||||
missing_str = "、".join(missing_names) if missing_names else "无"
|
||||
|
||||
filled_info = []
|
||||
|
||||
Reference in New Issue
Block a user