Download app.py from psina116/text: direct link, hf CLI and curl.
- Browser
- Download file 650 Bytes
-
https://huggingface.co/spaces/psina116/text/resolve/main/app.py
- Command line
-
hf download hf://spaces/psina116/text/app.py
-
curl -L -o app.py https://huggingface.co/spaces/psina116/text/resolve/main/app.py
650 Bytes
| import gradio as gr | |
| def greet(name): | |
| return f"Привет, {name}!" | |
| with gr.Blocks(title="Тест") as demo: | |
| gr.Markdown("# Тестовое приложение") | |
| gr.Markdown("Если вы видите это — Gradio работает.") | |
| name_input = gr.Textbox(label="Введите ваше имя") | |
| output_text = gr.Textbox(label="Результат") | |
| greet_btn = gr.Button("Сказать привет") | |
| greet_btn.click(fn=greet, inputs=name_input, outputs=output_text) | |
| if __name__ == "__main__": | |
| demo.launch( | |
| server_name="0.0.0.0", | |
| server_port=7860, | |
| ssr_mode=False | |
| ) |