Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -8,7 +8,7 @@ set_seed(randint(randint(1000,10000),randint(50000,300000)))
|
|
8 |
def gpt2(string, max_length):
|
9 |
return generator(string, max_length=max_length, num_return_sequences=1)[0]['generated_text']
|
10 |
|
11 |
-
max_length_slider = gr.inputs.Slider(minimum=50, maximum=500, step=10, default=
|
12 |
|
13 |
iface = gr.Interface(fn=gpt2, inputs=["text", max_length_slider], outputs="text")
|
14 |
|
|
|
8 |
def gpt2(string, max_length):
|
9 |
return generator(string, max_length=max_length, num_return_sequences=1)[0]['generated_text']
|
10 |
|
11 |
+
max_length_slider = gr.inputs.Slider(minimum=50, maximum=500, step=10, default=100, label="Maximum Length")
|
12 |
|
13 |
iface = gr.Interface(fn=gpt2, inputs=["text", max_length_slider], outputs="text")
|
14 |
|