Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -123,6 +123,12 @@ def main():
|
|
123 |
document_sections.extend(divide_document(file_content, max_length))
|
124 |
|
125 |
if len(document_sections) > 0:
|
|
|
|
|
|
|
|
|
|
|
|
|
126 |
st.markdown("**Chat with the model:**")
|
127 |
for i, section in enumerate(list(document_sections)):
|
128 |
if i in document_responses:
|
@@ -137,10 +143,6 @@ def main():
|
|
137 |
filename = generate_filename(f"{user_prompt}_section_{i+1}", choice)
|
138 |
create_file(filename, user_prompt, response)
|
139 |
st.sidebar.markdown(get_table_download_link(filename), unsafe_allow_html=True)
|
140 |
-
|
141 |
-
st.markdown("**Sections of the uploaded file:**")
|
142 |
-
for i, section in enumerate(list(document_sections)):
|
143 |
-
st.markdown(f"**Section {i+1}**\n{section}")
|
144 |
|
145 |
if st.button('💬 Chat'):
|
146 |
st.write('Thinking and Reasoning with your inputs...')
|
|
|
123 |
document_sections.extend(divide_document(file_content, max_length))
|
124 |
|
125 |
if len(document_sections) > 0:
|
126 |
+
|
127 |
+
st.markdown("**Sections of the uploaded file:**")
|
128 |
+
for i, section in enumerate(list(document_sections)):
|
129 |
+
st.markdown(f"**Section {i+1}**\n{section}")
|
130 |
+
|
131 |
+
|
132 |
st.markdown("**Chat with the model:**")
|
133 |
for i, section in enumerate(list(document_sections)):
|
134 |
if i in document_responses:
|
|
|
143 |
filename = generate_filename(f"{user_prompt}_section_{i+1}", choice)
|
144 |
create_file(filename, user_prompt, response)
|
145 |
st.sidebar.markdown(get_table_download_link(filename), unsafe_allow_html=True)
|
|
|
|
|
|
|
|
|
146 |
|
147 |
if st.button('💬 Chat'):
|
148 |
st.write('Thinking and Reasoning with your inputs...')
|