From 9bf6668b52646b768e1de8d0860083f84f9fa708 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aleix=20Conchillo=20Flaqu=C3=A9?= Date: Fri, 19 Dec 2025 12:02:53 -0800 Subject: [PATCH] LLMUserAggregator: show error if using turn analyzer in transport --- .../aggregators/llm_response_universal.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/pipecat/processors/aggregators/llm_response_universal.py b/src/pipecat/processors/aggregators/llm_response_universal.py index 2e4dfbe65..cad371ef3 100644 --- a/src/pipecat/processors/aggregators/llm_response_universal.py +++ b/src/pipecat/processors/aggregators/llm_response_universal.py @@ -44,6 +44,7 @@ from pipecat.frames.frames import ( LLMThoughtEndFrame, LLMThoughtStartFrame, LLMThoughtTextFrame, + SpeechControlParamsFrame, StartFrame, TextFrame, TranscriptionFrame, @@ -300,6 +301,8 @@ class LLMUserAggregator(LLMContextAggregator): await self.push_frame(frame, direction) elif isinstance(frame, LLMSetToolChoiceFrame): self.set_tool_choice(frame.tool_choice) + elif isinstance(frame, SpeechControlParamsFrame): + await self._handle_speech_control_params(frame) else: await self.push_frame(frame, direction) @@ -367,6 +370,16 @@ class LLMUserAggregator(LLMContextAggregator): if frame.run_llm: await self.push_context_frame() + async def _handle_speech_control_params(self, frame: SpeechControlParamsFrame): + if not frame.turn_params: + return + + logger.error( + f"{self}: turn_analyzer in base input transport is deprecated and " + "might result in unexpected behavior. Use PipelineTask's turn_start_strategies with " + "TurnAnalyzerBotTurnStartStrategy instead." + ) + async def _handle_transcription(self, frame: TranscriptionFrame): text = frame.text