Spaces:
Running on Zero
Running on Zero
Download mcp_tools/get_task_list.py from BlueSkyXN/ImageGen-Studio: direct link, hf CLI and curl.
- Browser
- Download file 912 Bytes
-
https://huggingface.co/spaces/BlueSkyXN/ImageGen-Studio/resolve/main/mcp_tools/get_task_list.py
- Command line
-
hf download hf://spaces/BlueSkyXN/ImageGen-Studio/mcp_tools/get_task_list.py
-
curl -L -o get_task_list.py https://huggingface.co/spaces/BlueSkyXN/ImageGen-Studio/resolve/main/mcp_tools/get_task_list.py
912 Bytes
| """ | |
| MCP Tool: get_task_list | |
| Get a list of all supported image generation task types along with their required/optional parameter lists. | |
| """ | |
| from .common import _TASK_DEFINITIONS | |
| import copy | |
| def handle_get_task_list() -> list: | |
| """Get a list of all supported image generation task types along with their required/optional parameter lists.""" | |
| tasks = copy.deepcopy(_TASK_DEFINITIONS) | |
| for task in tasks: | |
| if "image" in task["required_inputs"] or "images" in task["required_inputs"]: | |
| task["image_input_alternatives"] = { | |
| "choose_exactly_one": ["image", "images", "numbered fields (img1 / 图1 / image1, ...)"], | |
| "description": "image is a single source; images is an ordered list. Numbered fields replace images. See get_model_features.image_workflows for task/run_mode constraints. Never send multiple forms together.", | |
| } | |
| return tasks | |