Ticio commited on
Commit
8c599d6
·
verified ·
1 Parent(s): 73b4807

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -8
app.py CHANGED
@@ -20,11 +20,4 @@ with gr.Blocks(theme = theme) as demo:
20
  hidden_text = gr.Textbox(visible = False) # Added hidden text component
21
  gr.ChatInterface(fn=inference, chatbot=chatbot, type="messages", additional_inputs= hidden_text, additional_outputs= hidden_text, save_history= True).render()
22
 
23
- app = demo.app
24
- app.add_middleware(
25
- CORSMiddleware,
26
- allow_origins=["*"], # or restrict to your site(s)
27
- allow_methods=["GET", "POST", "OPTIONS"],
28
- allow_headers=["authorization", "content-type", "accept"],
29
- allow_credentials=False, # keep False if using "*"
30
- )
 
20
  hidden_text = gr.Textbox(visible = False) # Added hidden text component
21
  gr.ChatInterface(fn=inference, chatbot=chatbot, type="messages", additional_inputs= hidden_text, additional_outputs= hidden_text, save_history= True).render()
22
 
23
+ demo.launch()