Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -28,13 +28,9 @@ st.markdown(
|
|
28 |
st.markdown("""Please do note that the model will take longer to generate summaries for documents that are too long.""")
|
29 |
|
30 |
st.markdown(
|
31 |
-
"As input we only ingests
|
32 |
)
|
33 |
|
34 |
-
st.markdown(
|
35 |
-
"""- Raw text entered in text box.
|
36 |
-
- URL of an article to be summarized."""
|
37 |
-
)
|
38 |
|
39 |
st.markdown("---")
|
40 |
|
@@ -60,8 +56,8 @@ if summarize:
|
|
60 |
|
61 |
with st.spinner(text="Loading Model and Extracting summary. This might take a few seconds depending on the length of your text..."):
|
62 |
model = model()
|
63 |
-
summarized_text = text_to_summarize if len(text_to_summarize) > 60 else ''.join(model(body, min_length=60))
|
64 |
-
|
65 |
st.subheader("Summarized text")
|
66 |
|
67 |
st.write(summarized_text)
|
|
|
28 |
st.markdown("""Please do note that the model will take longer to generate summaries for documents that are too long.""")
|
29 |
|
30 |
st.markdown(
|
31 |
+
"As input we only ingests Raw text entered in text box or URL of an article to be summarised."
|
32 |
)
|
33 |
|
|
|
|
|
|
|
|
|
34 |
|
35 |
st.markdown("---")
|
36 |
|
|
|
56 |
|
57 |
with st.spinner(text="Loading Model and Extracting summary. This might take a few seconds depending on the length of your text..."):
|
58 |
model = model()
|
59 |
+
#summarized_text = text_to_summarize if len(text_to_summarize) > 60 else ''.join(model(body, min_length=60))
|
60 |
+
summarized_text = ''.join(model(body, min_length=60))
|
61 |
st.subheader("Summarized text")
|
62 |
|
63 |
st.write(summarized_text)
|