Skip to content

Commit 024d11a

Browse files
authored
Fix incorrect model type check in process_frame method
Signed-off-by: He Huang (Steve) <105218074+stevehuang52@users.noreply.github.com>
1 parent 4f45f58 commit 024d11a

File tree

1 file changed

+1
-2
lines changed
  • nemo/agents/voice_agent/pipecat/services/nemo

1 file changed

+1
-2
lines changed

nemo/agents/voice_agent/pipecat/services/nemo/stt.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@
3434
from pydantic import BaseModel
3535

3636
from nemo.agents.voice_agent.pipecat.services.nemo.streaming_asr import NemoStreamingASRService
37-
from nemo.agents.voice_agent.pipecat.services.nemo.streaming_diar import NeMoStreamingDiarService
3837

3938
try:
4039
# disable nemo logging
@@ -267,7 +266,7 @@ async def set_model(self, model: str):
267266

268267
async def process_frame(self, frame: Frame, direction: FrameDirection):
269268
"""Process incoming frames and handle VAD events."""
270-
if isinstance(frame, VADUserStoppedSpeakingFrame) and isinstance(self._model, NeMoStreamingDiarService):
269+
if isinstance(frame, VADUserStoppedSpeakingFrame) and isinstance(self._model, NemoStreamingASRService):
271270
# manualy reset the state of the model when end of utterance is detected by VAD
272271
logger.debug("Resetting state of the model due to VADUserStoppedSpeakingFrame")
273272
self._model.reset_state()

0 commit comments

Comments
 (0)