Update app.py
Browse files
app.py
CHANGED
|
@@ -1,6 +1,8 @@
|
|
| 1 |
import gradio as gr
|
| 2 |
import requests
|
| 3 |
|
|
|
|
|
|
|
| 4 |
|
| 5 |
def get_response(user_input):
|
| 6 |
# Make a POST request to the API
|
|
@@ -19,6 +21,7 @@ def get_response(user_input):
|
|
| 19 |
|
| 20 |
# Create the Gradio interface
|
| 21 |
iface = gr.Interface(
|
|
|
|
| 22 |
fn=get_response, # Function to call when user submits input
|
| 23 |
inputs="text", # Input type
|
| 24 |
outputs="text", # Output type
|
|
|
|
| 1 |
import gradio as gr
|
| 2 |
import requests
|
| 3 |
|
| 4 |
+
def show_live_status():
|
| 5 |
+
return "🟢 You can now use, Backend Server is live!"
|
| 6 |
|
| 7 |
def get_response(user_input):
|
| 8 |
# Make a POST request to the API
|
|
|
|
| 21 |
|
| 22 |
# Create the Gradio interface
|
| 23 |
iface = gr.Interface(
|
| 24 |
+
live_status = gr.Markdown(show_live_status())
|
| 25 |
fn=get_response, # Function to call when user submits input
|
| 26 |
inputs="text", # Input type
|
| 27 |
outputs="text", # Output type
|