Spaces:
Sleeping
Sleeping
import streamlit as st | |
from transformers import pipeline | |
st.title("TLDR-izer") | |
article = st.text_area('Text to be summarized:', height=200) | |
if st.button("Do the Magic!"): | |
summarizer = pipeline("summarization", model="facebook/bart-large-cnn") | |
output= summarizer(article, min_length = 100 , max_length=200) | |
st.write(output[0]['summary_text']) | |