Update app.py
Browse files
app.py
CHANGED
@@ -603,7 +603,9 @@ def remove_stop_words_from_lines(lines, stop_words):
|
|
603 |
cleaned_lines.append(" ".join(cleaned_words))
|
604 |
return cleaned_lines
|
605 |
|
606 |
-
#
|
|
|
|
|
607 |
if query:
|
608 |
# پیدا کردن ۱۰ خط نزدیکتر به سوال
|
609 |
closest_lines = find_closest_lines(query, doc_texts, stop_words, top_n=3)
|
|
|
603 |
cleaned_lines.append(" ".join(cleaned_words))
|
604 |
return cleaned_lines
|
605 |
|
606 |
+
# حفظ تاریخچه چت
|
607 |
+
if "chat_history" not in st.session_state:
|
608 |
+
st.session_state.chat_history = []
|
609 |
if query:
|
610 |
# پیدا کردن ۱۰ خط نزدیکتر به سوال
|
611 |
closest_lines = find_closest_lines(query, doc_texts, stop_words, top_n=3)
|