Spaces:
Sleeping
Sleeping
Download app.py from othsueh/Hello_world: direct link, hf CLI and curl.
- Browser
- Download file 206 Bytes
-
https://huggingface.co/spaces/othsueh/Hello_world/resolve/main/app.py
- Command line
-
hf download hf://spaces/othsueh/Hello_world/app.py
-
curl -L -o app.py https://huggingface.co/spaces/othsueh/Hello_world/resolve/main/app.py
206 Bytes
| import gradio as gr | |
| from transformers import pipeline | |
| pipe = pipeline("sentiment-analysis") | |
| def porn(text): | |
| return pipe(text) | |
| demo = gr.Interface(fn=porn, inputs="text", outputs="json") | |
| demo.launch() |