Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,11 +1,16 @@
|
|
| 1 |
-
import gradio as gr
|
| 2 |
import random
|
|
|
|
|
|
|
| 3 |
|
| 4 |
def respond_yes_no_randomly(message, history):
|
| 5 |
responses = ["Yes", "No"]
|
| 6 |
return random.choice(responses)
|
| 7 |
|
| 8 |
-
|
| 9 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 10 |
|
| 11 |
demo.launch()
|
|
|
|
|
|
|
| 1 |
import random
|
| 2 |
+
import gradio as gr
|
| 3 |
+
|
| 4 |
|
| 5 |
def respond_yes_no_randomly(message, history):
|
| 6 |
responses = ["Yes", "No"]
|
| 7 |
return random.choice(responses)
|
| 8 |
|
| 9 |
+
|
| 10 |
+
demo = gr.ChatInterface(
|
| 11 |
+
respond_yes_no_randomly,
|
| 12 |
+
title="Yes No Bot",
|
| 13 |
+
description="This chatbot responds yes or no to your questions!",
|
| 14 |
+
)
|
| 15 |
|
| 16 |
demo.launch()
|