ModelsinclusionAIMing-Image-0.1-Design-Layer
providerinclusionAI /

Ming-Image-0.1-Design-Layer

6 DZD× (width / 1024) × (height / 1024) × (iters / 12)

Ming-Image-0.1-Design-Layer runs image generation backwards. Every other image model in this catalogue turns a description into a picture; this one takes a finished, flattened design and pulls it apart into separate transparent RGBA layers — the background, the shapes, the text, each on its own canvas and each independently editable. You supply the image and a layer plan saying how many layers you want, and it returns them alongside a recomposed version you can check the result against. Six billion parameters, twelve sampling steps, MIT licensed.

PublicImageRGBALayersDesignMIT
Ming-Image-0.1-Design-Layer
Capabilities
Vision
ArchitectureMultimodal Diffusion Transformer
Context WindowImage

Ming-Image-0.1-Design-Layer

Generation, run backwards. A flattened design goes in; separate editable layers come out.


The Direction Is the Point

Every other image model takes a description and produces a picture.

This one takes a picture and produces its parts.

Give it a flattened design — a poster, a card, a UI mock, an infographic — and a layer plan, and it returns each element on its own transparent canvas. Background separate from shapes. Shapes separate from text. Each one an RGBA image you can move, recolour, or delete without touching the rest.

What that recovers. A design exported to PNG has lost its structure. The layers that made it are gone; what remains is a grid of pixels where a logo and the gradient behind it are the same thing.

This model reconstructs the structure. Not perfectly, and not as the original file — but as editable layers where there were none.


Ming-Image-0.1-Design-Layer decomposition example

The input design, six decomposed layers, and the recomposed result.


⚠️ The Output Is N + 1

The integration detail that will surprise you, and it is documented.

The model returns the requested layers plus one leading composite, full-canvas image.

Ask for six layers and seven images come back. The composite first, then the six.

Why the composite is there. It is the model's own recomposition — the layers flattened back together. Comparing it against your input is how you check whether the decomposition preserved the design or lost something.

Which makes it a verification artefact rather than a spare output. A composite that differs visibly from the input tells you the decomposition failed before you open a single layer.

And it means index zero is not layer one. Code that treats the first returned image as the first layer is off by one on every element.


The Layer Count Comes From the Prompt

Not a parameter. A sentence.

The model parses the count from your text, in either of two documented forms:

CODE
Decompose this image into 6 layers
CODE
Number of layers: 6

And a layer plan is more than a count. A detailed specification describing what each layer should contain gives the model something to decompose toward, rather than leaving it to decide where the seams are.

The minimal path exists too. Omit the plan and supply a count alone, and the model generates the default request for you — which works, and gives you no control over what lands where.

The practical difference. A count alone produces a plausible decomposition. A plan produces the decomposition you asked for — background, then illustration, then heading, then body text, then badge — which is what makes the output usable downstream rather than merely interesting.


Ming-Image-0.1-Design-Layer gallery

Additional flattened designs, their transparent layers, and the corresponding recomposed results.


Twelve Steps

The sampling configuration is unusually economical, and it is published as a recommendation rather than left to you.

Sampling steps12
CFG scale2.0
PrecisionBF16
Resolution bucket1024 recommended, 512 for faster work

Twelve steps is low. Most diffusion models use twenty to fifty, and the difference is directly visible in latency.

And CFG 2.0 is low too — a light guidance scale, which on a generation model would produce loose adherence to the prompt.

Both make sense here because the task is different. Decomposition is not synthesis. The model is not inventing an image; it is separating one that already exists. The input constrains the output far more tightly than a text prompt ever could, so less guidance and fewer steps are needed to reach it.

The output preserves the input image's aspect ratio, whichever resolution bucket you use.


Specifications

Model IDinclusionAI/Ming-Image-0.1-Design-Layer
TaskLayer decomposition
PipelineImage-Text-to-Image
Parameters6B
InputFlattened design image + layer plan
OutputRGBA PNG layers + one leading composite
Resolution1024 recommended, 512 faster
Aspect ratioPreserved from input
Sampling steps12
CFG scale2.0
PrecisionBF16
Validated hardwareOne CUDA GPU, 80 GiB VRAM
LicenceMIT
DeveloperinclusionAI — Ant Group

