fix: 更新配置文件,禁用身份压缩以提高回复性能
refactor: 移除日志信息以简化回复和响应动作
This commit is contained in:
@@ -96,7 +96,6 @@ class ReplyAction(BaseAction):
|
|||||||
# 发送回复
|
# 发送回复
|
||||||
reply_text = await self._send_response(response_set)
|
reply_text = await self._send_response(response_set)
|
||||||
|
|
||||||
logger.info(f"{self.log_prefix} reply 动作执行成功")
|
|
||||||
return True, reply_text
|
return True, reply_text
|
||||||
|
|
||||||
except asyncio.CancelledError:
|
except asyncio.CancelledError:
|
||||||
@@ -218,8 +217,7 @@ class RespondAction(BaseAction):
|
|||||||
|
|
||||||
# 发送回复(respond 默认不引用)
|
# 发送回复(respond 默认不引用)
|
||||||
reply_text = await self._send_response(response_set)
|
reply_text = await self._send_response(response_set)
|
||||||
|
|
||||||
logger.info(f"{self.log_prefix} respond 动作执行成功")
|
|
||||||
return True, reply_text
|
return True, reply_text
|
||||||
|
|
||||||
except asyncio.CancelledError:
|
except asyncio.CancelledError:
|
||||||
|
|||||||
@@ -126,7 +126,6 @@ class ChatStreamImpressionTool(BaseTool):
|
|||||||
updates.append(f"兴趣分: {final_impression['stream_interest_score']:.2f}")
|
updates.append(f"兴趣分: {final_impression['stream_interest_score']:.2f}")
|
||||||
|
|
||||||
result_text = f"已更新聊天流 {stream_id} 的印象:\n" + "\n".join(updates)
|
result_text = f"已更新聊天流 {stream_id} 的印象:\n" + "\n".join(updates)
|
||||||
logger.info(f"聊天流印象更新成功: {stream_id}")
|
|
||||||
|
|
||||||
return {"type": "chat_stream_impression_update", "id": stream_id, "content": result_text}
|
return {"type": "chat_stream_impression_update", "id": stream_id, "content": result_text}
|
||||||
|
|
||||||
@@ -214,7 +213,7 @@ class ChatStreamImpressionTool(BaseTool):
|
|||||||
await cache.delete(generate_cache_key("stream_impression", stream_id))
|
await cache.delete(generate_cache_key("stream_impression", stream_id))
|
||||||
await cache.delete(generate_cache_key("chat_stream", stream_id))
|
await cache.delete(generate_cache_key("chat_stream", stream_id))
|
||||||
|
|
||||||
logger.info(f"聊天流印象已更新到数据库: {stream_id}")
|
logger.debug(f"聊天流印象已更新到数据库: {stream_id}")
|
||||||
else:
|
else:
|
||||||
error_msg = f"聊天流 {stream_id} 不存在于数据库中,无法更新印象"
|
error_msg = f"聊天流 {stream_id} 不存在于数据库中,无法更新印象"
|
||||||
logger.error(error_msg)
|
logger.error(error_msg)
|
||||||
|
|||||||
@@ -131,7 +131,7 @@ safety_guidelines = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
compress_personality = false # 是否压缩人格,压缩后会精简人格信息,节省token消耗并提高回复性能,但是会丢失一些信息,如果人设不长,可以关闭
|
compress_personality = false # 是否压缩人格,压缩后会精简人格信息,节省token消耗并提高回复性能,但是会丢失一些信息,如果人设不长,可以关闭
|
||||||
compress_identity = true # 是否压缩身份,压缩后会精简身份信息,节省token消耗并提高回复性能,但是会丢失一些信息,如果不长,可以关闭
|
compress_identity = false # 是否压缩身份,压缩后会精简身份信息,节省token消耗并提高回复性能,但是会丢失一些信息,如果不长,可以关闭
|
||||||
|
|
||||||
[expression]
|
[expression]
|
||||||
# 表达学习配置
|
# 表达学习配置
|
||||||
@@ -283,7 +283,7 @@ path_expansion_path_score_weight = 0.50 # 路径分数在最终评分中的权
|
|||||||
path_expansion_importance_weight = 0.30 # 重要性在最终评分中的权重
|
path_expansion_importance_weight = 0.30 # 重要性在最终评分中的权重
|
||||||
path_expansion_recency_weight = 0.20 # 时效性在最终评分中的权重
|
path_expansion_recency_weight = 0.20 # 时效性在最终评分中的权重
|
||||||
|
|
||||||
# 🆕 路径扩展 - 记忆去重配置
|
# 路径扩展 - 记忆去重配置
|
||||||
enable_memory_deduplication = true # 启用检索结果去重(合并相似记忆)
|
enable_memory_deduplication = true # 启用检索结果去重(合并相似记忆)
|
||||||
memory_deduplication_threshold = 0.85 # 记忆相似度阈值(0.85表示85%相似即合并)
|
memory_deduplication_threshold = 0.85 # 记忆相似度阈值(0.85表示85%相似即合并)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user