Nodes/ComfyUI-QwenVL/QwenVL (Advanced)
ComfyUI Node

QwenVL (Advanced)

The QwenVL node, but with every knob — for when defaults aren't cutting it

By aistudynow·Created 11 months ago·Updated 5 months ago· 15
QwenVL (Advanced)
  • image
  • video
  • text
â—„model_nameQwen3-VL-4B-Instructâ–º
â—„quantization8-bit (Balanced)â–º
â—„preset_promptDescribe this image in detail.â–º
â—„custom_promptâ–º
â—„max_tokens1024â–º
â—„temperature0.6â–º
â—„top_p0.90â–º
â—„num_beams1â–º
â—„repetition_penalty1.20â–º
â—„frame_count16â–º
â—„deviceautoâ–º
â—„use_torch_compilefalseâ–º
â—„keep_model_loadedtrueâ–º
â—„seed1â–º
â—„attention_modeautoâ–º

"QwenVL (Advanced)" is the same engine as the plain QwenVL node - same Qwen3-VL weights, same auto-download into models/LLM/Qwen-VL, same image-and-video-to-text job - with the training wheels off. It's the version you reach for when the default node's captions are too repetitive, too loose, or just not landing, or when you need it to run somewhere weird like CPU or Apple Silicon. Same pack, same author, same install; the whole difference is a dozen extra parameters on the widget.

What the extra knobs actually do

The plain node hardcodes sensible defaults and hides them. This one exposes them, and they split into two groups. First, sampling controls: temperature, top_p, repetition_penalty, and num_beams. Raise the temperature toward 0.8–1.0 when you want looser, more creative captions; drop it to 0.2–0.3 when you're captioning a training set and want the model to just say what's there. repetition_penalty (default 1.2, above 1) actively discourages Qwen from repeating itself - if your captions read like a scratched record, nudge it up. Flip num_beams above 1 and you switch from sampling to beam search, which gives more stable, more consistent answers at the cost of speed - and it silently disables temperature/top_p while it's on, so don't set both expecting to get both.

Second, runtime controls. device lets you force cpu or mps instead of trusting auto-detect - genuinely useful on an iMac or when you want to keep the GPU free for the sampler. use_torch_compile wraps the model in torch.compile after load; it's a real speedup on supported CUDA/Torch 2.1+ builds, but the first run pays a one-time compile cost that can look like a hang. frame_count (1–64, default 16) decides how many frames get sampled out of a video input before prompting - more frames means the model sees more of the clip and takes longer per run. The pack even ships a couple of intentionally niche presets, including an anatomy-observation prompt in the preset_prompt list, a small taste of where this family of nodes ends up.

The inputs that matter

  • temperature / top_p - set the creativity dial; 0.2–0.4 focused, 0.7+ creative.
  • num_beams - 1 for speed and variety, 2–4 for stable, repeatable-style answers.
  • frame_count - only matters for video; raise it when a 16-frame sample misses the action.
  • device - auto unless you know better; cpu/mps for machines without CUDA.
  • use_torch_compile - a cheap win after the warmup if your setup supports it.

Everything else matches the plain node: model_name (2B/4B/8B Instruct and Thinking, plus FP8), quantization (4-bit / 8-bit / FP16), preset_prompt, custom_prompt, max_tokens, keep_model_loaded, seed, and attention_mode (auto / sage / flash_attention_2 / sdpa). Optional image and video sockets feed it media; the output is one text string, and it's an output node so the answer appears in the UI.

Getting it

Identical to its little sibling - ComfyUI Manager (search "ComfyUI-QwenVL"), or:

cd ComfyUI/custom_nodes
git clone https://github.com/aistudynow/ComfyUI-QwenVL

then restart and find both nodes under the 🧠aistudynow/QwenVL menu. Same dependencies, same first-run weight download into models/LLM/Qwen-VL, same bitsandbytes requirement if you want the 4/8-bit options on CUDA.

Where people get burned

The most common "bug" is really a misread: because num_beams > 1 disables temperature and top_p, you can crank both, see zero effect, and assume the node is broken. It isn't - beam search just doesn't sample. Second, use_torch_compile on the first run looks like a freeze while it compiles; give it a minute before you kill it. Third, the 8B with FP16 and a long video prompt can OOM a 12 GB card - drop to the 4B or 8-bit, or lower frame_count. If your captions come out refusing content, that's the Instruct model's fine-tuning, not a settings problem - switch models or use an abliterated build.

This is the node I'd actually run for training-data captioning, because repetition_penalty and a low temperature are exactly the two levers that separate "a usable caption" from "three sentences of the same word." Start with the plain node to check the plumbing; switch to this one when you're building the real dataset.

Category🧠aistudynow/QwenVL

Inputs (17)

NameTypeDefaultDescription
model_nameCOMBOQwen3-VL-4B-Instruct18 options: Qwen3-VL-2B-Instruct, Qwen3-VL-2B-Thinking, Qwen3-VL-2B-Instruct-FP8, Qwen3-VL-2B-Thinking-FP8, Qwen3-VL-4B-Instruct, Qwen3-VL-4B-Thinking, +12
quantizationCOMBO8-bit (Balanced)3 options: 4-bit (VRAM-friendly), 8-bit (Balanced), None (FP16)
preset_promptCOMBODescribe this image in detail.13 options: Describe this image in detail., Describe this video in detail., Summarize the key events in this video., Generate 5 descriptive keywords for this content., Create a detailed text-to-image prompt from this image., Generate a detailed Stable Diffusion prompt that includes subject, background, lighting, and style., +7
custom_promptSTRING—
max_tokensINT102464–2048—
temperatureFLOAT0.60.1–1—
top_pFLOAT0.900–1—
num_beamsINT11–10—
repetition_penaltyFLOAT1.200–2—
frame_countINT161–64—
deviceCOMBOauto4 options: auto, cuda, cpu, mps
use_torch_compileBOOLEANfalse—
keep_model_loadedBOOLEANtrue—
seedINT11–18446744073709550000—
attention_modeCOMBOauto4 options: auto, sage, flash_attention_2, sdpa
imageoptIMAGE—
videooptIMAGE—

Outputs (1)

NameTypeDescription
textSTRING—