Default streaming to false if it's not set in the request body.

This commit is contained in:
digiwombat 2023-05-30 20:17:18 -04:00
parent 38eaf2b7f7
commit a25f830fe1

View file

@ -482,6 +482,10 @@ bool parse_options_completion(json body, llama_server_context& llama, Response &
{
llama.streaming = body["streaming"].get<bool>();
}
else
{
llama.streaming = false;
}
if (!body["n_predict"].is_null())
{
llama.params.n_predict = body["n_predict"].get<int>();