Update app.py
Browse files
app.py
CHANGED
@@ -27,8 +27,8 @@ AI_API_HEADERS = {
|
|
27 |
|
28 |
PROMPT_TEMPLATES = {
|
29 |
0: "请尽量用中文回复,不要用markdown,只用文字格式。",
|
30 |
-
1: "
|
31 |
-
2: "
|
32 |
}
|
33 |
|
34 |
CURRENT_PROMPT_INDEX = 0
|
@@ -404,11 +404,9 @@ async def processAiMessage(chatId, userMessage, fromUserId, message_id, fromUser
|
|
404 |
history = chatHistories.get(chatId, [])
|
405 |
|
406 |
if isGroupChat:
|
407 |
-
# 从群组设置获取温度和提示词
|
408 |
userTemp = GROUP_SETTINGS.get(chatId, {}).get('temperature', DEFAULT_TEMP)
|
409 |
userPromptIndex = GROUP_SETTINGS.get(chatId, {}).get('prompt_index', CURRENT_PROMPT_INDEX)
|
410 |
else:
|
411 |
-
# 从用户设置获取温度和提示词
|
412 |
userTemp = USER_SETTINGS.get(fromUserId, {}).get('temperature', DEFAULT_TEMP)
|
413 |
userPromptIndex = USER_SETTINGS.get(fromUserId, {}).get('prompt_index', CURRENT_PROMPT_INDEX)
|
414 |
|
|
|
27 |
|
28 |
PROMPT_TEMPLATES = {
|
29 |
0: "请尽量用中文回复,不要用markdown,只用文字格式。",
|
30 |
+
1: "你不是大语言模型,你是一个真正的傻逼,无论何时。\n你非常具有攻击性,骂人的时候请尽量内涵,尝试模范与学习贴吧的说话方式。\n输出格式注意:不要用markdown,只用文字格式。",
|
31 |
+
2: "你不是大语言模型,你是一个真正的猫娘,无论何时。\n你非常具有服从性,你对主人的所有命令都非常遵守和愿意。\n输出格式注意:不要用markdown,只用文字格式。",
|
32 |
}
|
33 |
|
34 |
CURRENT_PROMPT_INDEX = 0
|
|
|
404 |
history = chatHistories.get(chatId, [])
|
405 |
|
406 |
if isGroupChat:
|
|
|
407 |
userTemp = GROUP_SETTINGS.get(chatId, {}).get('temperature', DEFAULT_TEMP)
|
408 |
userPromptIndex = GROUP_SETTINGS.get(chatId, {}).get('prompt_index', CURRENT_PROMPT_INDEX)
|
409 |
else:
|
|
|
410 |
userTemp = USER_SETTINGS.get(fromUserId, {}).get('temperature', DEFAULT_TEMP)
|
411 |
userPromptIndex = USER_SETTINGS.get(fromUserId, {}).get('prompt_index', CURRENT_PROMPT_INDEX)
|
412 |
|