sohamchitimali commited on
Commit
22be60d
·
1 Parent(s): 5f1ee2a

Fixed Broken Front End

Browse files
Files changed (1) hide show
  1. app.py +8 -4
app.py CHANGED
@@ -906,8 +906,12 @@ with gr.Blocks(title="🏆 Hackathon-Winning Query System", theme=gr.themes.Defa
906
  outputs=[single_output]
907
  )
908
 
909
- app = gr.mount_gradio_app(api_app, demo, path="/")
910
-
911
  if __name__ == "__main__":
912
- import uvicorn
913
- uvicorn.run(app, host="0.0.0.0", port=7860)
 
 
 
 
 
 
 
906
  outputs=[single_output]
907
  )
908
 
 
 
909
  if __name__ == "__main__":
910
+ # The launch function will start a server, automatically handling both
911
+ # the Gradio interface and your FastAPI endpoints on port 7860.
912
+ # It will also correctly serve all necessary static files.
913
+ demo.launch(
914
+ server_name="0.0.0.0",
915
+ server_port=7860,
916
+ show_error=True
917
+ )