Skip to content

Commit

Permalink
server: add data: [DONE] to /chat/completions stream response
Browse files Browse the repository at this point in the history
  • Loading branch information
VoidIsVoid authored Sep 13, 2024
1 parent 7820364 commit b3280e1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions examples/server/server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2986,6 +2986,7 @@ int main(int argc, char ** argv) {
}, [&](json error_data) {
server_sent_event(sink, "error", error_data);
});
sink.write("data: [DONE]\n\n", 14);
sink.done();
return true;
};
Expand Down

0 comments on commit b3280e1

Please sign in to comment.