Spaces:
Sleeping
Sleeping
File size: 637 Bytes
f1455e6 1e3ff24 f1455e6 51ae59d f91927e 1e3ff24 1918fab f1455e6 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
import gradio as gr
import random
# import lines go at the top! Any libraries I need to import go up ^
def magic_eight_ball(message, history):
return random.choice(['Possibly', 'Absolutely not', 'If you try', "Why not", 'Yes!'])
#def yes_or_no(message, history):
# return random.choice(['Yes','No'])
# always need two parameters in hf
# def echo(message, history):
# return message
print("hello world")
chatbot = gr.ChatInterface(magic_eight_ball, type="messages", title = "Magic Eight Ball Chat")
# declaring chatbot so that user can interact and see their conversation history and send new messages
chatbot.launch() |