openai: fix merge

This commit is contained in:
Olivier Chafik 2024-05-21 18:12:36 +01:00
parent 3f5a25f566
commit 5ea637e42c

View file

@ -385,7 +385,7 @@ static json oaicompat_completion_params_parse(
std::string extra_system_message; std::string extra_system_message;
// Apply chat template to the list of messages // Apply chat template to the list of messages
llama_params["prompt"] = format_chat(model, chat_template, body.at("messages")); llama_params["prompt"] = format_chat(model, chat_template, body.at("messages"), extra_system_message);
// Handle "stop" field // Handle "stop" field
if (body.contains("stop") && body.at("stop").is_string()) { if (body.contains("stop") && body.at("stop").is_string()) {