Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -100,8 +100,17 @@ def get_response(system_message, chat_history, user_text, max_new_tokens=256):
|
|
100 |
# Streamlit UI Setup
|
101 |
st.set_page_config(page_title="NASA ChatBot", page_icon="π")
|
102 |
|
103 |
-
st.title("π
|
104 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
105 |
|
106 |
# Custom CSS for chat styling
|
107 |
st.markdown("""
|
|
|
100 |
# Streamlit UI Setup
|
101 |
st.set_page_config(page_title="NASA ChatBot", page_icon="π")
|
102 |
|
103 |
+
st.title("π HAL")
|
104 |
+
# Chat Display with Updated Styling
|
105 |
+
st.markdown("<div class='container'>", unsafe_allow_html=True)
|
106 |
+
|
107 |
+
for message in st.session_state.chat_history:
|
108 |
+
if message["role"] == "user":
|
109 |
+
st.markdown(f"<div class='user-msg'><strong>You:</strong> {message['content']}</div>", unsafe_allow_html=True)
|
110 |
+
else:
|
111 |
+
st.markdown(f"<div class='assistant-msg'><strong>Bot:</strong> {message['content']}</div>", unsafe_allow_html=True)
|
112 |
+
|
113 |
+
st.markdown("</div>", unsafe_allow_html=True)
|
114 |
|
115 |
# Custom CSS for chat styling
|
116 |
st.markdown("""
|