From 1c1cf35694c5963d50b975cc62f52eaf75fd87d7 Mon Sep 17 00:00:00 2001 From: Thomas Antony Date: Sun, 19 Mar 2023 13:00:08 -0700 Subject: [PATCH] Update main.cpp to use instruct mode --- main.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/main.cpp b/main.cpp index f9d6f894a..49c43bd49 100644 --- a/main.cpp +++ b/main.cpp @@ -210,13 +210,16 @@ int main(int argc, char ** argv) { } if (is_interacting) { if (params.instruct) { - llama_update_input(ctx, "\n\n### Instruction:\n\n"); - + llama_update_input(ctx, inp_pfx); printf("\n> "); } // currently being interactive process_interactive_input(ctx, params); + + if (params.instruct) { + llama_update_input(ctx, inp_sfx); + } input_noecho = true; // do not echo this input again is_interacting = false; }