You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// if a custom chat template is not supplied, we will use the one that comes with the model (if any)
4225
4218
if (params.chat_template.empty()) {
4226
-
if (!ctx_server.validate_model_chat_template()) {
4219
+
if (!ctx_server.validate_builtin_chat_template()) {
4227
4220
LOG_WRN("%s: The chat template that comes with this model is not yet supported, falling back to chatml. This may cause the model to output suboptimal responses\n", __func__);
4228
4221
params.chat_template = "chatml";
4229
4222
}
4230
4223
}
4231
4224
4232
4225
// print sample chat example to make it clear which template is used
{"role": "user", "content": "What is the best book"},
113
+
]
114
+
})
115
+
assertres.status_code==200
116
+
assert"__verbose"inres.body
117
+
assertres.body["__verbose"]["prompt"] =="<s> <|start_header_id|>system<|end_header_id|>\n\nBook<|eot_id|><|start_header_id|>user<|end_header_id|>\n\nWhat is the best book<|eot_id|><|start_header_id|>assistant<|end_header_id|>\n\n"
0 commit comments