Spaces:
Sleeping
Sleeping
Download app.py from Bernd-Ebenhoch/SQLite: direct link, hf CLI and curl.
- Browser
- Download file 396 Bytes
-
https://huggingface.co/spaces/Bernd-Ebenhoch/SQLite/resolve/main/app.py
- Command line
-
hf download hf://spaces/Bernd-Ebenhoch/SQLite/app.py
-
curl -L -o app.py https://huggingface.co/spaces/Bernd-Ebenhoch/SQLite/resolve/main/app.py
396 Bytes
| import gradio as gr | |
| gr.set_static_paths(['static/database.csv']) | |
| def greet(name): | |
| with open('static/database.csv','a') as file: | |
| file.write(name + "\n") | |
| with open('static/database.csv','r') as file: | |
| a = file.read() | |
| return "Hello " + a + "!!" | |
| demo = gr.Interface(fn=greet, inputs="text", outputs="text") | |
| demo.launch(allowed_paths=['static/database.csv']) |