Nodes/ComfyUI-QING/Kimi视觉丨API
ComfyUI Node

Kimi视觉丨API

Ask an image questions — Kimi reads it for you

By sheengoa·Created about a year ago·Updated 19 days ago· 16
Kimi视觉丨API
  • image
  • generated_text
  • conversation_info
  • total_tokens
text_input请描述这张图片的内容。
platform月之暗面
modelkimi-latest-32k
max_tokens4096
history8
temperature0.8
top_p0.95
image_qualityauto
clear_historyfalse

Caption an image, describe a scene, answer "what's wrong with this face?" - and get the answer back as text your workflow can use. KimiVisionAPI is the vision half of the QING pack's Kimi integration: wire in an image and a question, and Moonshot's kimi-latest vision models look at the picture and talk back. It's the VLM-in-the-graph move from the LLM-in-comfyui playbook, done as a drop-in node.

It's from ComfyUI-QING (display name "Kimi视觉丨API"). Note that this is a paid API call, not a local model - no weights, no VRAM, but also no free lunch.

How it works

The node takes your IMAGE tensor, encodes it, and sends it to Moonshot's vision endpoint along with your text_input question. Under the hood it's the openai package talking to an OpenAI-compatible endpoint - same machinery as the pack's KimiLanguageAPI, but with an image attached. It also keeps a multi-turn conversation (default history of 8 rounds), so you can ask follow-ups about the same image across runs.

The inputs that matter:

  • image - the tensor it's looking at. Required.
  • text_input - your question or instruction. Default: "请描述这张图片的内容。" (describe the content of this image).
  • model - three context-window options: kimi-latest-8k, kimi-latest-32k (default), kimi-latest-128k. All three map to the same underlying kimi-latest API model; you're really choosing how much conversation context you want to keep around the image.
  • image_quality - auto / low / high. This controls how the image is sent upstream; low is faster and cheaper for rough analysis, high when fine detail matters (reading text in the image, small objects).
  • max_tokens, temperature, top_p, clear_history - the usual LLM dials.

The platform dropdown has a single choice (月之暗面 / Moonshot) - the vision models only ship through Moonshot's own endpoint, unlike the language node which spans four providers. That's not a bug, it's just where the models live.

Outputs: generated_text (STRING), conversation_info (STRING), and total_tokens (INT).

Where it fits

The two jobs this is genuinely good at: auto-captioning - describe a generated image and feed the description back into your prompt pipeline or a dataset - and image QA in a loop - a "did it come out right?" check that lets a workflow branch on the answer. The multi-turn history is the differentiator over a one-shot captioner: you can drill into an image ("now focus on the hands") without resending the picture and losing context.

Honest caveat: for bulk dataset captioning, a local VLM (JoyCaption, Florence-2) is free per call and uncensored; an API is better when you want frontier-quality description and don't mind the per-call cost (llm-in-comfyui makes this call for you). And remember the API is Moonshot's - it filters what it filters, and your image leaves the machine.

Installing

Part of ComfyUI-QING. ComfyUI Manager: search "ComfyUI-QING". Or:

cd ComfyUI/custom_nodes
git clone https://github.com/GAO-SHIQING/ComfyUI-QING
cd ComfyUI-QING
python install_dependencies.py   # or: pip install -r requirements.txt

Restart ComfyUI. Needs the openai package (in requirements.txt) and an internet connection. Then configure your Moonshot key in Settings → QING → API configuration (or the MOONSHOT_API_KEY env var) - the key is stored locally and auto-injected at runtime.

Gotchas

The big one: no key, no call. If the node errors immediately, the key is almost always the cause - check Settings → QING first, then the console. image_quality is your cost lever: leave it auto until you specifically need high, because high-quality upstream encoding costs more tokens and adds latency. And be precise with text_input - vision models take instructions literally, so "describe the content" and "count the people and their positions" are different quality tiers of answer. Finally, remember this is a paid metered call inside a graph that may run hundreds of times - wire total_tokens into a LogPrinter if you're batching, so the spend doesn't surprise you.

CategoryQING/API

Inputs (10)

NameTypeDefaultDescription
imageIMAGE输入要分析的图像
text_inputSTRING请描述这张图片的内容。输入要发送给Kimi视觉模型的文本问题,Kimi擅长图像理解、场景分析和视觉问答
platformCOMBO月之暗面选择API服务提供商
modelCOMBOkimi-latest-32k选择要使用的Kimi视觉模型 📋 模型特点: 🔸 kimi-latest-8k:8K上下文版本,适合简单图像分析 🔸 kimi-latest-32k:32K上下文版本,适合复杂图像理解 🔸 kimi-latest-128k:128K上下文版本,支持超长对话和详细分析 💡 Kimi视觉模型在图像理解、文字识别、场景分析方面表现优异
max_tokensINT40961–32768模型生成文本时最多能使用的token数量
historyINT81–25保持的历史对话轮数
temperatureoptFLOAT0.80–2控制生成文本的随机性
top_poptFLOAT0.950–1控制生成文本的多样性
image_qualityoptCOMBOauto图像处理质量:auto(自动选择), low(低质量,速度快), high(高质量,精度高)
clear_historyoptBOOLEANfalse是否清除历史对话记录

Outputs (3)

NameTypeDescription
generated_textSTRING
conversation_infoSTRING
total_tokensINT