ai-tomoni commited on
Commit
6f02e40
·
verified ·
1 Parent(s): dc12302

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -4
app.py CHANGED
@@ -1,9 +1,16 @@
1
  import gradio as gr
2
 
 
 
 
 
3
  demo = gr.Interface(
4
- fn=lambda x: f"Hello {x}",
5
- inputs="text",
6
- outputs="text"
 
 
7
  )
8
 
9
- demo.launch()
 
 
1
  import gradio as gr
2
 
3
+ def simple_function(name):
4
+ return f"Hello {name}! This is Gradio 4.x"
5
+
6
+ # Gradio 4.x Interface
7
  demo = gr.Interface(
8
+ fn=simple_function,
9
+ inputs=gr.Textbox(label="Your Name", placeholder="Enter your name here"),
10
+ outputs=gr.Textbox(label="Response"),
11
+ title="Gradio 4.x Test",
12
+ description="Testing if Gradio 4.x works properly"
13
  )
14
 
15
+ if __name__ == "__main__":
16
+ demo.launch()