ComfyUI Node

SID LLM Local

A free vision LLM inside ComfyUI — no API key, no cloud bill

By slahiri·Created 10 months ago·Updated 8 months ago· 59
SID LLM Local
    • LLM_MODEL
    modelQwen3-VL-2B-Instruct
    quantizationAuto (Detect Best)
    deviceauto
    temperature0.3
    max_tokens_presetMedium (1024)
    custom_max_tokens1024
    keep_model_loadedtrue
    attention_modeauto
    repetition_penalty1.2
    top_p0.90
    use_torch_compilefalse

    Every cloud provider on the toolkit's other node wants a key and a credit card. This one wants neither. SID_LLM_Local is the pack's free option: a vision LLM that runs inside your ComfyUI process, with the weights pulled from Hugging Face on first use. The node description says "No GPU" - meaning it'll happily run on CPU if that's all you've got (slow, but it runs) - and no API. For a node nobody's searching for yet, it's quietly the one most people should start with.

    Which model? The dropdown lists Qwen3-VL (2B / 4B / 8B, plus Thinking reasoning variants), Florence-2, Moondream2, SmolVLM, and Phi-3.5-Vision. The labels carry the spec sheet: max tokens and VRAM at 4-bit. The 8B sits at ~4.5GB quantized but wants 12GB at full fp16, which is why the pack defaults to the 2B. Community consensus from the release thread: 4B is the sweet spot, "you might even get away with the 2B."

    How it works. It loads the model with Hugging Face transformers in-process - no Ollama process to babysit - auto-detects CUDA vs CPU, and quantizes to fit your card. quantization handles that (Auto / 4-bit / FP16). keep_model_loaded keeps it warm in VRAM between runs, which turns repeat inference from a multi-second load into instant. The Thinking variants set the supports_reasoning flag that flips the prompt generator into agentic mode; the plain variants stay single-shot, which the pack's own docs recommend for local models anyway.

    Inputs. model, quantization, device, temperature, max_tokens_preset, custom_max_tokens, keep_model_loaded, attention_mode, repetition_penalty, top_p, use_torch_compile. You realistically touch three:

    • model - the vision model. Pick the smallest that gives you usable prompts; 4B Qwen3-VL is the "good enough" default for most people.
    • quantization - Auto is fine; drop to 4-bit only if you're VRAM-starved.
    • keep_model_loaded - leave it on unless you need the VRAM back between runs.

    The rest are pass-through sampling knobs: repetition_penalty (1.2 default) is worth knowing if output starts looping, and attention_mode can go flash_attention_2 on an Ampere+ card for a speed bump. use_torch_compile speeds inference but makes the first run slower and needs CUDA + Torch 2.1+.

    Output. One LLM_MODEL, wired straight into the llm_model input of SID_ZImagePromptGenerator. Same contract as the API node, so swapping between the two is a two-second edit.

    Install. ComfyUI Manager (search "AI Photography Toolkit"), or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/slahiri/ComfyUI-AI-Photography-Toolkit.git
    

    Restart ComfyUI; the pack installs transformers, accelerate, and friends automatically. 4-bit quantization needs bitsandbytes and is CUDA-only.

    Gotchas. The first run downloads multiple GB of weights, so the first generation looks hung - it isn't. If you're on 8GB of VRAM, don't reach for the 8B at fp16; the 4-bit 4B will make you happier. And if local output comes out rambly or structured-JSON-shaped, you picked a Thinking variant - switch to a plain one and let it run single-shot, which is where small local models shine.

    CategorySID Photography Toolkit/LLM Providers

    Inputs (11)

    NameTypeDefaultDescription
    modelCOMBOQwen3-VL-2B-InstructSelect model: Name | Max Tokens | VRAM (4-bit)
    quantizationCOMBOAuto (Detect Best)Auto: detects best based on VRAM, 4-bit: lowest VRAM, FP16: best quality
    deviceCOMBOautoDevice to run on (auto recommended)
    temperatureFLOAT0.30–1Creativity (0=deterministic, 0.3=balanced, 1=creative)
    max_tokens_presetCOMBOMedium (1024)Output length: Low=512, Medium=1024, High=2048, Very High=Model Max
    custom_max_tokensINT1024128–4096Custom max tokens (only used when preset is 'Custom')
    keep_model_loadedBOOLEANtrueKeep model in VRAM between runs (faster repeat inference)
    attention_modeCOMBOautoAttention implementation: auto (recommended), flash_attention_2 (Ampere+), sdpa, eager
    repetition_penaltyFLOAT1.20.8–2Penalize repeated tokens (1.0=off, 1.2=recommended, 2.0=strong)
    top_pFLOAT0.900.1–1Nucleus sampling (0.9=recommended, lower=more focused)
    use_torch_compileBOOLEANfalseEnable torch.compile for faster inference (CUDA + Torch 2.1+ only, first run slower)

    Outputs (1)

    NameTypeDescription
    LLM_MODELLLM_MODELLLM configuration to connect to prompt generator