RomZay commited on
Commit
a188893
·
verified ·
1 Parent(s): befce47

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -174,15 +174,15 @@ with gr.Blocks(css=".chatbox {height: 400px; overflow-y: auto; border: 1px solid
174
  return render_message(history), history
175
 
176
  msg_input.submit(user_interaction,
177
- inputs=[msg_input, api_key_input, system_message, max_tokens, top_p, temperature],
178
  outputs=[chatbot_output, history_state, msg_input, last_message_state])
179
 
180
  send_btn.click(user_interaction,
181
- inputs=[msg_input, api_key_input, system_message, max_tokens, top_p, temperature],
182
  outputs=[chatbot_output, history_state, msg_input, last_message_state])
183
 
184
- regen_btn.click(clear_history,
185
- inputs=[api_key_input],
186
  outputs=[chatbot_output, history_state])
187
 
188
  def authorize_and_proceed(user, api_key):
 
174
  return render_message(history), history
175
 
176
  msg_input.submit(user_interaction,
177
+ inputs=[msg_input, history_state, api_key_input, max_tokens, top_p, temperature],
178
  outputs=[chatbot_output, history_state, msg_input, last_message_state])
179
 
180
  send_btn.click(user_interaction,
181
+ inputs=[msg_input, history_state, api_key_input, max_tokens, top_p, temperature],
182
  outputs=[chatbot_output, history_state, msg_input, last_message_state])
183
 
184
+ regen_btn.click(regenerate_response,
185
+ inputs=[history_state, last_message_state, max_tokens, top_p, temperature],
186
  outputs=[chatbot_output, history_state])
187
 
188
  def authorize_and_proceed(user, api_key):