Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -95,10 +95,11 @@ bot.write("Hello human! Wanna practice naming some words?")
|
|
95 |
|
96 |
#for showing history of messages
|
97 |
for message in st.session_state.messages:
|
98 |
-
|
99 |
-
|
100 |
-
st.markdown(message['content']
|
101 |
-
|
|
|
102 |
st.markdown(message['content'])
|
103 |
|
104 |
def get_text():
|
|
|
95 |
|
96 |
#for showing history of messages
|
97 |
for message in st.session_state.messages:
|
98 |
+
if message['role'] == 'user':
|
99 |
+
with st.chat_message(message['role'], avatar='simon.jpg'):
|
100 |
+
st.markdown(message['content'])
|
101 |
+
else:
|
102 |
+
with st.chat_message(message['role']):
|
103 |
st.markdown(message['content'])
|
104 |
|
105 |
def get_text():
|