From c2d501856586401b7e4bef5e110370dcd7207933 Mon Sep 17 00:00:00 2001 From: Rodrigo Brandao Date: Thu, 13 Nov 2025 07:02:23 -0800 Subject: [PATCH] Disabling streaming when receiving agentic request for msteams channel --- .../hosting/aiohttp/app/streaming/streaming_response.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/libraries/microsoft-agents-hosting-aiohttp/microsoft_agents/hosting/aiohttp/app/streaming/streaming_response.py b/libraries/microsoft-agents-hosting-aiohttp/microsoft_agents/hosting/aiohttp/app/streaming/streaming_response.py index a86fc721..f495aa9c 100644 --- a/libraries/microsoft-agents-hosting-aiohttp/microsoft_agents/hosting/aiohttp/app/streaming/streaming_response.py +++ b/libraries/microsoft-agents-hosting-aiohttp/microsoft_agents/hosting/aiohttp/app/streaming/streaming_response.py @@ -251,8 +251,13 @@ async def wait_for_queue(self) -> None: def _set_defaults(self, context: "TurnContext"): if Channels.ms_teams == context.activity.channel_id.channel: - self._is_streaming_channel = True - self._interval = 1.0 + if context.activity.is_agentic_request(): + # Agentic requests do not support streaming responses at this time. + # TODO : Enable streaming for agentic requests when supported. + self._is_streaming_channel = False + else: + self._is_streaming_channel = True + self._interval = 1.0 elif Channels.direct_line == context.activity.channel_id.channel: self._is_streaming_channel = True self._interval = 0.5