Adding the direction when pushing the BotStartedSpeaking and BotStoppedSpeaking frames.

This commit is contained in:
Filipi Fuchter
2025-06-02 15:05:56 -03:00
parent 4d7c87bb4c
commit b828bfd890

View File

@@ -196,10 +196,10 @@ class BaseInputTransport(FrameProcessor):
await self._handle_bot_interruption(frame)
elif isinstance(frame, BotStartedSpeakingFrame):
await self._handle_bot_started_speaking(frame)
await self.push_frame(frame)
await self.push_frame(frame, direction)
elif isinstance(frame, BotStoppedSpeakingFrame):
await self._handle_bot_stopped_speaking(frame)
await self.push_frame(frame)
await self.push_frame(frame, direction)
elif isinstance(frame, EmulateUserStartedSpeakingFrame):
logger.debug("Emulating user started speaking")
await self._handle_user_interruption(UserStartedSpeakingFrame(emulated=True))