Clip Input Switch JK๐
Swap CLIP encoders on the fly โ one checkbox between two text encoders
- clip_false
- clip_true
- clip_output
- boolean
CLIP isn't one thing - SDXL runs CLIP-L and CLIP-G, SD3/Flux run a triple of CLIP-L, CLIP-G and T5-XXL, and which encoder you feed a prompt through changes how it's interpreted. Clip Input Switch JK๐ lets you put two CLIP models in the graph and pick between them with a boolean, so A/B-ing encoders (or routing between a standard and a fine-tuned CLIP) is a toggle, not a rebuild.
In JakeUpgrade's ecosystem this node does real work: the changelog shows the pack juggling "clip l, clip g, t5xxl texture encode" logic and dual-clip switches for SDXL workflows. When a workflow can condition the same prompt through different encoder stacks, a clip switch is how you choose which one the sampler actually sees.
How it works
Same proven shape as every other JK switch:
if clip_true is not None and boolean_value:
return (clip_true, boolean_value)
else:
return (clip_false, boolean_value)
boolean_value-Truereturns the "true" CLIP,Falsereturns the "false" CLIP.clip_false- required, the CLIP used when the condition is False.clip_true- optional, the CLIP used when True. Unplugged, the node passesclip_falsethrough.
Outputs: clip_output (a CLIP, ready to feed CLIP Text Encode / CLIP Text Encode Encode) and boolean (the condition, echoed for further branching).
A practical note on wiring: because CLIP inputs are typically loaded by separate loaders, this node is usually sandwiched between two CLIP loaders upstream and a text-encoder node downstream. Both loaders run every execution regardless - the switch only decides which result flows on - so you're paying the load cost for both even when you only use one. That's the standard trade-off for any switch, and it only matters if your CLIPs are huge (T5-XXL, say); for SD15/SDXL-sized encoders it's a non-issue.
Where you'd use it
Prompt-path experimentation: one CLIP for the raw model, one for a character-consistency LoRA'd encoder, toggle between them. Or replicate the pack's own dual-clip pattern - the same latent branch, different encoder, and you want to compare conditioning without touching the graph. It also slots into API workflows where a caller can set the boolean and get a different encoder behavior without the workflow changing.
Install
Ships with ComfyUI-JakeUpgrade. ComfyUI Manager โ search ComfyUI-JakeUpgrade, or:
cd ComfyUI/custom_nodes
git clone https://github.com/jakechai/ComfyUI-JakeUpgrade
cd ComfyUI-JakeUpgrade && pip install -r requirements.txt
No models to fetch - the CLIPs themselves come from your checkpoint or dedicated CLIP loaders. Menu location: ๐ JK/๐ Switch. Pack-level gotchas apply as usual: if Manager warns about an IPAdapter Plus conflict, that's the replacement folder's noise, not a real conflict, and you can ignore it.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| boolean_value | BOOLEAN | false | Condition to select between inputs (True=clip_true, False=clip_false) |
| clip_false | CLIP | CLIP to return when condition is False | |
| clip_trueopt | CLIP | CLIP to return when condition is True (optional) |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| clip_output | CLIP | โ |
| boolean | BOOLEAN | โ |