For the complete documentation index, see llms.txt. This page is also available as Markdown.

FLUX.2-klein-4B

Summary: FLUX.2-klein-4B is a compact, efficient text-to-image model developed by Black Forest Labs, designed to deliver high-quality image generation with a reduced 4B parameter footprint. Building on the FLUX architecture, the klein variant prioritises speed and resource efficiency while maintaining strong visual fidelity, making it well-suited for content creation, rapid prototyping, and applications where low-latency generation is essential.

Image quality

Speed

Input

Output

Intelligence activeIntelligence active

Speed active Speed active Speed active

Text active Image inactive Audio inactive

Model icon Model icon Audio inactive

Medium

High

Text

Image

Central parameters

Description: Compact 4B-parameter image generation model optimised for fast, high-quality visual output with low resource overhead.

Model identifier: black-forest-labs/FLUX.2-klein-4B

IONOS CLOUD AI Model Hub lifecycle and alternatives

IONOS CLOUD start date

End of Life

Alternative

Successor

June 16, 2026

N/A

N/A

Origin

Provider

Country

License

Flavor

Release

Technology

Input Length

Iterations

Quantization

Multilingual

Further details

256

4

8bit

Yes

Modalities

Text

Image

Audio

Input

Output

Not supported

Endpoints

Chat Completions

Embeddings

Image generation

Image editing

Not supported

Not supported

v1/images/generations

v1/images/edits

Features

Streaming

Reasoning

Tool calling

Image editing

Not supported

Not supported

Not supported

Supported

Usage example

Parameter

Values

n

An integer between 1 and 10 (inclusive). Limit: The total output cannot exceed 12,582,912 pixels per request (n × width × height). For example, if requesting 2048x2048 images, n can be at most 3.

output_format

jpg, jpeg, png, webp

size

A string in widthxheight format. Both dimensions must be between 64 and 2048 (inclusive) and are automatically rounded down to the nearest multiple of 16. The default for image generation is 1024x1024. For image editing, the default is the input image's aspect ratio and size, scaled down to fit these limits. Examples: 1024x1024, 1536x1024, 1024x1536, 2048x2048, 2048x1152.

Image editing requires a single input image with a minimum dimension of 64 pixels on each side and an aspect ratio no more extreme than 8 to 1 (or 1 to 8). Requests that do not meet these limits are rejected with a 400 Bad Request error detailing the exceeded limit.

Generate an Image

The following example demonstrates how to generate an image using FLUX.2-klein-4B.

API Endpoint: POST https://openai.inference.de-txl.ionos.com/v1/images/generations

Request:

Response:

Edit an image

The following example demonstrates how to edit an image using FLUX.2-klein-4B.

API Endpoint: POST https://openai.inference.de-txl.ionos.com/v1/images/edits

Request format: multipart/form-data

Request:

Response:

Rate limits

Rate limits ensure fair usage and reliable access to the AI Model Hub. The default rate limits apply to this model, separately from other models.

The default limit is 5 requests per second, with bursts of up to 10 requests. Each request counts once, however many images it generates.

Last updated

Was this helpful?