From 2436a59ed3f8a570f6e8f54687d36debde542ea8 Mon Sep 17 00:00:00 2001 From: Hayden Johnson Date: Thu, 19 Dec 2024 08:13:47 -0800 Subject: [PATCH] Add red coloring to assistant response To better distinguish between the user's messages and the ai's messages, the "assistant" label will be colored red --- assistant.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/assistant.py b/assistant.py index cfa2465..b958d79 100755 --- a/assistant.py +++ b/assistant.py @@ -193,11 +193,10 @@ def chat2(args, user_input, stream=True): elif type(command_result) == str: # sometimes I want to change the user prompt with a command user_input = command_result + print('\033[91m' + 'assistant' + '\033[0m: ', end='') if args.reflect: - print('assistant: ', end='') result = reflection_mode(user_input, stream) else: - print('assistant: ', end='') result = chat(user_input, stream) conversation += 'user: ' + user_input + '\n'