aadya1762 commited on
Commit
16a69d8
·
1 Parent(s): 5ca1c38

add clear history functionality

Browse files
Files changed (1) hide show
  1. app.py +4 -0
app.py CHANGED
@@ -53,6 +53,10 @@ def main():
53
  st.session_state.selected_task = selected_task
54
  st.rerun()
55
 
 
 
 
 
56
 
57
  # Main content area
58
  # Initialize model with the selected configuration
 
53
  st.session_state.selected_task = selected_task
54
  st.rerun()
55
 
56
+ # Clear chat history button
57
+ if st.button("Clear Chat History"):
58
+ st.session_state.messages = [] # Clear the chat history
59
+ st.success("Chat history cleared!")
60
 
61
  # Main content area
62
  # Initialize model with the selected configuration