MIT licence. Commercial use, modification, and redistribution with no conditions, no attribution requirement, and no user threshold.

The validated hardware figure is worth noting — 80 GiB for a six-billion-parameter model is more than the parameter count suggests, because a diffusion pipeline holds an encoder, a connector, a diffusion transformer, and a VAE at once, and each layer being generated is a full-resolution RGBA image.


Capabilities

CapabilityValue
input_typesimage, text
output_typesimage — multiple RGBA
taskLayer decomposition
output_countN requested + 1 composite
output_formatRGBA PNG
transparencyYes — alpha channel per layer
layer_count_sourceParsed from the prompt
aspect_ratioPreserved from input
text_generationNot applicable
requires_promptInput image required; layer plan optional

Writing a Layer Plan

Where the quality of the result is decided.

A count alone is the minimum:

CODE
Decompose this image into 6 layers

A plan is what makes the output usable:

CODE
Decompose this image into 6 layers.

Layer 1: the background gradient, full canvas, no other elements.
Layer 2: the decorative border and corner ornaments.
Layer 3: the central illustration, isolated with clean edges.
Layer 4: the headline text only.
Layer 5: the body text block.
Layer 6: the logo and the small print at the bottom.

Three habits that matter.

Order layers back to front. Background first, foreground last. That is the order a design tool expects, and it is what makes the output importable without rearranging.

Name what belongs on each layer, and what does not. "The background gradient, no other elements" prevents a shadow or a border bleeding into a layer that should have been clean.

Group by editability, not by visual similarity. Two text blocks you will always edit together belong on one layer; two you will edit separately belong on two — even if they look alike.

And keep the count honest. Asking for twelve layers from a design with four distinct elements forces the model to invent seams that are not there.


Checking the Result

The composite exists for this, and the check is a few lines.

PYTHON
from PIL import Image, ImageChops
from pathlib import Path


def verify(input_path: str, composite_path: str, threshold: int = 12) -> None:
    """Compare the model's recomposition against the original design."""
    original = Image.open(input_path).convert("RGB")
    composite = Image.open(composite_path).convert("RGB")

    if original.size != composite.size:
        composite = composite.resize(original.size)

    diff = ImageChops.difference(original, composite)
    bbox = diff.getbbox()

    if bbox is None:
        print("identical")
        return

    # Mean absolute difference across all channels.
    pixels = list(diff.getdata())
    mean = sum(sum(p) for p in pixels) / (len(pixels) * 3)

    print(f"mean difference: {mean:.1f}  changed region: {bbox}")

    if mean > threshold:
        raise ValueError("recomposition differs substantially — decomposition likely lost content")

The bounding box is the useful part. It tells you where the recomposition diverged — and a divergence concentrated on one region usually means one element was split badly or dropped.

A perfect match is not the goal. Decomposition and recomposition both pass through a diffusion model; some difference is expected. A large or localised one is the signal.


Stacking the Layers Back

The other half of verification, and the operation your downstream tooling will do anyway.

PYTHON
from PIL import Image
from pathlib import Path


def stack(layer_paths: list[str]) -> Image.Image:
    """Composite RGBA layers back to front into a single image."""
    layers = [Image.open(p).convert("RGBA") for p in layer_paths]

    canvas = Image.new("RGBA", layers[0].size, (0, 0, 0, 0))
    for layer in layers:
        if layer.size != canvas.size:
            raise ValueError(f"layer size {layer.size} does not match canvas {canvas.size}")
        canvas = Image.alpha_composite(canvas, layer)

    return canvas


# Remember: index 0 is the model's composite, not the first layer.
outputs = sorted(Path("outputs/layers").glob("*.png"))
composite, layers = outputs[0], outputs[1:]

stack([str(p) for p in layers]).save("recomposed.png")

The size check earns its place. Layers that do not share a canvas size cannot be composited, and discovering that in a design tool rather than in code is a slower way to learn it.

And note the split at index zero. That is the documented output structure, and it is the easiest thing to get wrong.


Performance

Layer-decomposition results on the Crello test set

Evaluated on the Crello test set, with two metrics measuring different halves of the problem:

