aggregators: fix LLMUserResponseAggregator passs-through

This commit is contained in:
Aleix Conchillo Flaqué
2024-04-10 21:46:16 -07:00
parent 1a0a66e503
commit af8663e95d

View File

@@ -133,8 +133,9 @@ class LLMResponseAggregator(FrameProcessor):
self.aggregation = ""
yield self._end_frame()
yield LLMMessagesFrame(self.messages)
elif isinstance(frame, self._accumulator_frame) and self.aggregating:
self.aggregation += f" {frame.text}"
elif isinstance(frame, self._accumulator_frame):
if self.aggregating:
self.aggregation += f" {frame.text}"
if self._pass_through:
yield frame
else: