a
    dQ                     @   s   d dl Z d dlZd dlmZ d dlZd dlmZ dZddddd	d
dddddddddg ddZedddZ	e 
dddkrejseje	efd  dS )    N)Dict)
wasm_utilsz*https://api.gradio.app/gradio-messaging/enzRunning on local URL:  {}z!Running on local URL:  {}://{}:{}zRunning on public URL: {}zr
Could not create share link. Please check your internet connection or our status page: https://status.gradio.app.a?  
Could not create share link. Missing file: {}. 

Please check your internet connection. This can happen if your antivirus software blocks the download of this file. You can install manually by following these steps: 

1. Download this file: {}
2. Rename the downloaded file to: {}
3. Move the file to this location: {}zDCannot display local interface on google colab, public link created.z9
To create a public link, set `share=True` in `launch()`.zOModel available publicly at: {} (may take up to a minute for link to be usable)z3Generating public link (may take a few seconds...):z
Thanks for being a Gradio user! If you have questions or feedback, please join our Discord server and chat with us: https://discord.gg/feTf9x3ZSBzColab notebook detected. This cell will run indefinitely so that you can see errors and logs. To turn off, set debug=False in launch().zUColab notebook detected. To show errors in colab notebook, set debug=True in launch()zENote: opening Chrome Inspector may crash demo inside Colab notebooks.z
This share link expires in 72 hours. For free permanent hosting and GPU upgrades, run `gradio deploy` from Terminal to deploy to Spaces (https://huggingface.co/spaces)zInterface loading below...)zYou can add authentication to your app with the `auth=` kwarg in the `launch()` command; for example: `gr.Interface(...).launch(auth=('username', 'password'))`zLet users specify why they flagged input with the `flagging_options=` kwarg; for example: `gr.Interface(..., flagging_options=['too slow', 'incorrect output', 'other'])`zYou can show or hide the button for flagging with the `allow_flagging=` kwarg; for example: gr.Interface(..., allow_flagging=False)a  The inputs and outputs flagged by the users are stored in the flagging directory, specified by the flagging_dir= kwarg. You can view this data through the interface by setting the examples= kwarg to the flagging directory; for example gr.Interface(..., examples='flagged')a  You can add a title and description to your interface using the `title=` and `description=` kwargs. The `article=` kwarg can be used to add a description under the interface; for example gr.Interface(..., title='My app', description='Lorem ipsum'). Try using Markdown!zpFor a classification or regression model, set `interpretation='default'` to see why the model made a prediction.)ZRUNNING_LOCALLYZRUNNING_LOCALLY_SEPARATEDZSHARE_LINK_DISPLAYZCOULD_NOT_GET_SHARE_LINKZ%COULD_NOT_GET_SHARE_LINK_MISSING_FILEZCOLAB_NO_LOCALZPUBLIC_SHARE_TRUEZMODEL_PUBLICLY_AVAILABLE_URLZGENERATING_PUBLIC_LINKZBETA_INVITEZCOLAB_DEBUG_TRUEZCOLAB_DEBUG_FALSEZCOLAB_WARNINGZSHARE_LINK_MESSAGEZINLINE_DISPLAY_BELOWZTIPS)enc                 C   s8   z t jtdd }| | W n ty2   Y n0 d S )N   )timeout)requestsgetMESSAGING_API_ENDPOINTjsonupdate	Exception)r   Zupdated_messaging r   W/var/www/html/stable-diffusion-webui/venv/lib/python3.9/site-packages/gradio/strings.pyget_updated_messaging'   s
    r   ZGRADIO_ANALYTICS_ENABLEDTrue)targetargs)os	threadingtypingr   r   Zgradior   r	   r   r   getenvZIS_WASMThreadstartr   r   r   r   <module>   s2   