Nodes/🗂️ Dict Tools/🔵CLIP-vision → Dict🗂️
ComfyUI Node

🔵CLIP-vision → Dict🗂️

The Vision Encoder, On the Bus

By Lex-DRL·Created 4 months ago·Updated 4 months ago· 1
🔵CLIP-vision → Dict🗂️
  • dict
  • value
  • dict
◄key—►
â—„cleanup_keytrueâ–ş

CLIP-vision is the other text-adjacent encoder: the one that reads images rather than prompts. It's the engine behind image-conditioned tricks like IP-Adapter and reference-image workflows, and it comes out of your loader as its own object. DictAddClipVision (spelled DictAddClipVision in the pack) lets you stash it in your dict under a named key so it rides the bus with everything else.

It's grouped under Add/Models like the other model-family nodes, and the CLIP_VISION value is a wired input from a CLIP Vision Loader. It's validated against the actual vision-model type before being stored - no accepting a regular CLIP here.

How it works

Standard Dict Tools mechanics: validate the value, store it under your key, return a new frozendict without mutating your input, and sort keys alphabetically on each update. Like other model objects, the vision encoder is stored by reference - the dict holds a handle, not a copy, so there's no real memory cost to bundling it.

Where this earns its keep: reference-image workflows where the same CLIP-vision encoder needs to reach an IP-Adapter application that's far from the loader in the graph. Bundle it, route it, extract it - the bus pattern in miniature.

The inputs that matter

  • key (STRING) - the name you'll fetch the encoder back by.
  • cleanup_key (BOOL, default on) - trims spaces/newlines from the key.
  • dict (DICT, optional) - an existing dict to extend, or empty to start one.
  • value (CLIP_VISION, optional) - the wired vision encoder from a CLIP Vision Loader.

Output is dict (DICT). Pair with DictExtractClipVision when you need it back.

Install

ComfyUI Manager: search Dict Tools, install, restart. Or:

cd ComfyUI/custom_nodes
git clone https://github.com/Lex-DRL/ComfyUI-DictTools

Restart after. Only dependency is frozendict, auto-installed by Manager.

Gotchas

Pack-wide: requires ComfyUI 0.18.0+ (newer node API). Failed to load → update ComfyUI.

The type strictness matters here more than usual, because CLIP and CLIP-vision are easy to mix up and they're not interchangeable. Feed a regular CLIP into this node and it fails the type check. And remember the snapshot rule: apply the vision encoder to an adapter, and the copy in the dict is still the pristine one - re-add if the bus needs the patched version.

Category🗂️ Dict Tools/Add/Models

Inputs (4)

NameTypeDefaultDescription
keySTRINGKey (name) of the item inserted into the dict.
cleanup_keyBOOLEANtrueAutomatically remove leading/trailing spaces and extra newlines from the key.
dictoptDICTAn (optional) Dictionary to work with.
valueoptCLIP_VISIONThe actual CLIP-vision-type item to add into the Dict.

Outputs (1)

NameTypeDescription
dictDICT—