Spaces:
Sleeping
Sleeping
| from transformers import pipeline | |
| def summarize_with_bart(text): | |
| pipe = pipeline("text2text-generation", model="EE21/Fine-tuned-BART-ToS-Summarization") | |
| summary = pipe(text, max_length=130, min_length=30, do_sample=False)[0]['generated_text'] | |
| return summary |