Arafath10 commited on
Commit
cd7f54a
1 Parent(s): b13ec75

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -2,8 +2,12 @@ import gradio as gr
2
  from chatterbot import ChatBot
3
  from chatterbot.trainers import ListTrainer
4
 
 
 
 
5
  def greet(name):
6
- return "Hello " + name + "!!"
 
7
 
8
  iface = gr.Interface(fn=greet, inputs="text", outputs="text")
9
  iface.launch()
 
2
  from chatterbot import ChatBot
3
  from chatterbot.trainers import ListTrainer
4
 
5
+ chatbot = ChatBot("Chatpot")
6
+
7
+
8
  def greet(name):
9
+ text = chatbot.get_response(name)
10
+ return "Hello " + text + "!!"
11
 
12
  iface = gr.Interface(fn=greet, inputs="text", outputs="text")
13
  iface.launch()