"allowed_paths" in Gradio

 I need to open a video file under a Gradio chatbot app via URL: <siteURL>/file={output_video_filename}. By default, Gradio not allows to open a file under the app folder, and so I added "allowed_paths" in "launch()" function. 

Sample code as below.

demo.launch(server_name="127.0.0.1", server_port=8000, allowed_paths=["output_video.mp4"])

Comments

Popular posts from this blog

Top JavaScript courses helping you develop SPFx webPart with ReactJS and AngularJS

Effective LLM Prompting skills

Enable the Microsoft Power BI report file type (.pbix) in SharePoint Search