RGB L1 — lower is better. How closely each layer's colour content matches the reference. This measures whether the right pixels landed on the right layer.

Alpha soft IoU — higher is better. How closely each layer's transparency mask matches the reference. This measures whether the shape of each layer is right — where it is opaque and where it is not.

The two can disagree, and that is the useful part. A layer with correct colours and a sloppy alpha mask has the right content with ragged edges. A layer with a clean mask and wrong colours has the right shape holding the wrong element. They are different failures needing different fixes.


The Companion Model

Ming-Image-0.1-Design is the other half of the series — a 6B text-to-image model for UI, infographics, posters, and other text-rich visual designs, with RGBA output and transparent background support.

Together they close a loop. Generate a design from a description; decompose it into layers; edit a layer; recompose.

And the series ships two agent workflows built on that loop:

Ling UI Design — using generated visual references and layer decomposition to help an agent build and visually check UI code from a prompt or a screenshot.

Image to Editable PPT — recreating a generated page or slide image as an editable PowerPoint slide, with text and simple shapes converted to native elements.

Read the second one carefully, because it describes what decomposition is actually for: turning a picture of a slide into a slide. The layers are the intermediate step that makes the conversion possible.


Prompt Enhancement

The layer plan can itself be written by a language model. The documentation names two options for prompt enhancement, both vision-capable — a model that looks at the design and writes the layer specification for it.

Which is the natural pipeline. A vision model reads the image, identifies the distinct elements, and produces the layer plan. The decomposition model then executes it.

That removes the step most likely to be skipped. Writing a good layer plan by hand for every image does not scale; having a model write it does.


Self-Hosting

vLLM-Omni is the recommended serving framework, with published recipes and an installation guide.

One CUDA GPU with 80 GiB VRAM is the validated configuration.

Attention implementation is worth one note. flash_attention_2 is optional — the command-line tool defaults to eager attention, because the language component implements only eager and FlashAttention 2, while the diffusion transformer always uses PyTorch SDPA internally regardless of what you select.

Which means the flag affects one half of the pipeline, not both. Selecting it is an optimisation on the language side and changes nothing about the diffusion.

512 rather than 1024 is the lever when throughput matters more than fidelity — faster decomposition at lower working resolution, with the aspect ratio preserved either way.


Where It Fits

Recovering editable designs from flat exports — the core case, and the one nothing else in this catalogue does.

Design-to-code pipelines, where separated layers give an agent structure a flat screenshot does not.

Slide and document reconstruction, turning a rendered page into native editable elements.

Asset extraction — pulling a logo, an illustration, or a badge off a background with a clean alpha mask.

Template creation, decomposing a finished design so the parts can be recombined.

Batch processing of design archives, where the alternative is manual rework in a design tool.

Not for generating images. The companion model in this series does that.

Not for photographs. It was built and evaluated on graphic design — compositions with distinct elements — and a photograph has no layers to recover.

Not for arbitrary image editing. It separates; it does not modify.


Practical Notes

Write a layer plan rather than only a count. The plan is what makes the output usable.

Order layers back to front.

Say what does not belong on each layer, not only what does.

Remember the output is N + 1 — the composite comes first.

Compare the composite against your input before opening any layer.

Keep the layer count honest to the design's actual structure.

Use 1024 for quality, 512 for throughput; the aspect ratio holds either way.

Have a vision model write the layer plan if you are processing at volume.


Limitations

The output count is N + 1, and the extra image leads rather than trails. Off-by-one is the default failure.

Built for graphic design. Posters, cards, UI, infographics — compositions with distinct elements. Photographs and continuous-tone images have no layer structure to recover.

Decomposition is generative. Both the layers and the composite pass through a diffusion model, so neither is a pixel-exact recovery of the original — verify rather than assume.

A plan you write badly is a decomposition you get badly. The model follows the specification, including its mistakes.

An unrealistic layer count forces invented seams. Ask for what the design contains.

80 GiB of VRAM validated for a six-billion-parameter model — the pipeline holds several components and generates full-resolution RGBA output.

No text output. Images in, images out.

Version 0.1. An early release in a new series, with the series' own agent workflows still being established.

Evaluated on one test set. Crello is a graphic-design corpus; performance on your own material is an empirical question with a cheap answer.