Skip to content

BlackForest Labs / image model

Flux 2 Klein 4B

Explore Flux 2 Klein 4B, its capabilities, use cases and ComfyUI workflows for image generation on HexGrid Cloud.

Flux-22 workflowsExplore workflows ↓

Deploy Flux 2 Klein 4B with ComfyUI

Choose a workflow to explore its setup, inputs, downloads and generation examples.

About Flux 2 Klein 4B

FLUX.2 Klein 4B is Black Forest Labs' compact, open-weight image generation and editing model, deployable on HexGrid.cloud with dedicated GPU infrastructure, configurable inference workflows, custom checkpoints and LoRA support.

It supports three primary capabilities within a unified architecture: text-to-image generation, single-image editing and multi-reference image composition. The model accepts natural-language instructions and up to 4 reference images, enabling subject preservation, style transformations, product visualization and complex image editing.

FLUX.2 Klein 4B uses a 4-billion-parameter rectified-flow transformer with a Qwen3 4B text encoder. The distilled checkpoint generates images in approximately 4 inference steps, supports output resolutions up to 4 megapixels and runs on consumer-grade GPUs with approximately 13 GB of VRAM. A separate undistilled Base checkpoint provides greater flexibility for fine-tuning and custom model development.

What people use it for

High-quality text-to-image

Generate detailed images directly from natural-language prompts, including photorealistic scenes, cinematic compositions, illustrations, digital artwork and creative concepts. Control lighting, camera perspective, textures, materials and artistic style through descriptive instructions.

Image editing and transformation

Modify existing images using natural-language instructions. Replace backgrounds, change clothing, adjust lighting, transform artistic styles, modify objects or alter specific visual elements while preserving important characteristics of the original image.

Multi-reference image composition

Combine up to 4 reference images into a new composition while preserving selected subjects, products, clothing, environments or visual styles. Create group portraits, product arrangements and branded visuals using references identified within the prompt.

Product and advertising visuals

Create product photography, marketing campaigns, promotional graphics and branded images with controlled lighting, composition, materials and color palettes. Generate alternative product settings and visual concepts without traditional photoshoots.

Character and identity consistency

Use reference images to preserve recognizable facial features, clothing, character appearance and visual identity across generated compositions. Create consistent illustrations, portraits and recurring subjects for creative projects.

Real-time creative exploration

Generate and edit images rapidly using the distilled 4-step checkpoint. Explore multiple compositions, visual styles, lighting conditions and creative directions through iterative prompting and reproducible random seeds.

Custom styles and LoRA training

Fine-tune the undistilled Base checkpoint on specialized datasets to create reusable characters, artistic styles, branded aesthetics or product identities. Deploy compatible custom checkpoints and LoRAs through configurable inference workflows.

Strengths

  • Unified text-to-image generation and image editing within a single model architecture
  • 4-billion-parameter rectified-flow transformer optimized for fast image generation
  • Distilled checkpoint supporting high-quality generation and editing in approximately 4 inference steps
  • Image generation and editing at resolutions up to 4 megapixels
  • Up to 4 reference images for subject consistency, visual composition and reference-guided editing
  • Natural-language editing instructions for changing objects, backgrounds, clothing, lighting and artistic styles
  • Strong photorealistic image generation with detailed textures, realistic materials and cinematic lighting
  • Reference-guided preservation of recognizable characters, products and visual characteristics
  • Improved typography and text rendering compared with earlier FLUX generations
  • Support for exact hexadecimal color descriptions within text prompts
  • Qwen3 4B text encoder for understanding detailed natural-language instructions
  • Efficient rectified-flow architecture combining visual quality with low inference latency
  • Sub-second inference demonstrated on high-performance GPUs, with approximately 1.2-second generation reported on RTX 5090 hardware
  • Consumer-GPU compatibility with approximately 13 GB of VRAM in standard inference configurations
  • Support for square, landscape, portrait, widescreen and custom image dimensions
  • Configurable inference steps, image dimensions, batch sizes and random seeds
  • Separate undistilled 4B Base checkpoint for fine-tuning, LoRA training and greater sampling flexibility
  • Optional CPU offloading, reduced-precision inference and optimized attention implementations
  • Open-weight architecture supporting model customization, fine-tuning and private deployment
  • Apache 2.0 license permitting commercial use, modification and redistribution under its terms

Limitations

  • The distilled checkpoint is optimized for approximately 4 inference steps. Increasing the step count does not necessarily improve image quality and may produce results outside its intended sampling configuration.
  • Maximum output resolution is 4 megapixels. Higher-resolution images require external upscaling, tiling or additional processing.
  • Multi-reference generation supports a maximum of 4 reference images in the standard Klein workflow.
  • The compact 4B architecture prioritizes inference speed and efficiency over the maximum detail and editing fidelity available from larger image generation models.
  • The model generates static images only. Native video generation, animation, audio synthesis and synchronized audiovisual output are not supported.
  • Although text rendering is improved, long paragraphs, mathematical notation, small typography and dense layouts may contain spelling errors or visual distortions.
  • Complex image compositions involving multiple interacting subjects, precise spatial relationships or detailed object positioning can produce inconsistent results.
  • Reference-guided editing may introduce changes to nearby objects, backgrounds or subject details that were not explicitly requested.
  • Identity preservation is reference-guided rather than guaranteed. Repeated generation or complex transformations may alter facial details, clothing or product characteristics.
  • The distilled checkpoint uses guidance distillation and is not designed for conventional high-scale classifier-free guidance. Fine-grained guidance experiments are better suited to the undistilled Base checkpoint.
  • Prompt upsampling is not included natively. Automatic prompt enhancement requires a separate text model or preprocessing workflow.
  • Native grounding search and real-time external information retrieval are not supported by Klein 4B.
  • Native segmentation masks, ControlNet conditioning and specialized region-editing controls require compatible additional components or custom workflows.
  • The undistilled Base checkpoint requires substantially more denoising steps than the distilled variant, increasing inference time and computational cost.
  • GPU memory requirements increase with image resolution, reference count, batch size and inference precision.
  • Generated images may contain inaccuracies, biases or visual artifacts, particularly for highly constrained or unusually complex instructions.

