diff --git a/agent/manager.py b/agent/manager.py index 786fe62..79101e2 100644 --- a/agent/manager.py +++ b/agent/manager.py @@ -91,7 +91,7 @@ class SessionManager: ) return session - async def send(self, conv_id: str, message: str, user_id: Optional[str] = None) -> str: + async def send(self, conv_id: str, message: str, user_id: Optional[str] = None, direct: bool = False) -> str: async with self._lock: session = self._sessions.get(conv_id) if session is None: @@ -108,7 +108,7 @@ class SessionManager: session.started = True self._save() - if cc_timeout > 60: + if not direct and cc_timeout > 60: from agent.task_runner import task_runner from orchestrator.tools import get_current_chat, set_current_chat, set_current_user diff --git a/orchestrator/agent.py b/orchestrator/agent.py index 7eae79e..d09f037 100644 --- a/orchestrator/agent.py +++ b/orchestrator/agent.py @@ -159,7 +159,7 @@ class OrchestrationAgent: # Passthrough mode: if enabled and active session, bypass LLM if self._passthrough[user_id] and active_conv: try: - reply = await manager.send(active_conv, text, user_id=user_id) + reply = await manager.send(active_conv, text, user_id=user_id, direct=True) logger.info("<<< [passthrough] reply: %r", reply[:120]) return reply except KeyError: