We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent be13429 commit 21453ffCopy full SHA for 21453ff
rag/llm/chat_model.py
@@ -56,6 +56,7 @@ def chat_streamly(self, system, history, gen_conf):
56
stream=True,
57
**gen_conf)
58
for resp in response:
59
+ if len(resp.choices) == 0:continue
60
if not resp.choices[0].delta.content:continue
61
ans += resp.choices[0].delta.content
62
total_tokens += 1
0 commit comments