Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -116,14 +116,14 @@ def generate_text(prompt, num_samples, max_new_tokens, temperature, top_k, top_p
|
|
116 |
demo = gr.Interface(
|
117 |
fn=generate_text,
|
118 |
inputs=[
|
119 |
-
gr.
|
120 |
-
gr.
|
121 |
-
gr.
|
122 |
-
gr.
|
123 |
-
gr.
|
124 |
-
gr.
|
125 |
-
gr.
|
126 |
-
gr.
|
127 |
],
|
128 |
outputs="text",
|
129 |
title="GPT Text Generator",
|
|
|
116 |
demo = gr.Interface(
|
117 |
fn=generate_text,
|
118 |
inputs=[
|
119 |
+
gr.Textbox(lines=2, placeholder="Enter your prompt here...", value="Write a short story about a boy:"),
|
120 |
+
gr.Slider(minimum=1, maximum=10, step=1, value=1, label="Number of Samples"),
|
121 |
+
gr.Slider(minimum=10, maximum=200, step=1, value=75, label="Max New Tokens"),
|
122 |
+
gr.Slider(minimum=0.1, maximum=1.0, step=0.1, value=0.8, label="Temperature"),
|
123 |
+
gr.Slider(minimum=1, maximum=100, step=1, value=50, label="Top-k"),
|
124 |
+
gr.Slider(minimum=0.1, maximum=1.0, step=0.1, value=0.85, label="Top-p"),
|
125 |
+
gr.Slider(minimum=1.0, maximum=2.0, step=0.1, value=1.1, label="Repetition Penalty"),
|
126 |
+
gr.Number(value=100264, label="End-of-Response Token ID")
|
127 |
],
|
128 |
outputs="text",
|
129 |
title="GPT Text Generator",
|