File size: 619 Bytes
696f787
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
"""
MediGuard AI — Gradio Launcher wrapper.

Spawns the Gradio frontend UI on the correct designated port (7861), separating
the frontend runner from the production API layer entirely.
"""

import logging
import os
import sys

# Ensure project root is in path
from pathlib import Path

sys.path.insert(0, str(Path(__file__).parent))

from src.gradio_app import launch_gradio

logging.basicConfig(level=logging.INFO)

if __name__ == "__main__":
    port = int(os.environ.get("GRADIO_PORT", 7861))
    logging.info("Starting Gradio Web UI Launcher on port %d...", port)
    launch_gradio(share=False, server_port=port)