> ## Documentation Index
> Fetch the complete documentation index at: https://comfyui-mcp.artokun.io/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Run ERNIE-Image Locally in ComfyUI (Apache-2.0, 2026)

> Run Baidu's ERNIE-Image — the Apache-2.0, 8B text-to-image model with sharp multilingual EN/CN/JP text — locally in ComfyUI. Install, settings, VRAM.

*by [artokun](https://github.com/artokun) · June 16, 2026 · ernie · image · ComfyUI · model highlight*

Most "open" image models come with an asterisk: open weights, closed wallet —
great until you ship something commercial and the license bites. **ERNIE-Image**
is the rare one that doesn't. Baidu shipped it under a real **Apache-2.0** license,
it renders **crisp multilingual text** (English, Chinese, Japanese) better than
almost anything its size, and the Turbo build runs **under 8 GB of VRAM** in about
8 steps. You can run the whole thing **locally in ComfyUI** — no API key, no
per-image fee, no non-commercial clause hanging over your head.

Below: what ERNIE-Image actually is (and the one thing people keep getting wrong
about it), how it stacks up against Ideogram 4 and Z-Image, the VRAM you need, and
the fastest way to get it running — a one-command install with
[comfyui-mcp](https://github.com/artokun/comfyui-mcp) and the [sidebar Panel](../panel),
instead of hand-downloading GGUFs and untangling a contaminated installer.

> **TL;DR — one-command setup.** Install comfyui-mcp, apply the `ernie` pack
> (`apply_manifest --path packs/ernie/manifest.yaml`, or run the generated
> `install-windows.bat` / `install-runpod.sh`), and drive the graph from your own
> Claude session via the Panel. Jump to [Install](#install-ernie-image-in-comfyui).

## What is ERNIE-Image?

ERNIE-Image (released **April 15, 2026** by Baidu's ERNIE-Image team) is an
**open-weight, single-stream Diffusion Transformer** with **about 8B DiT
parameters**. In ComfyUI it's paired with a **Ministral-3-3B** text encoder and the
**Flux 2 VAE**, plus an optional **3B Prompt Enhancer** that auto-expands short
prompts into richer descriptions. ComfyUI added **day-0 support** in April 2026.

**The license is the headline — and it's genuinely permissive.** ERNIE-Image ships
under **Apache-2.0**, which allows commercial use, modification, and redistribution,
full stop. That's a real difference from [Ideogram 4](./ideogram-4-comfyui),
which is open *weight* but under a **Non-Commercial** agreement (commercial use
needs a paid license). With ERNIE you can put it in a product on day one. No gated
download drama, no "for research only" footnote.

There are two builds. **ERNIE-Image** (base) takes \~50 steps for peak quality.
**ERNIE-Image-Turbo** is distilled (Distribution Matching Distillation + RL) and is
high-fidelity in **\~8 steps at cfg 1** — that's the one the pack ships, and the one
that fits under 8 GB.

## ERNIE-Image vs Ideogram 4 vs Z-Image

There's no single "best" — pick by the job:

| Pick…             | When you need…                                                                                                                       |
| ----------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| **ERNIE-Image**   | **Truly permissive (Apache-2.0)** commercial use, **multilingual EN/CN/JP text**, posters/signage/manga layouts, runs **under 8 GB** |
| **Ideogram 4**    | **Area-prompting** with structured JSON bounding boxes, fine-grained poster/logo **layout control**, brand-color accuracy            |
| **Z-Image Turbo** | **Raw speed + low VRAM** general-purpose ideation (\~2.5s), LoRA-training stability on the base                                      |
| **Qwen-Image**    | A larger, popular dev model also strong on long text — see our [Qwen-Image post](./qwen-image-comfyui)                               |

Where rivals win: **[Ideogram 4](./ideogram-4-comfyui)** gives you explicit
spatial control — draw bounding boxes, place text and objects by region — which
ERNIE doesn't expose (you steer ERNIE with descriptive prose). **[Z-Image](./z-image-comfyui)**
is the speed king for fast general ideation. But ERNIE wins decisively on the two
axes that matter for production text work: a **permissive license** and **clean
multilingual typography**. Each of those models gets its own post in this series —
this one is ERNIE's spotlight for **commercial-safe, text-rich images**.

## System & VRAM requirements

The official non-quantized release targets a **24 GB** card. The pack sidesteps
that by shipping the **Turbo GGUF**, so you pick a quant to fit your GPU:

| Quant        | VRAM           | Notes                                |
| ------------ | -------------- | ------------------------------------ |
| **Q5\_K\_S** | **under 8 GB** | Smallest; the under-8 GB target      |
| **Q6\_K**    | 8–12 GB        | Quality/VRAM middle ground           |
| **Q8\_0**    | 12–16 GB+      | Highest fidelity; the pack's default |

The Ministral-3-3B encoder and Flux 2 VAE add a few GB on top. The pack ships
**Q8\_0**; if you're tight on VRAM, edit the quant in the filename (e.g.
`ernie-image-turbo-Q5_K_S.gguf`) before installing. Running the bundled ERNIE↔Z-Image
*combo* pipelines loads two UNets, so budget for both or just run the single-model
ERNIE group.

## Install ERNIE-Image in ComfyUI

The manual route works: update ComfyUI, install the GGUF + a handful of node packs,
and drop the files into the right folders.

| File                                                                   | Folder                   |
| ---------------------------------------------------------------------- | ------------------------ |
| `ernie-image-turbo-Q8_0.gguf` (Turbo DiT)                              | `models/unet/`           |
| `ministral-3-3b.safetensors` (text encoder, load as CLIP type `flux2`) | `models/text_encoders/`  |
| `ernie-image-prompt-enhancer.safetensors` (optional enhancer)          | `models/text_encoders/`  |
| `flux2-vae.safetensors` (VAE)                                          | `models/vae/`            |
| `4x-ClearRealityV1.pth` (upscaler)                                     | `models/upscale_models/` |

(Canonical weights live in the official **Comfy-Org/ERNIE-Image** HF repo, Apache-2.0,
with the same filenames as the third-party mirror.)

### A real-world install gotcha

If you grab the popular third-party installer, beware: **it's contaminated with
Z-Image leftovers.** The upstream scripts are copy-pasted from a Z-Image pack —
their headers literally say "Z-IMAGE-BASE" and they download Z-Image-only files
(`z_image_turbo-*.gguf`, `Qwen3-4B-*.gguf`, `ae.safetensors`) that **ERNIE never
uses**. Pull those by mistake and you waste disk and end up wiring the wrong VAE.
**The comfyui-mcp `ernie` pack excludes them** — it installs only ERNIE's actual
files (`ernie-image-turbo`, `ministral-3-3b`, `flux2-vae`, and the optional enhancer).

### The fast way — comfyui-mcp + the Panel

Untangling that installer by hand is exactly the busywork the
[comfyui-mcp](https://github.com/artokun/comfyui-mcp) **`ernie` pack** removes. One
declarative manifest installs the custom nodes (ComfyUI-GGUF, rgthree, KJNodes,
essentials, RES4LYF, and friends) and pulls every model to the correct folder —
ERNIE-only, no Z-Image cruft — and the same manifest drives both an MCP-native
install and the generated double-click scripts:

```bash theme={null}
# MCP-native (from a Claude Code session, with COMFYUI_PATH set)
apply_manifest --path packs/ernie/manifest.yaml

# or one-click
packs/ernie/install-windows.bat      # Windows
packs/ernie/install-runpod.sh        # RunPod / Linux
```

Then load `packs/ernie/workflow.json`. Because the pack ships with the
[plugin](../plugin), your **own Claude session can drive the live graph through the
[Panel](../panel)** — add/wire nodes, set widgets, and iterate on prompts
conversationally, with full Ctrl+Z undo and no extra API keys. Every model URL in
the pack is CI-validated for reachability and size, so a link never quietly rots
([here's why that matters](./installer-packs-that-cant-rot)).

## Why text and layout are its superpower

This is the part that holds up to scrutiny. Per Baidu's published benchmarks,
ERNIE-Image hits:

* **LongTextBench \~0.9733** — state-of-the-art for long, layout-sensitive text
  rendering among open models.
* **GenEval \~0.8856 overall** — strong compositional accuracy, with a notable lead
  on **position understanding** and **attribute binding**.

A character-aware encoder trained on Baidu's web-scale **CJK** text-image corpus is
the reason Chinese (and Japanese) glyphs come out clean — stroke order and radical
composition, not mangled approximations. *(Benchmark figures are vendor-reported;
treat the "state-of-the-art" framing as scoped to text rendering and structured
layout, not general photorealism.)*

The practical version: if the image has to **carry words** — a poster headline, a
sign, a manga speech bubble, a UI mockup, multilingual packaging — ERNIE is the
open model to reach for. Write the exact string you want in quotes and it renders
it.

### It is TEXT-TO-IMAGE — not an editor (read this)

The single most common ERNIE confusion: people expect it to **edit a photo**. It
doesn't. **ERNIE-Image is a text-to-image generator.** You describe an image and it
paints one from scratch. It does **not** follow grounded edit instructions like
"change the shirt to red" or "remove the person on the left."

The shipped workflow *does* have an "image-to-image" path, and that's where the
confusion starts — but that path is **denoise-based refinement** (a style/detail
pass over one source image at low denoise), **not** instruction editing. If your
job is "change X in this photo," reach for **Qwen-Image-Edit** or **Flux Kontext**
instead. ERNIE's lane is generation, especially text- and layout-heavy generation.

## What to make with it

ERNIE's sweet spots all share one trait — the image has to say something:

* **Multilingual posters & key visuals** — EN/CN/JP headlines that render cleanly.
* **Text-heavy designs** — signage, packaging, menus, UI mockups, ad creatives.
* **Manga / anime layouts** — multi-panel pages and storyboards with legible speech
  bubbles (write the literal string in quotes).
* **Structured multi-object scenes** — ERNIE's strong instruction following handles
  complex, knowledge-heavy prompts.
* **Fast ideation** — Turbo's 8-step generation makes iterating on concepts cheap.

Prompting tip: lead with the **exact text** you want, in quotes — e.g. *a vintage
travel poster, bold title reading "KYOTO" at the top* — then describe style and
layout in plain, structured prose. That's ERNIE's headline strength.

## Settings that matter

The pack's workflow is tuned already, but for reference — these are the Turbo
defaults extracted from the shipped graph:

| Setting                       | Value                                                                        |
| ----------------------------- | ---------------------------------------------------------------------------- |
| Steps                         | **8–9** (Turbo)                                                              |
| CFG                           | **1**                                                                        |
| Sampler                       | **euler**                                                                    |
| Scheduler                     | **simple**                                                                   |
| Denoise                       | **1.0** (txt2img) · **0.35–0.4** (img2img refine)                            |
| `ModelSamplingAuraFlow` shift | **3.1**                                                                      |
| Resolution                    | 1920×1088 shipped (`EmptySD3LatentImage`); 1024–2048 long edge is reasonable |

A few notes that save grief:

* **Keep `ModelSamplingAuraFlow` shift at 3.1.** It's applied to the model before
  sampling; drop it and Turbo output goes soft/undercooked.
* **CFG 1 means negative conditioning is effectively inert.** The graph still wires
  a `ConditioningZeroOut` as the negative — that's normal, not a bug.
* **Base (non-Turbo) `ernie-image`?** Bump to \~50 steps and raise cfg (≈3.5–5)
  since it isn't distilled.
* **Use the Prompt Enhancer for short prompts**, turn it off (`ComfySwitchNode`
  false) once you've written a detailed prompt yourself.

## Troubleshooting

* **`UnetLoaderGGUF` / `CLIPLoaderGGUF` missing** → install **ComfyUI-GGUF** (city96).
* **`Power Lora Loader` / `Image Comparer` missing** → install **rgthree-comfy**.
* **`ImageResize+` missing** → install **ComfyUI\_essentials**.
* **`TextGenerate` (enhancer) missing** → install via ComfyUI-Manager search, or set
  the `ComfySwitchNode` to the raw prompt (switch=false) and skip enhancement.
* **CLIP type error on Ministral** → set `CLIPLoader` `type` to **`flux2`** (not
  `qwen_image` / `lumina2`; `lumina2` belongs to the Z-Image encoder).
* **Wrong-VAE artifacts** → ERNIE must use **`flux2-vae.safetensors`**;
  `ae.safetensors` is the Z-Image VAE.
* **Blurry / undercooked output** → confirm `ModelSamplingAuraFlow shift=3.1` is
  wired and steps ≥ 8 for Turbo.
* **You wanted to EDIT a photo and it ignored you** → expected. ERNIE is txt2img;
  use Qwen-Image-Edit or Flux Kontext for grounded edits.
* **Installer pulled Z-Image files too** → that's the contaminated upstream script;
  use the `ernie` pack, which excludes them.

## FAQ

**Is ERNIE-Image open source?** Yes — genuinely. It's released under **Apache-2.0**,
which permits commercial use, modification, and redistribution. Unlike Ideogram 4's
non-commercial license, there's no separate paid agreement to ship commercially.

**Can ERNIE-Image edit my photos?** No. It's **text-to-image** only. The workflow's
"image-to-image" is a low-denoise refine pass, not instruction editing. For "change
X in this photo," use Qwen-Image-Edit or Flux Kontext.

**How much VRAM do I need?** The Turbo GGUF runs in **under 8 GB** at the Q5\_K\_S
quant; Q6\_K wants 8–12 GB and Q8\_0 wants 12–16 GB+. The non-quantized official
release targets a 24 GB card.

**How many parameters?** About **8B** — a single-stream Diffusion Transformer, paired
with a Ministral-3-3B text encoder and the Flux 2 VAE.

**Is it good at non-English text?** Yes — that's a core strength. It renders
**English, Chinese, and Japanese** cleanly thanks to a character-aware encoder
trained on a large CJK corpus.

**ERNIE-Image vs Z-Image — which should I use?** [Z-Image](./z-image-comfyui)
for the fastest general-purpose ideation; **ERNIE** when you need a permissive
license plus precise multilingual text and structured layouts.

**Why is the text so accurate?** Reported **LongTextBench \~0.9733** — ERNIE was
designed for layout-sensitive, multilingual text rendering, not as an afterthought.
(Figures are vendor-reported; scope the claim to text/layout.)

***

## Get it running in one command

1. Install [comfyui-mcp](https://github.com/artokun/comfyui-mcp) and the [Panel](../panel) — the panel auto-starts a background agent on your Claude subscription (no API keys; sign in with `claude` once).
2. Apply the **`ernie` pack** — nodes + ERNIE-only models land in the right folders, validated, with the Z-Image cruft stripped out.
3. Open the [Panel](../panel) and let the panel's agent write multilingual prompts and wire the graph for you.

That's the whole point of the project: expert ComfyUI setups that install in one
step and drive themselves from your own agent session. **Next in the series:**
[ANIMA 1.0](./anima-comfyui) — the tiny anime model that generates and trains
LoRAs under 6 GB.
