From cb303e6109c50c8dfef1f5e6c1ec47223bf3cd11 Mon Sep 17 00:00:00 2001 From: zhayujie Date: Tue, 3 Feb 2026 21:27:30 +0800 Subject: [PATCH] fix: add decision round log --- agent/protocol/agent_stream.py | 4 ++-- channel/dingtalk/dingtalk_channel.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/agent/protocol/agent_stream.py b/agent/protocol/agent_stream.py index 4d516d8..d753cab 100644 --- a/agent/protocol/agent_stream.py +++ b/agent/protocol/agent_stream.py @@ -184,7 +184,7 @@ class AgentStreamExecutor: try: while turn < self.max_turns: turn += 1 - logger.debug(f"第 {turn} 轮") + logger.info(f"[Agent] 第 {turn} 轮") self._emit_event("turn_start", {"turn": turn}) # Check if memory flush is needed (before calling LLM) @@ -447,7 +447,7 @@ class AgentStreamExecutor: raise finally: - logger.debug(f"🏁 完成({turn}轮)") + logger.info(f"[Agent] 🏁 完成 ({turn}轮)") self._emit_event("agent_end", {"final_response": final_response}) # 每轮对话结束后增加计数(用户消息+AI回复=1轮) diff --git a/channel/dingtalk/dingtalk_channel.py b/channel/dingtalk/dingtalk_channel.py index ad7edd0..12b1801 100644 --- a/channel/dingtalk/dingtalk_channel.py +++ b/channel/dingtalk/dingtalk_channel.py @@ -607,7 +607,7 @@ class DingTalkChanel(ChatChannel, dingtalk_stream.ChatbotHandler): def send(self, reply: Reply, context: Context): - logger.info(f"[DingTalk] send() called with reply.type={reply.type}, content_length={len(str(reply.content))}") + logger.debug(f"[DingTalk] send() called with reply.type={reply.type}, content_length={len(str(reply.content))}") receiver = context["receiver"] # Check if msg exists (for scheduled tasks, msg might be None) @@ -647,7 +647,7 @@ class DingTalkChanel(ChatChannel, dingtalk_stream.ChatbotHandler): robot_code = msg.robot_code if robot_code and robot_code != self._robot_code: self._robot_code = robot_code - logger.info(f"[DingTalk] Cached robot_code: {robot_code}") + logger.debug(f"[DingTalk] Cached robot_code: {robot_code}") isgroup = msg.is_group incoming_message = msg.incoming_message