Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -1,6 +1,5 @@
|
|
1 |
# now to create an interface with gradio
|
2 |
import gradio as gr
|
3 |
-
from transformers import pipeline
|
4 |
|
5 |
from gradio_space_ci import enable_space_ci
|
6 |
|
@@ -8,13 +7,10 @@ enable_space_ci()
|
|
8 |
|
9 |
|
10 |
|
11 |
-
pipe = pipeline("text2text-generation", model="google/flan-t5-base")
|
12 |
-
|
13 |
# a function that uses the pipeline
|
14 |
# takes text as input and passes it to the pipeline
|
15 |
def chat(text):
|
16 |
-
|
17 |
-
return output
|
18 |
# fucntion , input of type text , output of type text
|
19 |
demo = gr.Interface(chat , "text" , "text" )
|
20 |
demo.launch()
|
|
|
1 |
# now to create an interface with gradio
|
2 |
import gradio as gr
|
|
|
3 |
|
4 |
from gradio_space_ci import enable_space_ci
|
5 |
|
|
|
7 |
|
8 |
|
9 |
|
|
|
|
|
10 |
# a function that uses the pipeline
|
11 |
# takes text as input and passes it to the pipeline
|
12 |
def chat(text):
|
13 |
+
return text
|
|
|
14 |
# fucntion , input of type text , output of type text
|
15 |
demo = gr.Interface(chat , "text" , "text" )
|
16 |
demo.launch()
|