diff --git a/nucliadb/src/nucliadb/search/search/chat/ask.py b/nucliadb/src/nucliadb/search/search/chat/ask.py index aaa6167bb1..6fad9b9f64 100644 --- a/nucliadb/src/nucliadb/search/search/chat/ask.py +++ b/nucliadb/src/nucliadb/search/search/chat/ask.py @@ -302,7 +302,7 @@ async def _stream_predict_answer_text(self) -> AsyncGenerator[str, None]: self.metrics.record_first_chunk_yielded() first_answer_chunk_yielded = True yield item.text - if isinstance(item, JSONGenerativeResponse): + elif isinstance(item, JSONGenerativeResponse): self._object = item elif isinstance(item, StatusGenerativeResponse): self._status = item