Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
|
2 |
import os
|
3 |
-
os.system("pip install gradio[notebook]")
|
4 |
import gradio as gr
|
5 |
|
6 |
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
|
@@ -16,11 +16,12 @@ def predict(input_text):
|
|
16 |
return decoded_prediction
|
17 |
|
18 |
iface = gr.Interface(fn=predict,
|
19 |
-
inputs=gr.inputs.Textbox(lines=2,
|
|
|
20 |
outputs="text",
|
21 |
-
title="My
|
22 |
description="Summarize large blocks of text.",
|
23 |
-
theme="
|
24 |
analytics_enabled=False)
|
25 |
|
26 |
iface.launch()
|
|
|
1 |
|
2 |
import os
|
3 |
+
#os.system("pip install gradio[notebook]")
|
4 |
import gradio as gr
|
5 |
|
6 |
from transformers import AutoTokenizer, AutoModelForSeq2SeqLM
|
|
|
16 |
return decoded_prediction
|
17 |
|
18 |
iface = gr.Interface(fn=predict,
|
19 |
+
inputs=gr.inputs.Textbox(lines=2,
|
20 |
+
placeholder="Enter your text..."),
|
21 |
outputs="text",
|
22 |
+
title="My First App",
|
23 |
description="Summarize large blocks of text.",
|
24 |
+
theme="dark",
|
25 |
analytics_enabled=False)
|
26 |
|
27 |
iface.launch()
|