Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -27,6 +27,9 @@ def init_db():
|
|
| 27 |
conn.commit()
|
| 28 |
conn.close()
|
| 29 |
|
|
|
|
|
|
|
|
|
|
| 30 |
# Retrieve past chat history
|
| 31 |
def get_chat_history(user_id):
|
| 32 |
conn = sqlite3.connect("chat_history.db")
|
|
@@ -100,5 +103,4 @@ with col2:
|
|
| 100 |
delete_chat_history(st.session_state.user_id)
|
| 101 |
st.experimental_rerun()
|
| 102 |
|
| 103 |
-
|
| 104 |
-
init_db()
|
|
|
|
| 27 |
conn.commit()
|
| 28 |
conn.close()
|
| 29 |
|
| 30 |
+
# Initialize Database
|
| 31 |
+
init_db()
|
| 32 |
+
|
| 33 |
# Retrieve past chat history
|
| 34 |
def get_chat_history(user_id):
|
| 35 |
conn = sqlite3.connect("chat_history.db")
|
|
|
|
| 103 |
delete_chat_history(st.session_state.user_id)
|
| 104 |
st.experimental_rerun()
|
| 105 |
|
| 106 |
+
|
|
|