Unverified Commit 9e372664 authored by Zhao Yingzhuo's avatar Zhao Yingzhuo Committed by GitHub
Browse files

bugfix: fix the bug that stream generate not work (#2756)

parent 8a4358ec
......@@ -66,7 +66,7 @@ async def generate(request: Request) -> Response:
prompt + output.text for output in request_output.outputs
]
ret = {"text": text_outputs}
yield (json.dumps(ret) + "\0").encode("utf-8")
yield (json.dumps(ret) + "\n").encode("utf-8")
if stream:
return StreamingResponse(stream_results())
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment