pdarleyjr commited on
Commit
4c4c9e8
·
1 Parent(s): 2248522

Update Gradio configuration for Hugging Face Spaces deployment

Browse files
Files changed (1) hide show
  1. app.py +7 -3
app.py CHANGED
@@ -48,10 +48,14 @@ demo = gr.Interface(
48
  allow_flagging="never"
49
  )
50
 
51
- # Launch the app
52
  if __name__ == "__main__":
53
- demo.queue()
54
  demo.launch(
55
  server_name="0.0.0.0",
56
- share=True
 
 
 
 
57
  )
 
48
  allow_flagging="never"
49
  )
50
 
51
+ # Launch the app with configuration for Hugging Face Spaces
52
  if __name__ == "__main__":
53
+ demo.queue(concurrency_count=3) # Allow multiple concurrent requests
54
  demo.launch(
55
  server_name="0.0.0.0",
56
+ server_port=7860,
57
+ enable_queue=True,
58
+ show_api=True, # Enable API documentation
59
+ share=False, # Not needed in Spaces
60
+ debug=True
61
  )