nageshsomayajula commited on
Commit
761854b
·
1 Parent(s): e5f754c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -4
app.py CHANGED
@@ -11,16 +11,12 @@ def call_chat(message)
11
  outputs = model.generate(**inputs, max_new_tokens=20)
12
  return tokenizer.decode(outputs[0], skip_special_tokens=True)
13
 
14
-
15
-
16
-
17
  with gr.Blocks() as demo:
18
  chatbot = gr.Chatbot()
19
  msg = gr.Textbox()
20
  clear = gr.ClearButton([msg, chatbot])
21
 
22
  def respond(message, chat_history):
23
- bot_message = random.choice(["How are you?", "I love you", "I'm very hungry"])
24
  chat_history.append((message, bot_message))
25
  time.sleep(2)
26
  return "", chat_history
 
11
  outputs = model.generate(**inputs, max_new_tokens=20)
12
  return tokenizer.decode(outputs[0], skip_special_tokens=True)
13
 
 
 
 
14
  with gr.Blocks() as demo:
15
  chatbot = gr.Chatbot()
16
  msg = gr.Textbox()
17
  clear = gr.ClearButton([msg, chatbot])
18
 
19
  def respond(message, chat_history):
 
20
  chat_history.append((message, bot_message))
21
  time.sleep(2)
22
  return "", chat_history