From 511ddc6ef674fd5383fb035e1db8595724b2d3c6 Mon Sep 17 00:00:00 2001 From: Sadeep Madurange Date: Sat, 15 Aug 2026 07:14:06 +0800 Subject: Align two apply_template calls, improve prompt. --- main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.c b/main.c index 9d05e53..6a2eb36 100644 --- a/main.c +++ b/main.c @@ -12,7 +12,7 @@ #define SYSTEM_PROMPT \ "You are a dictionary assistant. Define the target word in the context provided.\n" \ "DO NOT repeat target word in definition. Choose one or two of Formality levels.\n\n" \ - "Output format:\n" \ + "FOLLOW the output format:\n" \ " () — \n\n" \ "DEFINITION:\n" \ "\n\n" \ @@ -50,7 +50,7 @@ static void process_request(struct llama_model *model, const char *user_prompt) if (!tmpl) fprintf(stderr, "Warning: model has no embedded chat template\n"); - prompt_len = llama_chat_apply_template(tmpl, messages, 2, true, NULL, 0); + prompt_len = llama_chat_apply_template(NULL, messages, 2, true, NULL, 0); if (prompt_len <= 0) { fprintf(stderr, "Error: failed to calculate chat template size\n"); return; -- cgit v1.2.3