chx_Ksampler_Kontext
A Flux Kontext sampler ā but the pack itself marks it deprecated
- context
- image
- mask
- redux_stack
- union_stack
- context
- image
- latent
Worth saying up front, because it's the single most important thing about this node: Apt_Preset itself files chx_Ksampler_Kontext under a "š«Deprecatedš«" category. That's not something inferred from GitHub issues or community chatter - it's the literal category path the node ships under in the current pack. If you found this page because a workflow JSON you downloaded references it, or because it showed up in an old tutorial, treat that as a sign the workflow predates a newer, non-deprecated way of doing the same job in this pack - check the current Apt_Preset README or node list for whatever replaced it before building anything new around this one.
What it was built to do
Despite the deprecation, the node is still functional and worth understanding if you're maintaining an existing workflow that uses it. It's a KSampler variant built for Flux Kontext-style editing - BFL's in-context image editor, which takes an image plus an instruction and edits it directly rather than generating from scratch. Apt_Preset's README describes its "General Control Kontext Stack" as handling multi-image reference, partitioned generation, redux transfer, and union ControlNet, and this sampler is the execution end of that stack: it's built to consume the redux (an IP-Adapter-style reference transfer for Flux) and union ControlNet modifier stacks the rest of that controller group produces.
Worth knowing about Kontext itself if you're editing this into a live workflow: it's a non-commercial-licensed model with a real content-restriction clause - any NSFW LoRA or fine-tune built on it is a documented license violation, and platforms have actually pulled NSFW Kontext derivatives under that clause. If your project needs an unrestricted instruction-editing model, Qwen-Image-Edit is the community's usual Apache-2.0 alternative.
The inputs and outputs that matter
context,seed- required, standard.prompt_weight(default 0.5) - how strongly the text instruction steers the edit relative to the image reference.steps(default -1) - the node's own tooltip states it plainly: -1 means no change, i.e. it leaves the step count coming throughcontextalone rather than overriding it. Set an explicit number only if you want this node to force a specific step count.denoise(default 1) andauto_adjust_image(boolean) - standard sampling strength, plus a toggle for automatic image-size/format adjustment.image_output- five choices here (None/Hide/Preview/Save/Hide/Save), one more option than most of the pack's other samplers.- Optional
image,mask,redux_stack(REDUX_STACK- Flux Redux-style reference conditioning),union_stack(UNION_STACK- Union ControlNet conditioning), andpos(multiline prompt text).
Outputs: context, image, and latent.
Installing it
Through ComfyUI Manager: search ComfyUI-Apt_Preset, install, restart. Manual:
cd ComfyUI/custom_nodes
git clone https://github.com/cardenluo/ComfyUI-Apt_Preset.git
then install.bat on Windows for dependencies, restart. You'll need a Flux Kontext checkpoint downloaded separately - the pack doesn't ship model weights - and, if you're using redux_stack/union_stack, the corresponding Redux and Union ControlNet model files.
Common issues
The node is missing from a newer install, or behaves unexpectedly. Given the deprecated status, this is the first thing to check if something feels off - confirm you're not fighting a node the pack's own maintainer has moved past. Check the pack's current README and changelog for whatever the Kontext controller stack now routes through instead.
redux_stack / union_stack inputs have nothing to connect. These expect Apt_Preset's own stack-builder nodes for Redux transfer and Union ControlNet respectively, not raw ComfyUI ControlNet or IP-Adapter outputs - they're pack-specific types, not general ComfyUI ones.
Output looks over-edited or under-edited relative to your instruction. That's prompt_weight and denoise together - raise prompt_weight if the instruction isn't taking effect strongly enough, adjust denoise if the edit is changing more (or less) of the image than intended.
Inputs (12)
| Name | Type | Default | Description |
|---|---|---|---|
| context | RUN_CONTEXT | ā | |
| seed | INT | 00ā18446744073709550000 | ā |
| prompt_weight | FLOAT | 0.500ā1 | ā |
| steps | INT | -1-1ā10000 | -1 means no change |
| denoise | FLOAT | 1.000ā1 | ā |
| auto_adjust_image | BOOLEAN | false | ā |
| image_output | COMBO | Preview | 5 options: None, Hide, Preview, Save, Hide/Save |
| imageopt | IMAGE | ā | |
| maskopt | MASK | ā | |
| redux_stackopt | REDUX_STACK | ā | |
| union_stackopt | UNION_STACK | ā | |
| posopt | STRING | ā |
Outputs (3)
| Name | Type | Description |
|---|---|---|
| context | RUN_CONTEXT | ā |
| image | IMAGE | ā |
| latent | LATENT | ā |