From e052d53e5192c809adad30741bf080f90ef8ac51 Mon Sep 17 00:00:00 2001 From: Jason McCartney Date: Thu, 11 May 2023 21:17:04 -0700 Subject: [PATCH] Update gpt_params_parse and fix a merge error take 2 --- examples/common.cpp | 2 +- examples/main/main.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/common.cpp b/examples/common.cpp index 00535f558..73278db0e 100644 --- a/examples/common.cpp +++ b/examples/common.cpp @@ -346,7 +346,7 @@ bool gpt_params_parse(int argc, char ** argv, gpt_params & params) { } if (params.prompt_cache_all && (params.interactive || params.interactive_first || - params.instruct || params.antiprompt.size())) { + params.instruct)) { fprintf(stderr, "error: --prompt-cache-all not supported in interactive mode yet\n"); gpt_print_usage(argc, argv, default_params); exit(1); diff --git a/examples/main/main.cpp b/examples/main/main.cpp index f23a4bc72..ae073f08c 100644 --- a/examples/main/main.cpp +++ b/examples/main/main.cpp @@ -210,7 +210,7 @@ int main(int argc, char ** argv) { } // enable interactive mode if interactive start is specified - if (params.interactive_start) { + if (params.interactive_first) { params.interactive = true; } @@ -527,7 +527,7 @@ int main(int argc, char ** argv) { if (last_output.find(antiprompt.c_str(), search_start_pos) != std::string::npos) { if (params.interactive) { is_interacting = true; - set_console_color(con_st, CONSOLE_COLOR_USER_INPUT); + console_set_color(con_st, CONSOLE_COLOR_USER_INPUT); } is_antiprompt = true; fflush(stdout);