Get up and running with Kimi, GLM, MiniMax, DeepSeek, gpt-oss, Qwen, Gemma and other models.
llm: always add bos token to prompt (#4941)
Jeffrey Morgan34f142797aff
diff --git a/llm/ext_server/server.cpp b/llm/ext_server/server.cppindex 8a0dffeaa..7d14e48ed 100644--- a/llm/ext_server/server.cpp+++ b/llm/ext_server/server.cpp@@ -835,7 +835,7 @@ struct llama_server_contextsystem_tokens.clear();if (!system_prompt.empty()) {- system_tokens = ::llama_tokenize(ctx, system_prompt, add_bos_token);+ system_tokens = ::llama_tokenize(ctx, system_prompt, true);llama_batch_clear(batch);@@ -1656,7 +1656,7 @@ struct llama_server_contextslot.t_start_process_prompt = ggml_time_us();slot.t_start_genereration = 0;- prompt_tokens = tokenize(slot.prompt, system_prompt.empty() && add_bos_token); // add BOS if there isn't system prompt+ prompt_tokens = tokenize(slot.prompt, system_prompt.empty()); // add BOS if there isn't system promptslot.n_prompt_tokens = prompt_tokens.size();