diff --git a/engine/config/chat_template_renderer.h b/engine/config/chat_template_renderer.h index f40894f7b..63a47ecf3 100644 --- a/engine/config/chat_template_renderer.h +++ b/engine/config/chat_template_renderer.h @@ -123,7 +123,7 @@ static int32_t llama_chat_apply_template_internal( ss << content << "\n"; } } else if (role == "user") { - ss << content << " [/INST]"; + ss << "[INST] " << content << " [/INST]"; } else { ss << (space_around_response ? " " : "") << content << (space_around_response ? " " : "") << "";