rachea commited on
Commit
c53181a
·
verified ·
1 Parent(s): 2858ef0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -4
app.py CHANGED
@@ -1,10 +1,12 @@
1
  import gradio as gr
 
2
 
3
- def echo(message, history):
4
- return message
 
5
 
6
- print("hello, world!")
7
 
8
- chatbot = gr.ChatInterface(echo, type="messages") #chatbot UI - conversation history and user input
 
9
 
10
  chatbot.launch()
 
1
  import gradio as gr
2
+ import random
3
 
4
+ def respond_yes_no_random(message, history):
5
+ responses = ["yes" , "No"]
6
+ return random.choice(responses)
7
 
 
8
 
9
+
10
+ chatbot = gr.ChatInterface(respond_yes_no_random, type="messages") , title="Yes No Bot"
11
 
12
  chatbot.launch()