Update app.py
Browse files
app.py
CHANGED
@@ -142,7 +142,10 @@ claims_extracted = st.session_state.claims_extraction
|
|
142 |
chunk_size = 350
|
143 |
|
144 |
# Split the extracted claims into chunks
|
145 |
-
|
|
|
|
|
|
|
146 |
|
147 |
# Process each chunk with the BERT-based model
|
148 |
summaries = []
|
|
|
142 |
chunk_size = 350
|
143 |
|
144 |
# Split the extracted claims into chunks
|
145 |
+
if isinstance(claims_extracted, str):
|
146 |
+
chunks = [claims_extracted[i:i+chunk_size] for i in range(0, len(claims_extracted), chunk_size)]
|
147 |
+
else:
|
148 |
+
chunks = []
|
149 |
|
150 |
# Process each chunk with the BERT-based model
|
151 |
summaries = []
|