Skip to content

Commit 6191bcd

Browse files
authored
fix: minor bug in chat stream output - python error being serialized (#1449)
1 parent d3acd85 commit 6191bcd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

private_gpt/open_ai/openai_models.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -118,5 +118,5 @@ def to_openai_sse_stream(
118118
yield f"data: {OpenAICompletion.json_from_delta(text=response.delta)}\n\n"
119119
else:
120120
yield f"data: {OpenAICompletion.json_from_delta(text=response, sources=sources)}\n\n"
121-
yield f"data: {OpenAICompletion.json_from_delta(text=None, finish_reason='stop')}\n\n"
121+
yield f"data: {OpenAICompletion.json_from_delta(text='', finish_reason='stop')}\n\n"
122122
yield "data: [DONE]\n\n"

0 commit comments

Comments
 (0)