Spaces:
Running
Running
|
Download api/load.md from modelscope/modelscope-studio: direct link, hf CLI and curl.
- Browser
- Download file 1.32 kB
-
https://huggingface.co/spaces/modelscope/modelscope-studio/resolve/afb453a4cbbfd672cedb39efb522c31c69f8defd/api/load.md
- Command line
-
hf download hf://spaces/modelscope/modelscope-studio@afb453a4cbbfd672cedb39efb522c31c69f8defd/api/load.md
-
curl -L -o load.md https://huggingface.co/spaces/modelscope/modelscope-studio/resolve/afb453a4cbbfd672cedb39efb522c31c69f8defd/api/load.md
1.32 kB
| # load | |
| This feature is similar to [gr.load](https://www.gradio.app/docs/gradio/load). Allow users to Construct a demo from a [ModelScope Studio](https://modelscope.cn/studios) repo. | |
| ## How to Use | |
| ### Basic Usage | |
| ```python | |
| import modelscope_studio as mgr | |
| demo = mgr.load("modelscope/modelscope-studio") | |
| demo.launch() | |
| ``` | |
| ### With Access Token | |
| Use the access token to load a private ModelScope Studio repo. Find your sdk token here: https://modelscope.cn/my/myaccesstoken. | |
| ```python | |
| import modelscope_studio as mgr | |
| demo = mgr.load("modelscope/modelscope-studio", token="YOUR_ACCESS_TOKEN") | |
| demo.launch() | |
| ``` | |
| ## Initialization | |
| | Parameter | Type | Default Value | Description | | |
| | --------- | ---- | ------------- | ----------------------------------------------------------------------------------------------------------------------------------- | | |
| | name | str | None | required. the name of the ModelScope Studio repo (e.g. "modelscope/modelscope-studio"). | | |
| | token | str | None | optional access token for loading private ModelScope Studio repo. Find your sdk token here: https://modelscope.cn/my/myaccesstoken. | | |