Ifeeab05 commited on
Commit
4904de0
·
verified ·
1 Parent(s): 1f54368

added one or8g

Browse files
Files changed (1) hide show
  1. app.py +5 -3
app.py CHANGED
@@ -1,7 +1,9 @@
1
  import gradio as gr
2
- def echo(message, history):
3
- return message
 
 
4
 
5
  print("hELLO World")
6
- chatbot = gr.ChatInterface(echo, type="messages") #chatbot UI - convo history & user input
7
  chatbot.launch()
 
1
  import gradio as gr
2
+ import random as rn
3
+ def respond_yes_no_randomly(message, history):
4
+ responses = ["Yes", "No"]
5
+ return random.choices(responses) #added here
6
 
7
  print("hELLO World")
8
+ chatbot = gr.ChatInterface(respond_yes_no_random, type="messages", title="Yes No Bot") #chatbot UI - convo history & user input
9
  chatbot.launch()