diff --git a/rag/llm/chat_model.py b/rag/llm/chat_model.py index 77f2714b9..114d7a0fe 100644 --- a/rag/llm/chat_model.py +++ b/rag/llm/chat_model.py @@ -1358,7 +1358,7 @@ class AnthropicChat(Base): stream=True, **gen_conf, ) - for res in response.iter_lines(): + for res in response: if res.type == 'content_block_delta': text = res.delta.text ans += text