Spaces:
Sleeping
Sleeping
RuslanKain
commited on
Commit
·
95e0040
1
Parent(s):
c13ad2a
test
Browse files- app.py +14 -0
- requirements.txt +1 -0
app.py
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
import gradio as gr
|
| 2 |
+
|
| 3 |
+
|
| 4 |
+
def greet(name):
|
| 5 |
+
return "Best of luck with the project " + name + "!"
|
| 6 |
+
|
| 7 |
+
|
| 8 |
+
with gr.Blocks() as demo:
|
| 9 |
+
name = gr.Textbox(label="Name")
|
| 10 |
+
output = gr.Textbox(label="Output Box")
|
| 11 |
+
greet_btn = gr.Button("Request Message")
|
| 12 |
+
greet_btn.click(fn=greet, inputs=name, outputs=output, api_name="greet")
|
| 13 |
+
|
| 14 |
+
demo.launch()
|
requirements.txt
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
gradio
|