Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -16,7 +16,15 @@ import os
|
|
16 |
def on_button_click(query):
|
17 |
st.session_state['button_clicked'] = query
|
18 |
|
19 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
20 |
|
21 |
def cloud_button(label, query, key=None, color=None, overlap=30):
|
22 |
button_id = f"cloud-button-{key or label}"
|
|
|
16 |
def on_button_click(query):
|
17 |
st.session_state['button_clicked'] = query
|
18 |
|
19 |
+
|
20 |
+
|
21 |
+
def display_chat_history(chat_history):
|
22 |
+
for sender, msg, _ in chat_history:
|
23 |
+
background_color = "#FFA07A" if sender == "User" else "#caf"
|
24 |
+
st.markdown(f"<div style='background-color: {background_color}; padding: 10px; border-radius: 10px; margin: 10px;'>{sender}: {msg}</div>", unsafe_allow_html=True)
|
25 |
+
|
26 |
+
|
27 |
+
|
28 |
|
29 |
def cloud_button(label, query, key=None, color=None, overlap=30):
|
30 |
button_id = f"cloud-button-{key or label}"
|