File size: 356 Bytes
0a37207
 
 
b7bda5c
0a37207
b7bda5c
0a37207
 
b7bda5c
0a37207
 
b7bda5c
 
1
2
3
4
5
6
7
8
9
10
11
12
13
import gradio as gr
from app.main import app as fastapi_app

# Create a dummy UI so Gradio has something to launch
demo = gr.Interface(
    fn=lambda x: "ContextQuery API is running",
    inputs="text",
    outputs="text",
    title="ContextQuery AI Backend"
)

# Mount the FastAPI app directly onto the Gradio app's server
demo.app.mount("/", fastapi_app)