🤖 自动格式化代码 [skip ci]

This commit is contained in:
github-actions[bot]
2025-06-24 10:25:00 +00:00
parent b7faf8bed3
commit 537a8d69a0

View File

@@ -121,14 +121,15 @@ class NoReplyAction(BaseAction):
)
return True, exit_reason
# **新增**:检查回复频率,决定是否退出专注模式
should_exit_focus = await self._check_frequency_and_exit_focus(current_time)
if should_exit_focus:
logger.info(f"{self.log_prefix} 检测到回复频率过高,退出专注模式")
# 标记退出专注模式
self.action_data["_system_command"] = "stop_focus_chat"
exit_reason = f"{global_config.bot.nickname}(你)发现自己回复太频繁了,决定退出专注模式,稍作休息"
exit_reason = (
f"{global_config.bot.nickname}(你)发现自己回复太频繁了,决定退出专注模式,稍作休息"
)
await self.store_action_info(
action_build_into_prompt=True,
action_prompt_display=exit_reason,