def main(get="", original_path=""): logger.debug('Assistant start at ' + str(os.getcwd())) asci_banner(START_SCREEN_NAME) if get == '': speak("Hello sir, how can i help you?") while True: get = string_process(get_input()) print() if check_done(get): break if get == 'clear': clear_screen() else: get = get.strip() if get != "" and get != "\n": msg = ai(get) speak(msg) line_sep() speak('Good Bye Sir.') asci_banner('BYE!') else: msg = ai(get) speak(msg) line_sep(t=1) logger.debug("Bot stopped.")
def cp_start(): try: from system.screen_text import asci_banner from tools.OJ.cp import cp_manager from settings.settings import START_SCREEN_NAME asci_banner(' ' + START_SCREEN_NAME) total = len(sys.argv) lt = list(sys.argv) lt = lt[1:] msg = '' for w in lt: msg += w + ' ' cp_manager(msg.strip()) pt = '-' * 50 cprint(pt, 'magenta') cprint(f' (^-^) -> Good luck sir.', 'green') cprint(pt, 'magenta') except Exception as e: cprint("Can't open sir.", 'red')
def main(get='',orginal_path='') : logger.debug('Bot starts at ' + str(os.getcwd())) asci_banner(START_SCREEN_NAME) if get == '': speak('Hello sir, how can I help you?') while True : get =string_process(get_audio()) print() if check_done(get): break if get == 'clear': clear_screen() else : msg = ai(get,orginal_path) speak(msg) line_sep() speak('Good Bye, Sir.') asci_banner('BYE!') else : msg = ai(get,orginal_path) speak(msg) line_sep(t=2) logger.debug('Bot stopped.')