Spaces:
Runtime error
Runtime error
File size: 353 Bytes
ddd3ad6 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
from fastapi import FastAPI
import gradio as gr
app = FastAPI()
@app.get("/predict")
def read_main():
return {"message": "This is your main app"}
io = gr.Interface(lambda x: "Hello, " + x + "!", "textbox", "textbox")
app = gr.mount_gradio_app(app, io, path="/")
# # Launch the app (which will be hosted on Hugging Face Spaces)
# io.launch()
|