Spaces:
Sleeping
Sleeping
Create app.py
Browse files
app.py
ADDED
@@ -0,0 +1,10 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
import gradio as gr
|
2 |
+
from gradio.context import LocalContext
|
3 |
+
|
4 |
+
def greet(name):
|
5 |
+
request = LocalContext.request.get()
|
6 |
+
print(f"{request=}")
|
7 |
+
return "Hello " + name + "!!"
|
8 |
+
|
9 |
+
iface = gr.Interface(fn=greet, inputs="text", outputs="text")
|
10 |
+
iface.launch()
|