CLIP Positive-Negative XL w/Text (WLSH)
CLIP Positive-Negative XL w/Text (WLSH)
- clip
- positive
- negative
- positive_text
- negative_text
SDXL's proper conditioning setup is more involved than SD 1.5's - it wants separate "global" and "local" text for both positive and negative, plus a handful of size and crop values that feed the model's micro-conditioning, on top of the dual text encoders SDXL runs under the hood. Doing that with stock nodes means wiring up ComfyUI's CLIPTextEncodeSDXL twice (once for positive, once for negative) and keeping all those numeric fields in sync by hand. This node folds the whole thing into one box.
The eleven inputs, grouped by what they actually do. clip is your CLIP model from the checkpoint loader. positive_g / positive_l and negative_g / negative_l are the four text fields - _g is the "global" prompt SDXL's larger text encoder sees, _l is the "local" prompt for the smaller one; in practice most people put the same (or very similar) text in both, which is exactly the simplification the pack's README calls out for its non-XL "unified" variant, but here you get the full separate control if you want it. width / height (default 1024 each) describe the image's actual generation size. crop_w / crop_h (default 0) are SDXL's crop-conditioning values - they tell the model how much of the training image was cropped from the top-left when this was trained, and leaving them at 0 (no crop) is correct for the overwhelming majority of workflows; nonzero values are a specialized technique, not something to fiddle with by default. target_width / target_height (default 1024) represent the intended final resolution for aesthetic-score conditioning - usually just matched to width/height, though SDXL's design allows them to differ if you're generating at one size with a different final target in mind.
Outputs, four of them: positive and negative are the CONDITIONING tensors your sampler actually consumes. positive_text and negative_text pass the raw strings back out - useful for feeding WLSH's own save nodes so your saved image metadata carries the actual prompt without you retyping it a second time.
Installing it: ComfyUI Manager, search "wlsh_nodes"; or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/wallish77/wlsh_nodes
Restart ComfyUI. No models or extra dependencies - this wraps CLIP text encoding, nothing more to install.
Where people get tripped up. Leaving crop_w/crop_h at nonzero values without meaning to is the classic mistake - it shifts what the model thinks the "visible" region of the image should look like relative to training, and can produce subtly (or not-so-subtly) off framing for no obvious reason. If your output looks strangely cropped or off-center on an otherwise sane prompt, check those two fields are actually 0 before looking anywhere else. And if you're only running SD 1.5 or a non-XL checkpoint, this node isn't for you at all - it'll happily accept your inputs but the extra SDXL-specific conditioning fields (crop and target size) have no meaning outside the SDXL architecture; use the plain CLIP Positive-Negative w/Text (WLSH) node instead.
Inputs (11)
| Name | Type | Default | Description |
|---|---|---|---|
| width | INT | 10240–8192 | — |
| height | INT | 10240–8192 | — |
| crop_w | INT | 00–8192 | — |
| crop_h | INT | 00–8192 | — |
| target_width | INT | 10240–8192 | — |
| target_height | INT | 10240–8192 | — |
| positive_g | STRING | POS_G | — |
| positive_l | STRING | POS_L | — |
| negative_g | STRING | NEG_G | — |
| negative_l | STRING | NEG_L | — |
| clip | CLIP | — |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| positive | CONDITIONING | — |
| negative | CONDITIONING | — |
| positive_text | STRING | — |
| negative_text | STRING | — |