Schrodingers commited on
Commit
bc16b18
1 Parent(s): 0c65406

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -8
app.py CHANGED
@@ -1,10 +1,7 @@
1
- pip install transformers
2
- from transformers import pipeline
3
 
4
- text_generator = pipeline("text-generation", model="gpt2")
 
5
 
6
- def generate_hello():
7
- return text_generator("Hello,")[0]['generated_text']
8
-
9
- if __name__ == "__main__":
10
- print(generate_hello())
 
1
+ import gradio as gr
 
2
 
3
+ def say_hello():
4
+ return "Hello World!"
5
 
6
+ interface = gr.Interface(fn=say_hello, inputs=None, outputs="text")
7
+ interface.launch()