ModelScope 图像描述生成
A caption machine for datasets, built on Qwen3-VL
- image
- description
This is the pack's purpose-built caption generator: feed it an image, get back a natural-language description as a STRING, ready to drop into a prompt or a dataset CSV. It showed up in late 2025 riding Qwen3-VL, and it's the node you'd reach for when you're building a training dataset and want captions that sound like descriptions a human would write - not the tag soup a local tagger produces.
Choosing this over the Vision node
It's the sibling of the pack's Vision node, and the overlap is real, so here's the honest way to choose. Vision uses a broader model menu (StepFun step3, Qwen2.5-VL, QVQ-72B) for open-ended image analysis. This node is narrower and more dataset-shaped: it defaults to Qwen/Qwen3-VL-8B-Instruct (with a 235B option), and it adds three things Vision doesn't have - a second prompt slot, a seed, and the ability to run with no image at all.
The inputs that matter
The inputs that matter:
- api_tokens (required) - your ModelScope token(s). Comma/newline-separated multiple tokens are supported and it'll fall through them on rate limits; tokens auto-save to
modelscope_config.jsonafter the first run. - image (optional) - here's the neat trick: leave it disconnected and the node quietly substitutes a blank 64×64 white image, which turns Qwen3-VL into a plain LLM for pure text generation. The author documented this intentionally; it's a free text node in disguise.
- prompt1 and prompt2 - two caption prompts that get auto-merged with a comma. This is a small but real workflow win: keep a fixed template in prompt1 ("describe the subject, background, colors, style") and vary prompt2 per batch, or use the second slot for a follow-up instruction.
- model - the Qwen3-VL-8B/235B pair.
- max_tokens (100–4000, default 1000), temperature (0.1–2.0, default 0.7), and seed (-1 random). The seed is new (added Dec 2025) and does actually vary the output between runs - but, same caveat as the Text node, it seeds the local RNG rather than controlling the API, so treat it as "give me a different caption" rather than a reproducibility guarantee.
Output is description, a STRING that wires into a prompt node, a Save Text node, or your dataset tooling. If the API errors, the output comes back as a "图像描述生成失败: …" string and the real trace lands in the console - the pack-wide failure mode, worth remembering when you see a caption that looks like a stack trace.
Installing it
Installation is the shared pack dance: ComfyUI Manager, searching "ComfyUI ModelScope API Node", or
cd ComfyUI/custom_nodes
git clone https://github.com/hujuying/ComfyUI-ModelScope-API
then restart. The node requires the openai package (it's a chat-completions call to api-inference.modelscope.cn/v1 under the hood); if it's missing you'll get a placeholder telling you to install it.
Bottom line
Bottom line: if you're building caption data for LoRA training and want natural-language captions on a tight budget, this is a solid pick - the 8B Qwen3-VL model is cheap to call and the two-prompt setup makes batch captioning less fiddly. If you already run a local captioner and don't need cloud calls in your training loop, it's a convenience you can skip.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| api_tokens | STRING | — | |
| imageopt | IMAGE | — | |
| prompt1opt | STRING | 详细描述这张图片的内容,包括主体、背景、颜色、风格等信息 | — |
| prompt2opt | STRING | — | |
| modelopt | COMBO | Qwen/Qwen3-VL-8B-Instruct | 2 options: Qwen/Qwen3-VL-8B-Instruct, Qwen/Qwen3-VL-235B-A22B-Instruct |
| max_tokensopt | INT | 1000100–4000 | — |
| temperatureopt | FLOAT | 0.70.1–2 | — |
| seedopt | INT | -1-1–2147483647 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| description | STRING | — |