Reality123b commited on
Commit
f95b164
·
verified ·
1 Parent(s): 75ce8d5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -297,8 +297,8 @@ class XylariaChat:
297
 
298
  # Clear conversation
299
  clear.click(
300
- fn=lambda: None,
301
- inputs=None,
302
  outputs=[chatbot],
303
  queue=False
304
  ).then(
@@ -322,7 +322,7 @@ class XylariaChat:
322
  # Load chat history on interface load
323
  demo.load(self.reset_conversation, None, None)
324
 
325
- return demo
326
 
327
  def format_chat_history(self):
328
  """Formats the chat history for display in the sidebar."""
 
297
 
298
  # Clear conversation
299
  clear.click(
300
+ fn=lambda _: None, # Corrected lambda to accept an argument
301
+ inputs=gr.State(None), # Pass a dummy state value
302
  outputs=[chatbot],
303
  queue=False
304
  ).then(
 
322
  # Load chat history on interface load
323
  demo.load(self.reset_conversation, None, None)
324
 
325
+ return demo
326
 
327
  def format_chat_history(self):
328
  """Formats the chat history for display in the sidebar."""