Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -3,9 +3,8 @@ import spaces
|
|
3 |
from transformers import pipeline
|
4 |
|
5 |
# Initialize Model
|
6 |
-
get_completion = pipeline("summarization", model="sshleifer/distilbart-cnn-12-6", device=0
|
7 |
|
8 |
-
@spaces.GPU(duration=120)
|
9 |
def summarize(input: str) -> str:
|
10 |
"""
|
11 |
Summarize the given input text using the sshleifer/distilbart-cnn-12-6 model.
|
|
|
3 |
from transformers import pipeline
|
4 |
|
5 |
# Initialize Model
|
6 |
+
get_completion = pipeline("summarization", model="sshleifer/distilbart-cnn-12-6", device=0)
|
7 |
|
|
|
8 |
def summarize(input: str) -> str:
|
9 |
"""
|
10 |
Summarize the given input text using the sshleifer/distilbart-cnn-12-6 model.
|