better:重整配置,分离表达,聊天模式区分
重整配置文件路径,添加更多配置选项 分离了人设表达方式和学习到的表达方式 将聊天模式区分为normal focus和auto
This commit is contained in:
@@ -26,7 +26,7 @@ logger = get_logger("normal_chat")
|
||||
|
||||
|
||||
class NormalChat:
|
||||
def __init__(self, chat_stream: ChatStream, interest_dict: dict = {}):
|
||||
def __init__(self, chat_stream: ChatStream, interest_dict: dict = None):
|
||||
"""初始化 NormalChat 实例。只进行同步操作。"""
|
||||
|
||||
# Basic info from chat_stream (sync)
|
||||
@@ -36,7 +36,7 @@ class NormalChat:
|
||||
self.stream_name = chat_manager.get_stream_name(self.stream_id) or self.stream_id
|
||||
|
||||
# Interest dict
|
||||
self.interest_dict = interest_dict
|
||||
self.interest_dict = interest_dict or {}
|
||||
|
||||
# --- Initialize attributes (defaults) ---
|
||||
self.is_group_chat: bool = False
|
||||
@@ -200,7 +200,6 @@ class NormalChat:
|
||||
logger.info(f"[{self.stream_name}] 兴趣监控任务被取消或置空,退出")
|
||||
break
|
||||
|
||||
|
||||
items_to_process = list(self.interest_dict.items())
|
||||
if not items_to_process:
|
||||
continue
|
||||
|
||||
Reference in New Issue
Block a user