ChatbotLab_Aug7 / app.py
Janec09's picture
Update app.py
2fb4dba verified
raw
history blame
596 Bytes
import gradio as gr
import random
def magic_8_ball(message, history):
return random.choice(['Let's goooo!!!!!', 'Yes haha', 'NO', 'GREAT!!!'])
#def yes_or_no(message, history):
#return random.choice(['Yes', 'No'])
# def echo(message, history):
# return message
print("Hello World!")
chatbot = gr.ChatInterface(
magic_8_ball,
title = "Magic 8 Ball",
description = "Ask any yes or no question to learn about your future",
type = "messages"
)
#defining my chatbot so users can interact and see their conversation history and send new messages!
chatbot.launch()