AI · Model-specific Setups
Flux.2 — Klein
Faster than SDXL, better than Flux.1 dev — in two variants, for two hardware classes.
The Swiss Army knife of diffusion models
My tests started with Flux.2 dev — the flagship of the series, 32 billion parameters, and by all accounts the current state of the art in AI image generation. It runs on the MacBook Pro with 64 GB Unified Memory. But with render times around 45 minutes per image, that's not a workflow — that's waiting. Flux.2 dev simply isn't made for local operation on normal hardware.
Klein 9B was the next step. Smaller, faster — but the encoder for 9B is 16.4 GB, and the model itself is nearly 10 GB. Model and encoder need to fit in memory simultaneously, along with Stability Matrix and a browser. On 16 GB, that's not practical.
Klein 4B was the surprise. And Klein as a model family is now my first recommendation for all workflows without ControlNet.
Flux.2 Klein 4B
What Klein is
Klein 4B and 9B are distilled models — trained to reach a result in 4 steps that would otherwise require 20–25 steps in a full Flux run. The speed advantage is not a simplification, but a different training logic.
Both variants use the same encoder type: Qwen 3, a large language model. No CLIP, no T5 split, no two-field interface. One text field, continuous prose. The prompt logic from 2.4.3 — Prompts for Flux transfers directly.
The key difference between 4B and 9B is not the diffusion model alone — it's the encoder. For 4B: 3.66 GB (Q6) or 8 GB (BF16). For 9B: 16.4 GB in BF16 — larger than the diffusion model itself. That makes 9B impractical on 16 GB, and not something I'd recommend for that hardware.
What it delivers
All measurements at 1024×1024, warm (models in memory):
| Model | MacBook Pro 64 GB | MacBook Air 16 GB |
| SDXL | 143 s | ~300 s |
| Flux.1 dev | 360 s | — (OOM) |
| Klein 4B | 36 s | 90 s |
| Klein 9B | 75–85 s | — (not practical) |
Klein 4B against Flux.1 dev: factor 10. Against SDXL on the Air: factor 3.3 — on a machine where Flux.1 dev doesn't run at all. Klein 9B takes roughly twice as long as 4B, but still runs significantly faster than Flux.1 dev.
What my tests also showed: both Klein variants deliver better results than Flux.1 dev — consistently, not as isolated cases. With decorative elements, light direction, material transitions. A model with a third of the parameters, running in a tenth of the time, and outperforming on quality — that was the real revelation of these tests.
Flux.1 dev has three times as many parameters as Klein 4B and takes ten times as long. The fact that Klein doesn't fall behind qualitatively — but comes out ahead — suggests that Flux.2 does something architecturally different, not just better scaling.
4B or 9B?
At first glance, results from both variants look nearly identical. In detail, 9B is more precise — more realistic reflections, finer object shapes, fewer deformations in small freestanding objects. In direct comparison, this only becomes visible when zooming in: chairs on a terrace show slightly deformed wheels in 4B at 300% view; in 9B they stay precise throughout.
Whether this difference is visible in the final output depends on the subject and the output size. For print formats where every detail counts, 9B can be the delivery model — 4B the fast search model before it. The same two-model logic as today's SDXL and Flux.1 dev, one generation further.
On 16 GB hardware, the decision is straightforward: Klein 4B. The 9B encoder alone takes up 16.4 GB — that's the entire available budget before the diffusion model even loads.
Klein 4B
Klein 9B
Setup
Klein 4B — Files and target folders
16 GB (MacBook Air) — 90 s warm:
| File | Size | Target folder |
| flux-2-klein-4b-Q8_0.gguf | 4.3 GB | diffusion_models/ |
| Qwen3-4B-UD-Q6_K_XL.gguf | 3.66 GB | text_encoders/ |
| flux2-vae.safetensors | ~335 MB | vae/ |
Total footprint ~8.3 GB. Stability Matrix and browser tabs can stay open — no cleanup needed.
64 GB (MacBook Pro) — 36 s warm:
Same configuration, optionally with qwen_3_4b.safetensors (BF16, 8 GB) instead of the quantised encoder. The diffusion model remains GGUF in either case — the custom node and Python package must be installed regardless of encoder choice.
Klein 9B — Files and target folders
Only two files change compared to 4B — VAE, steps, CFG and sampler stay identical. Recommended for 64 GB only.
| File | Size | Target folder |
| flux-2-klein-9b-Q8_0.gguf | 9.98 GB | diffusion_models/ |
| qwen_3_8b.safetensors | 16.4 GB | text_encoders/ |
| flux2-vae.safetensors | ~335 MB | vae/ |
Important: the 9B encoder is a safetensors file, not GGUF — use the regular CLIPLoader, not the GGUF loader. The same repository also contains fp8mixed and fp4mixed variants — both unusable on Apple Silicon.
Sources
| File | Repository |
| flux-2-klein-4b-Q8_0.gguf | unsloth/FLUX.2-klein-4B-GGUF |
| Qwen3-4B-UD-Q6_K_XL.gguf | unsloth/Qwen3-4B-GGUF |
| qwen_3_4b.safetensors (BF16) | Comfy-Org/vae-text-encorder-for-flux-klein-4b → split_files/text_encoders/ |
| flux-2-klein-9b-Q8_0.gguf | unsloth/FLUX.2-klein-9B-GGUF |
| qwen_3_8b.safetensors | Comfy-Org/vae-text-encorder-for-flux-klein-9b → not fp8mixed or fp4mixed! |
| flux2-vae.safetensors | Comfy-Org/flux2-dev → split_files/vae/ |
Nodes in ComfyUI
Klein requires different nodes than Flux.1 dev. The loader depends on the encoder's file format — not the model:
| Task | Node |
| Load diffusion model (4B + 9B) | Unet Loader (GGUF) — not Load Diffusion Model |
| Encoder 4B GGUF | CLIPLoader (GGUF), type = flux2 |
| Encoder 4B BF16 / Encoder 9B | CLIPLoader, type = flux2 |
| Enter text | CLIP Text Encode — not CLIPTextEncodeFlux |
No two-field interface, no clip_l/t5xxl split. One text field.
MPS rule
Any file with fp8 or fp4 in the filename is unusable on Apple Silicon — MPS cannot compute these formats. The official ComfyUI documentation links exactly these files as the default. Use BF16 or GGUF instead.
Required step: setting up GGUF support
The diffusion model is in GGUF format — a quantisation format that originally comes from the LLM world. ComfyUI cannot load GGUF files natively; it requires a custom node (ComfyUI-GGUF by city96) and a Python package.
Step 1 — Install Python package
Stability Matrix → ComfyUI package → three-dot menu → Python Packages → + → search for gguf → install. This step must come first.
Step 2 — Install custom node
ComfyUI → Manager → Custom Nodes Manager → search for GGUF → install ComfyUI-GGUF by city96. Pay attention to the author — there are imitations.
Then stop and restart ComfyUI. Verify: right-click on the canvas → Add Node → bootleg → Unet Loader (GGUF) — if the node appears, everything is installed correctly.
The most common failure: the custom node installs without an error message but never shows up anywhere. The cause is almost always the missing Python package — which is why step 1 comes first. Occurred on both test machines — not an edge case.
Parameters
These apply to both variants — 4B and 9B. CFG 1.0 means: no working negative prompt. Rephrase unwanted elements positively — same as Flux.1 dev, but even more so.
Steps: 4 (Flux2Scheduler) CFG: 1.0 (CFG Guider) Sampler: euler Scheduler: simple
Licence
Klein 4B is the only model in the Flux family under Apache 2.0 — no usage restrictions, no open legal questions for commercial work. Klein 9B and Flux.2 dev run under Black Forest Labs' non-commercial licence. More on this in 2.1.4 — Understanding Licence Models.
And RAY-L?
Klein has convinced me enough that its integration into RAY-L is decided — as soon as ControlNet Canny becomes available. That's the only open gap: no ComfyUI-compatible ControlNet Canny exists for Klein currently, neither for 4B nor 9B.
What does exist doesn't fit: a diffusers-based ControlNet approach for 9B has no ComfyUI node — RAY-L speaks ComfyUI. Another approach requires a reference image and fuses its identity with the Canny contour, which is not the same as "geometry fixed, material free". And Flux.2 dev does have ControlNet Canny — but at 45 minutes per render, that's not an argument.
For RAY-L v1.0, Flux.1 dev stays set. For all workflows without ControlNet — refinements, img2img, free generation — Klein is now the first choice. When ControlNet Canny arrives for Klein, the integration follows.
Flux.2 Klein 9B