Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
~ app.py
Browse files
app.py
CHANGED
@@ -25,7 +25,7 @@ def translate(text, num_beams=4, num_return_sequences=4):
|
|
25 |
output = gr.outputs.Textbox()
|
26 |
with gr.Accordion("Advanced Options"):
|
27 |
num_beams = gr.inputs.Slider(2, 10, step=1, label="Number of beams", default=4)
|
28 |
-
num_return_sequences = gr.inputs.Slider(2, 10, step=1, label="Number of
|
29 |
iface = gr.Interface(fn=translate, inputs=["text", num_beams, num_return_sequences], outputs=output)
|
30 |
iface.launch()
|
31 |
|
|
|
25 |
output = gr.outputs.Textbox()
|
26 |
with gr.Accordion("Advanced Options"):
|
27 |
num_beams = gr.inputs.Slider(2, 10, step=1, label="Number of beams", default=4)
|
28 |
+
num_return_sequences = gr.inputs.Slider(2, 10, step=1, label="Number of returned sequences", default=4)
|
29 |
iface = gr.Interface(fn=translate, inputs=["text", num_beams, num_return_sequences], outputs=output)
|
30 |
iface.launch()
|
31 |
|