JK Lil Context
A lightweight version of the rgthree Context pattern
- base_ctx
- base_model
- model
- base_clip
- clip
- vae
- positive
- negative
- latent
- images
- CONTEXT
- BASE_MODEL
- MODEL
- BASE_CLIP
- CLIP
- VAE
- POSITIVE
- NEGATIVE
- LATENT
- IMAGE
- SEED
Once a workflow grows past a screenful, the thing that actually makes it unreadable isn't the nodes - it's the wires. Model here, clip there, vae, positive, negative, latent, all crossing the canvas in parallel lines to reach the next node. The fix that's become standard across several packs is a "context" node: bundle all of that into one custom wire type, unpack it wherever you need it. rgthree-comfy popularized this pattern in ComfyUI with its Context and Context Big nodes; JK Lil Context is this pack's own version of the same idea, at the smaller end of the size spectrum - its sibling JKBigContext is the SDXL-scale version with a lot more fields bolted on.
How it works
Every input on this node is optional, and that's deliberate: you can feed it a base_ctx (an existing JK_CONTEXT from upstream) to merge into, plus whichever of model, clip, vae, positive, negative, latent, images, or seed you actually have at that point in your graph. Anything you don't wire in either passes through from base_ctx if you supplied one, or comes out empty.
It distinguishes base_model from model, and base_clip from clip - a small but useful detail: base_model/base_clip are meant to carry the unpatched checkpoint (no LoRAs applied), while model/clip carry the version with LoRAs applied, if any. That lets a downstream node choose which version it actually wants without you needing two separate context wires.
The inputs and outputs that matter
Everything listed above is optional on input, but the outputs are fixed: CONTEXT (the bundled JK_CONTEXT wire, plug this into any other JK node that accepts ctx), plus individual passthrough outputs for BASE_MODEL, MODEL, BASE_CLIP, CLIP, VAE, POSITIVE, NEGATIVE, LATENT, IMAGE, and SEED. So you get the single bundled wire and the unpacked individual values in one shot - tap whichever you need at any point downstream without adding a separate unpack node.
Typical use: build a JK Lil Context early in your graph right after loading your checkpoint and encoding your prompts, then hand its CONTEXT output to any of this pack's context-flavored nodes - EasyHRFix_Context, JKEasyDetailer_Context, JKEasyKSampler_Context - instead of re-wiring model/clip/vae/positive/negative into each one individually.
Installing it
It's part of the kostenickj/jk-comfyui-helpers pack - already on comfy.icu, or self-hosted with cd ComfyUI/custom_nodes && git clone https://github.com/kostenickj/jk-comfyui-helpers.git, then restart. No models, no extra Python dependencies for this particular node - it's pure graph plumbing. The pack overall is a small, low-visibility personal toolkit rather than a widely-discussed pack, so treat the README as your primary reference rather than expecting a big community thread to lean on.
Common issues
- A downstream context node errors because a field is missing. Since every input here is optional, it's easy to build a context that's missing something a later node actually needs (say,
latentif you forgot to wire it). Check what the receiving node actually requires and make sure it was populated somewhere upstream in the chain. - Confusing
modelandbase_model. If a downstream node behaves like your LoRAs aren't applied, you may have wiredbase_modelwheremodelwas expected, or vice versa - they're intentionally different things. - Expecting more fields than it has. This is the "lil" one on purpose - no sampler settings, no checkpoint name, no SDXL dual-text-encoder fields. If you need those, that's what JKBigContext is for.
Inputs (11)
| Name | Type | Default | Description |
|---|---|---|---|
| base_ctxopt | JK_CONTEXT | — | |
| base_modelopt | MODEL | the base model without any patching or LORA applied | |
| modelopt | MODEL | model with loras applied (if any) | |
| base_clipopt | CLIP | — | |
| clipopt | CLIP | — | |
| vaeopt | VAE | — | |
| positiveopt | CONDITIONING | — | |
| negativeopt | CONDITIONING | — | |
| latentopt | LATENT | — | |
| imagesopt | IMAGE | — | |
| seedopt | INT | — |
Outputs (11)
| Name | Type | Description |
|---|---|---|
| CONTEXT | JK_CONTEXT | — |
| BASE_MODEL | MODEL | — |
| MODEL | MODEL | — |
| BASE_CLIP | CLIP | — |
| CLIP | CLIP | — |
| VAE | VAE | — |
| POSITIVE | CONDITIONING | — |
| NEGATIVE | CONDITIONING | — |
| LATENT | LATENT | — |
| IMAGE | IMAGE | — |
| SEED | INT | — |