feat(chat): 实现可配置的主动思考范围并优化逻辑
- 将主动思考的prompt移至代码内部,并区分私聊和群聊场景。 - 增加`The_scope_that_proactive_thinking_can_trigger`配置项,允许用户将主动思考限制在“全部”、“私聊”或“群聊”范围。 - 删除了旧的`proactive_thinking_prompt_template`配置。 - 优化了主动思考的触发条件,现在会根据新的范围配置进行检查。 - 清理了代码中多余的空行和未使用的导入。
This commit is contained in:
@@ -1,18 +1,13 @@
|
||||
import asyncio
|
||||
import time
|
||||
import json
|
||||
import hashlib
|
||||
from typing import List, Optional, Tuple, Dict, Any
|
||||
from typing import List, Dict, Any
|
||||
from dataclasses import dataclass
|
||||
import threading
|
||||
from datetime import datetime, timedelta
|
||||
|
||||
import numpy as np
|
||||
import chromadb
|
||||
from chromadb.config import Settings
|
||||
from src.common.logger import get_logger
|
||||
from src.chat.utils.utils import get_embedding
|
||||
from src.config.config import global_config
|
||||
|
||||
|
||||
logger = get_logger("vector_instant_memory_v2")
|
||||
|
||||
Reference in New Issue
Block a user