Commit 79533a8c by Ziyuan Nan

Fix rich print error

parent 7f078368
from anpl.synthesizer import raw_query, msg from anpl.synthesizer import raw_query, msg
from utils import sys_str, system_info, multiline_input, select_task, set_openai_key, rich_dumps from utils import sys_str, system_info, multiline_input, select_task, set_openai_key, rich_dumps
from rich.prompt import IntPrompt, Confirm, Prompt from rich.prompt import IntPrompt, Confirm, Prompt
from rich import print
from anpl.sandbox import import_module_from_string from anpl.sandbox import import_module_from_string
import numpy as np import numpy as np
import time import time
...@@ -9,7 +8,7 @@ import time ...@@ -9,7 +8,7 @@ import time
history = [] history = []
def print_msg(message): def print_msg(message):
role, text = message["role"], message["content"] role, text = message["role"], message["content"]
print(f"[blue]{role}[/blue]:") print(f"{role}:")
print(text) print(text)
def print_history(): def print_history():
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment