diff --git a/src/plugins/chat/bot.py b/src/plugins/chat/bot.py index e1049829e..53047f31e 100644 --- a/src/plugins/chat/bot.py +++ b/src/plugins/chat/bot.py @@ -1,25 +1,11 @@ -import re -import time -from random import random -from ..memory_system.Hippocampus import HippocampusManager from ..moods.moods import MoodManager # 导入情绪管理器 from ..config.config import global_config -from .emoji_manager import emoji_manager # 导入表情包管理器 from ..chat_module.reasoning_chat.reasoning_generator import ResponseGenerator -from .message import MessageSending, MessageRecv, MessageThinking, MessageSet -from .chat_stream import chat_manager -from .message_sender import message_manager # 导入新的消息管理器 -from ..relationship.relationship_manager import relationship_manager from ..storage.storage import MessageStorage # 修改导入路径 -from .utils import is_mentioned_bot_in_message, get_recent_group_detailed_plain_text -from .utils_image import image_path_to_base64 -from ..willing.willing_manager import willing_manager # 导入意愿管理器 -from ..message import UserInfo, Seg -from src.heart_flow.heartflow import heartflow from src.common.logger import get_module_logger, CHAT_STYLE_CONFIG, LogConfig from ..chat_module.think_flow_chat.think_flow_chat import ThinkFlowChat from ..chat_module.reasoning_chat.reasoning_chat import ReasoningChat diff --git a/src/plugins/chat_module/reasoning_chat/reasoning_chat.py b/src/plugins/chat_module/reasoning_chat/reasoning_chat.py index 600ba4f06..ed7db2a2a 100644 --- a/src/plugins/chat_module/reasoning_chat/reasoning_chat.py +++ b/src/plugins/chat_module/reasoning_chat/reasoning_chat.py @@ -9,9 +9,8 @@ from ...chat.emoji_manager import emoji_manager from .reasoning_generator import ResponseGenerator from ...chat.message import MessageSending, MessageRecv, MessageThinking, MessageSet from ...chat.message_sender import message_manager -from ...relationship.relationship_manager import relationship_manager from ...storage.storage import MessageStorage -from ...chat.utils import is_mentioned_bot_in_message, get_recent_group_detailed_plain_text +from ...chat.utils import is_mentioned_bot_in_message from ...chat.utils_image import image_path_to_base64 from ...willing.willing_manager import willing_manager from ...message import UserInfo, Seg diff --git a/src/plugins/chat_module/reasoning_chat/reasoning_generator.py b/src/plugins/chat_module/reasoning_chat/reasoning_generator.py index 354ddaefc..688d09f03 100644 --- a/src/plugins/chat_module/reasoning_chat/reasoning_generator.py +++ b/src/plugins/chat_module/reasoning_chat/reasoning_generator.py @@ -5,7 +5,7 @@ import random from ....common.database import db from ...models.utils_model import LLM_request from ...config.config import global_config -from ...chat.message import MessageRecv, MessageThinking, Message +from ...chat.message import MessageRecv, MessageThinking from .reasoning_prompt_builder import prompt_builder from ...chat.utils import process_llm_response from src.common.logger import get_module_logger, LogConfig, LLM_STYLE_CONFIG diff --git a/src/plugins/chat_module/reasoning_chat/reasoning_prompt_builder.py b/src/plugins/chat_module/reasoning_chat/reasoning_prompt_builder.py index 19c52081a..508febec8 100644 --- a/src/plugins/chat_module/reasoning_chat/reasoning_prompt_builder.py +++ b/src/plugins/chat_module/reasoning_chat/reasoning_prompt_builder.py @@ -129,7 +129,7 @@ class PromptBuilder: {chat_talking_prompt} 现在"{sender_name}"说的:{message_txt}。引起了你的注意,你想要在群里发言发言或者回复这条消息。\n 你的网名叫{global_config.BOT_NICKNAME},有人也叫你{"/".join(global_config.BOT_ALIAS_NAMES)},{prompt_personality}。 -你正在{chat_target_2},现在请你读读之前的聊天记录,然后给出日常且口语化的回复,平淡一些, +你正在{chat_target_2},现在请你读读之前的聊天记录,{mood_prompt},然后给出日常且口语化的回复,平淡一些, 尽量简短一些。{keywords_reaction_prompt}请注意把握聊天内容,不要回复的太有条理,可以有个性。{prompt_ger} 请回复的平淡一些,简短一些,说中文,不要刻意突出自身学科背景,尽量不要说你说过的话 请注意不要输出多余内容(包括前后缀,冒号和引号,括号,表情等),只输出回复内容。 diff --git a/src/plugins/chat_module/think_flow_chat/think_flow_chat.py b/src/plugins/chat_module/think_flow_chat/think_flow_chat.py index e644e1eb9..e2a96b985 100644 --- a/src/plugins/chat_module/think_flow_chat/think_flow_chat.py +++ b/src/plugins/chat_module/think_flow_chat/think_flow_chat.py @@ -9,7 +9,6 @@ from ...chat.emoji_manager import emoji_manager from .think_flow_generator import ResponseGenerator from ...chat.message import MessageSending, MessageRecv, MessageThinking, MessageSet from ...chat.message_sender import message_manager -from ...relationship.relationship_manager import relationship_manager from ...storage.storage import MessageStorage from ...chat.utils import is_mentioned_bot_in_message, get_recent_group_detailed_plain_text from ...chat.utils_image import image_path_to_base64 diff --git a/src/plugins/chat_module/think_flow_chat/think_flow_generator.py b/src/plugins/chat_module/think_flow_chat/think_flow_generator.py index 18769983f..d7240d9a6 100644 --- a/src/plugins/chat_module/think_flow_chat/think_flow_generator.py +++ b/src/plugins/chat_module/think_flow_chat/think_flow_generator.py @@ -5,7 +5,7 @@ from typing import List, Optional, Tuple, Union from ....common.database import db from ...models.utils_model import LLM_request from ...config.config import global_config -from ...chat.message import MessageRecv, MessageThinking, Message +from ...chat.message import MessageRecv, MessageThinking from .think_flow_prompt_builder import prompt_builder from ...chat.utils import process_llm_response from src.common.logger import get_module_logger, LogConfig, LLM_STYLE_CONFIG diff --git a/src/plugins/chat_module/think_flow_chat/think_flow_prompt_builder.py b/src/plugins/chat_module/think_flow_chat/think_flow_prompt_builder.py index a61ce2f15..cba03d234 100644 --- a/src/plugins/chat_module/think_flow_chat/think_flow_prompt_builder.py +++ b/src/plugins/chat_module/think_flow_chat/think_flow_prompt_builder.py @@ -2,12 +2,11 @@ import random import time from typing import Optional -from ....common.database import db from ...memory_system.Hippocampus import HippocampusManager from ...moods.moods import MoodManager from ...schedule.schedule_generator import bot_schedule from ...config.config import global_config -from ...chat.utils import get_embedding, get_recent_group_detailed_plain_text +from ...chat.utils import get_recent_group_detailed_plain_text from ...chat.chat_stream import chat_manager from src.common.logger import get_module_logger