Spaces:
Sleeping
Sleeping
Amanda Sackey
commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,9 +1,11 @@
|
|
| 1 |
import gradio as gr
|
|
|
|
| 2 |
|
| 3 |
-
def
|
| 4 |
-
|
|
|
|
| 5 |
|
| 6 |
-
print("Hello World")
|
| 7 |
-
chatbot = gr.ChatInterface(
|
| 8 |
|
| 9 |
chatbot.launch()
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
+
import random
|
| 3 |
|
| 4 |
+
def respond_yes_no_randomly(message, history):
|
| 5 |
+
responses = ["Yes","No"] #added here
|
| 6 |
+
return random.choice(responses) #added here
|
| 7 |
|
| 8 |
+
print("Hello World!")
|
| 9 |
+
chatbot = gr.ChatInterface(respond_yes_no_randomly, type="messages", title = "Yes No BOT") #chatbot UI - conversion history and user input
|
| 10 |
|
| 11 |
chatbot.launch()
|