GlobalBusinessAdvisors commited on
Commit
07f564a
1 Parent(s): 0b62847

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +11 -0
app.py CHANGED
@@ -1,4 +1,15 @@
1
  import uvicorn
 
 
 
 
 
2
 
3
  if __name__ == "__main__":
 
 
 
 
 
4
  uvicorn.run("app.main:app", host="0.0.0.0", port=8000, reload=True)
 
 
1
  import uvicorn
2
+ from threading import Thread
3
+ from app.gradio_ui import create_ui
4
+
5
+ def start_gradio_ui():
6
+ create_ui()
7
 
8
  if __name__ == "__main__":
9
+ # Start the Gradio UI in a separate thread
10
+ ui_thread = Thread(target=start_gradio_ui)
11
+ ui_thread.start()
12
+
13
+ # Run the FastAPI app
14
  uvicorn.run("app.main:app", host="0.0.0.0", port=8000, reload=True)
15
+