Closed signebedi closed 1 year ago
When we want to re-write our queries in chat, we should be able to use keyboard interrupts without breaking the program. Something like:
chat
# Get user input try: i = await session.prompt_async(ANSI(f"{CYAN}> {RESET}")) # i = await ainput(f"{CYAN}> ") tag,question = get_tag_from_text(i) prompt_length = len(question) # handle keyboard interrupt except KeyboardInterrupt: i = None
When we want to re-write our queries in
chat
, we should be able to use keyboard interrupts without breaking the program. Something like: