Spaces:
Runtime error
Runtime error
Commit
·
47837be
1
Parent(s):
6277b98
working on text splitting
Browse files
app.py
CHANGED
|
@@ -98,11 +98,10 @@ def main() -> None:
|
|
| 98 |
sentences = split_sentences_by_token_length(nltk.sent_tokenize(target_text_input), 600)
|
| 99 |
for sentence in sentences:
|
| 100 |
output = pipe(sentence)
|
| 101 |
-
st.markdown(output[0]["summary_text"])
|
| 102 |
-
|
| 103 |
-
|
| 104 |
-
|
| 105 |
-
# display_summary(summary_sentences)
|
| 106 |
|
| 107 |
|
| 108 |
if __name__ == "__main__":
|
|
|
|
| 98 |
sentences = split_sentences_by_token_length(nltk.sent_tokenize(target_text_input), 600)
|
| 99 |
for sentence in sentences:
|
| 100 |
output = pipe(sentence)
|
| 101 |
+
# st.markdown(output[0]["summary_text"])
|
| 102 |
+
summary = output[0]["summary_text"]
|
| 103 |
+
summary_sentences.append(summary.split("."))
|
| 104 |
+
display_summary(summary_sentences)
|
|
|
|
| 105 |
|
| 106 |
|
| 107 |
if __name__ == "__main__":
|