Hugging Face
Models
Datasets
Spaces
Posts
Docs
Enterprise
Pricing
Log In
Sign Up
Spaces:
xnetba
/
bart
like
0
Sleeping
App
Files
Files
Community
Fetching metadata from the HF Docker repository...
xnetba
commited on
Jul 7, 2023
Commit
c268f0b
·
1 Parent(s):
93da9c8
Create app.py
Browse files
Files changed (1)
hide
show
app.py
+8
-0
app.py
ADDED
Viewed
@@ -0,0 +1,8 @@
1
+
from transformers import pipeline
2
+
3
+
generator = pipeline("text-generation", model="distilgpt2")
4
+
generator(
5
+
"In this course, we will teach you how to",
6
+
max_length=30,
7
+
num_return_sequences=2,
8
+
)