Specifications

Generation, input and serving details.

ProviderBlackForest LabsFamilyFlux-2CategoryimageWorkflows2

Generation

Modes
Text-to-image, image editing, multi-reference image composition
Variants
FLUX.2 Klein 4B, FLUX.2 Klein 4B Base
Architecture
Rectified-flow Diffusion Transformer with unified generation and editing
Model parameters
4B image generation transformer parameters
Text encoder
Qwen3 4B
Resolution
Up to 4 megapixels
Default resolution
1024×1024 in the reference inference example; configurable
Maximum resolution
4 megapixels, approximately 2048×2048 for square output
Minimum resolution
64×64 pixels in the standard generation interface
Aspect ratios
Square, landscape, portrait, widescreen and custom aspect ratios
Image dimensions
Configurable width and height, generally using multiples of 16
Output formats
PNG; JPEG and WebP through compatible output processing
Reference images
Up to 4
Inference steps
Distilled: 4 recommended; Base: approximately 50 for full sampling
Guidance
Distilled checkpoint uses guidance distillation; Base supports conventional configurable guidance
Generation framework
Rectified-flow matching
Image decoder
FLUX.2 variational autoencoder
Batch generation
Configurable number of images per generation request
Model precision
BF16 reference inference; optimized precision configurations supported
Inference performance
Approximately 0.3 seconds on GB200 and 1.2 seconds on RTX 5090 in published Klein 4B benchmarks

Inputs and Controls

Text prompt
Required for text-to-image; used to describe desired modifications in image-editing workflows
Input image
Optional for generation; required for editing existing images
Reference images
Up to 4 images for composition, editing and subject conditioning
Multi-image conditioning
Supported for combining subjects, products, clothing, backgrounds and visual styles
Image editing
Natural-language instructions for changing existing image content
Local editing
Prompt-guided localized changes; explicit masks require compatible additional workflows
Character consistency
Reference-guided preservation of recognizable subjects and visual identity
Style control
Natural-language descriptions of artistic style, lighting, color grading, materials and composition
Color control
Supports hexadecimal color values in prompts for more precise color specification
Camera and composition
Prompt-based control over perspective, framing, depth of field, lighting and photographic style
Negative prompt
Not a standard control for the guidance-distilled 4-step checkpoint; additional control is available through compatible Base workflows
Inference steps
Configurable; 4 recommended for the distilled checkpoint
Guidance scale
Guidance-distilled inference; guidance_scale 1.0 in the reference Diffusers example
Random seed
Optional integer seed for reproducible generation
Image width
Configurable, subject to resolution and alignment limits
Image height
Configurable, subject to resolution and alignment limits
Number of images
Configurable batch generation
Prompt expansion
Not built into Klein; optional through external text models or custom preprocessing
Text rendering
Supports typography, short text, signage and branded image content
Reference indexing
Reference images can be identified by their order within natural-language prompts
Checkpoint selection
Distilled 4B for fast inference; 4B Base for full sampling and customization
LoRA training
Supported, with the undistilled Base checkpoint recommended for training
LoRA inference
Supported through compatible model adapters and inference workflows
CPU offloading
Supported to reduce GPU memory requirements
Quantization
Reduced-precision and quantized inference available through compatible runtimes
Content watermarking
Optional invisible watermarking and provenance metadata through compatible processing workflows

Serving

Provider
Black Forest Labs
API platform
HexGrid.cloud
Deployment
Private GPU deployment with configurable image generation and editing workflows
Generation workflows
Text-to-image, single-image editing and multi-reference image composition
Model checkpoints
FLUX.2-klein-4B and FLUX.2-klein-base-4B
Checkpoint formats
Safetensors
Output format
Static RGB images, typically PNG
Model availability
Open-weight checkpoints available for private commercial deployment
Model license
Apache 2.0
Commercial use
Permitted under Apache 2.0, subject to applicable license and trademark requirements
Fine-tuning
Custom model adaptation and LoRA fine-tuning supported
Model architecture
4B rectified-flow transformer with Qwen3 4B text conditioning and FLUX.2 autoencoder
Inference frameworks
Official FLUX.2 inference implementation, Diffusers, ComfyUI and compatible optimized runtimes
Infrastructure
Dedicated GPU infrastructure with private model execution and configurable inference pipelines
GPU requirements
Approximately 13 GB VRAM for standard inference; optimized benchmark configurations report approximately 8.4 GB
Memory optimization
CPU model offloading, reduced-precision inference and optimized attention implementations
Customization
Custom checkpoints, LoRAs, inference parameters, reference conditioning, prompt processing and image post-processing workflows
Performance
Distilled 4-step generation optimized for low latency; actual throughput depends on GPU hardware, resolution, reference count and batch size
Content safety
Optional content filtering, invisible watermarking and provenance metadata through compatible deployment workflows