clarissah commited on
Commit
1d3c732
·
verified ·
1 Parent(s): 5fabe04

updated to import random and yes or no response

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -1,8 +1,12 @@
1
  import gradio as gr
 
2
 
3
  def echo(message, history):
 
 
 
4
  return message
5
-
6
  chatbot = gr.ChatInterface(echo, type = "messages")
7
 
8
  chatbot.launch()
 
1
  import gradio as gr
2
+ import random
3
 
4
  def echo(message, history):
5
+ choices = ["yes", "no"]
6
+ #use random to select one of these choices
7
+
8
  return message
9
+ print(f{random.choice(choices)})
10
  chatbot = gr.ChatInterface(echo, type = "messages")
11
 
12
  chatbot.launch()