Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -676,11 +676,13 @@ if prompt :
|
|
| 676 |
st.markdown(prompt)
|
| 677 |
|
| 678 |
# Generate AI response
|
| 679 |
-
with
|
| 680 |
-
|
| 681 |
-
|
|
|
|
| 682 |
|
| 683 |
-
|
|
|
|
| 684 |
|
| 685 |
try:
|
| 686 |
# Generate response using the agent executor
|
|
@@ -706,11 +708,14 @@ if prompt :
|
|
| 706 |
#combined_text = f"{cleaned_text}\n\n---\n\n**Trust Tip**: {trust_tip}\n\n**Suggestion**: {suggestion}"
|
| 707 |
combined_text = f"{cleaned_text}\n\n---\n\n**Trust Tip**: {trust_tip}\n\n**Suggestion**: {suggestion}"
|
| 708 |
|
| 709 |
-
st.markdown(combined_text,unsafe_allow_html=True)
|
| 710 |
|
| 711 |
#seprtor= st.markdown("---") # Add a separator
|
| 712 |
#t_tip= st.markdown(f"**Trust Tip**: {trust_tip}")
|
| 713 |
#s_sug- st.markdown(f"**Suggestion**: {suggestion}")
|
|
|
|
|
|
|
|
|
|
| 714 |
|
| 715 |
|
| 716 |
|
|
|
|
| 676 |
st.markdown(prompt)
|
| 677 |
|
| 678 |
# Generate AI response
|
| 679 |
+
with response_placeholder:
|
| 680 |
+
with st.chat_message("assistant"):
|
| 681 |
+
add_dot_typing_animation() # Adds the CSS for the typing animation
|
| 682 |
+
display_typing_indicator()
|
| 683 |
|
| 684 |
+
|
| 685 |
+
full_response = ""
|
| 686 |
|
| 687 |
try:
|
| 688 |
# Generate response using the agent executor
|
|
|
|
| 708 |
#combined_text = f"{cleaned_text}\n\n---\n\n**Trust Tip**: {trust_tip}\n\n**Suggestion**: {suggestion}"
|
| 709 |
combined_text = f"{cleaned_text}\n\n---\n\n**Trust Tip**: {trust_tip}\n\n**Suggestion**: {suggestion}"
|
| 710 |
|
| 711 |
+
#st.markdown(combined_text,unsafe_allow_html=True)
|
| 712 |
|
| 713 |
#seprtor= st.markdown("---") # Add a separator
|
| 714 |
#t_tip= st.markdown(f"**Trust Tip**: {trust_tip}")
|
| 715 |
#s_sug- st.markdown(f"**Suggestion**: {suggestion}")
|
| 716 |
+
with response_placeholder:
|
| 717 |
+
with st.chat_message("assistant"):
|
| 718 |
+
st.markdown(combined_text, unsafe_allow_html=True)
|
| 719 |
|
| 720 |
|
| 721 |
|