Spaces:
Sleeping
Sleeping
AngelaKkkkkkkkk
commited on
Commit
•
e5f7529
1
Parent(s):
0a6201c
Update app.py
Browse files
app.py
CHANGED
@@ -1,7 +1,14 @@
|
|
1 |
import gradio as gr
|
2 |
|
3 |
-
def
|
4 |
-
return "
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
|
6 |
-
demo = gr.Interface(fn=greet, inputs="text", outputs="text")
|
7 |
demo.launch()
|
|
|
1 |
import gradio as gr
|
2 |
|
3 |
+
def simple_search(query):
|
4 |
+
return f"You searched for: {query}"
|
5 |
+
|
6 |
+
# Gradio Interface
|
7 |
+
with gr.Blocks() as demo:
|
8 |
+
query = gr.Textbox(label="Search the web")
|
9 |
+
output = gr.Textbox(label="Results")
|
10 |
+
submit_btn = gr.Button("Submit")
|
11 |
+
|
12 |
+
submit_btn.click(simple_search, query, output)
|
13 |
|
|
|
14 |
demo.launch()
|