Update app.py
Browse files
app.py
CHANGED
@@ -263,7 +263,7 @@ def highlight_entities(article_content,summary_output):
|
|
263 |
print("")
|
264 |
print(summary_output)
|
265 |
|
266 |
-
summary_output = summary_output.replace("
|
267 |
|
268 |
print("")
|
269 |
print(summary_output)
|
@@ -319,7 +319,7 @@ def schleifer_model():
|
|
319 |
|
320 |
@st.experimental_singleton(suppress_st_warning=True)
|
321 |
def google_model():
|
322 |
-
model_name = 'google/pegasus-
|
323 |
summarizer = pipeline('summarization',model=model_name, tokenizer=model_name,
|
324 |
device=0 if torch.cuda.is_available() else -1)
|
325 |
return summarizer
|
|
|
263 |
print("")
|
264 |
print(summary_output)
|
265 |
|
266 |
+
summary_output = summary_output.replace("n<","")
|
267 |
|
268 |
print("")
|
269 |
print(summary_output)
|
|
|
319 |
|
320 |
@st.experimental_singleton(suppress_st_warning=True)
|
321 |
def google_model():
|
322 |
+
model_name = 'google/pegasus-xsum'
|
323 |
summarizer = pipeline('summarization',model=model_name, tokenizer=model_name,
|
324 |
device=0 if torch.cuda.is_available() else -1)
|
325 |
return summarizer
|