Update app.py
Browse files
app.py
CHANGED
@@ -219,10 +219,10 @@ def read_root():
|
|
219 |
|
220 |
# Gradio Interface for displaying the stored data
|
221 |
def show_data():
|
222 |
-
return lists
|
223 |
|
224 |
# Gradio app interface
|
225 |
-
gr_interface = gr.Interface(fn=show_data,
|
226 |
|
227 |
# Add the Gradio app to FastAPI
|
228 |
app = gr.mount_gradio_app(app, gr_interface, path="/gradio")
|
|
|
219 |
|
220 |
# Gradio Interface for displaying the stored data
|
221 |
def show_data():
|
222 |
+
return json.dumps(lists, indent=4) # Return the data as formatted JSON
|
223 |
|
224 |
# Gradio app interface
|
225 |
+
gr_interface = gr.Interface(fn=show_data, inputs=[], outputs="text")
|
226 |
|
227 |
# Add the Gradio app to FastAPI
|
228 |
app = gr.mount_gradio_app(app, gr_interface, path="/gradio")
|