Simplify frames in the NotifierGate
This commit is contained in:
@@ -22,18 +22,13 @@ from loguru import logger
|
|||||||
|
|
||||||
from pipecat.frames.frames import (
|
from pipecat.frames.frames import (
|
||||||
BotInterruptionFrame,
|
BotInterruptionFrame,
|
||||||
CancelFrame,
|
|
||||||
CancelTaskFrame,
|
|
||||||
EndFrame,
|
EndFrame,
|
||||||
EndTaskFrame,
|
|
||||||
Frame,
|
Frame,
|
||||||
LLMFullResponseEndFrame,
|
LLMFullResponseEndFrame,
|
||||||
LLMFullResponseStartFrame,
|
LLMFullResponseStartFrame,
|
||||||
LLMTextFrame,
|
LLMTextFrame,
|
||||||
StartInterruptionFrame,
|
|
||||||
StopFrame,
|
StopFrame,
|
||||||
StopInterruptionFrame,
|
SystemFrame,
|
||||||
StopTaskFrame,
|
|
||||||
TTSAudioRawFrame,
|
TTSAudioRawFrame,
|
||||||
TTSStartedFrame,
|
TTSStartedFrame,
|
||||||
TTSStoppedFrame,
|
TTSStoppedFrame,
|
||||||
@@ -104,19 +99,7 @@ class NotifierGate(FrameProcessor):
|
|||||||
await self.push_frame(frame, direction)
|
await self.push_frame(frame, direction)
|
||||||
elif isinstance(
|
elif isinstance(
|
||||||
frame,
|
frame,
|
||||||
(
|
(SystemFrame, EndFrame, StopFrame),
|
||||||
BotInterruptionFrame,
|
|
||||||
CancelFrame,
|
|
||||||
CancelTaskFrame,
|
|
||||||
EndTaskFrame,
|
|
||||||
EndFrame,
|
|
||||||
StartInterruptionFrame,
|
|
||||||
StopInterruptionFrame,
|
|
||||||
StopFrame,
|
|
||||||
StopTaskFrame,
|
|
||||||
UserStartedSpeakingFrame,
|
|
||||||
UserStoppedSpeakingFrame,
|
|
||||||
),
|
|
||||||
):
|
):
|
||||||
await self.push_frame(frame, direction)
|
await self.push_frame(frame, direction)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user