Spaces:
Sleeping
Sleeping
Update app.py
Browse files
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 |
-
|
| 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."""
|