Skip to content

Commit ac3fa7f

Browse files
committed
BaseOuputTransport: minor cleanup
1 parent 6eadad5 commit ac3fa7f

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

src/pipecat/transports/base_output.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ def __init__(
403403
# Last time a BotSpeakingFrame was pushed.
404404
self._bot_speaking_frame_time = 0
405405
# How often a BotSpeakingFrame should be pushed (value should be
406-
# lower than the audio chunks).
406+
# greater than the audio chunks to have any effect).
407407
self._bot_speaking_frame_period = 0.2
408408
# Last time the bot actually spoke.
409409
self._bot_speech_last_time = 0
@@ -644,8 +644,7 @@ async def _bot_currently_speaking(self):
644644

645645
diff_time = time.time() - self._bot_speaking_frame_time
646646
if diff_time >= self._bot_speaking_frame_period:
647-
await self._transport.push_frame(BotSpeakingFrame())
648-
await self._transport.push_frame(BotSpeakingFrame(), FrameDirection.UPSTREAM)
647+
await self._transport.broadcast_frame(BotSpeakingFrame)
649648
self._bot_speaking_frame_time = time.time()
650649

651650
self._bot_speech_last_time = time.time()

0 commit comments

Comments
 (0)