Best Local AI for Image Editing and Inpainting

Local models that edit a photo you already own: instruction editing, mask inpainting and outpainting, with download sizes, licences and what fits in VRAM.

Editing a picture you already own is the local-AI task with the shortest distance between what you want and what you get: remove the object in the corner, change the jacket, extend the frame, replace the text on the invoice. It is also the task where the model families diverge most, where the download size is only half the story, and where the licence decides more than any leaderboard.

Three different jobs sit under the word editing

Instruction editing means you describe the change in words and the model applies it: “turn this cat into a dog”, “replace the text in the second row of the table”. That is the job FLUX.1 Kontext, the Qwen-Image-Edit family and FLUX.2 [klein] are built for.

Mask inpainting means you paint the region you want rewritten and leave the rest of the image untouched. That is a different model, FLUX.1 Fill, and ComfyUI ships both an inpainting and an outpainting template for it.

Multi-reference editing means you feed several images and ask for a new one that keeps their characters, style or product identity. FLUX.2 [klein] does this in the same architecture it generates with.

Getting that distinction right is what stops you making a 20 GB download that turns out to do the wrong job.

The models side by side

Sizes are decimal gigabytes, converted from the byte counts published in each repository’s file listing. The VDEBench columns are the scores published on the VDEBench dataset, a benchmark of 3,506 document editing examples in English and Chinese; “Local” is the headline task and both scores average IoU, CDM, BLEU-4 and TEDS.

ModelJobWeights to downloadLicenceCommercial useVDEBench local / global
FLUX.2 [klein] 4Bediting, generation, multi-reference7.75 GB BF16, 2.60 GB Q4_K_M GGUFApache 2.0yes0.767 / 0.807
FLUX.2 [klein] 9Bsame family, larger18.16 GB BF16, 5.67 GB Q4_K_M GGUFFLUX non-commercialweights nonot scored
Qwen-Image-Edit-2511instruction and multi-image editing, built-in LoRAs20.50 GB int8, 40.86 GB BF16Apache 2.0yes0.656 / 0.699
Qwen-Image-Edit-2509instruction and multi-image editing20.43 GB fp8Apache 2.0yes0.618 / 0.639
FLUX.1 Kontext [dev]instruction editing, successive edits11.90 GB fp8FLUX.1 [dev] Non-Commercialoutputs yes, weights no0.423 / 0.321
FLUX.1 Fill [dev]mask inpainting and outpainting23.81 GB upstream bf16, 6.81 GB Q4_K_S GGUFFLUX.1 [dev] Non-Commercialoutputs yes, weights nonot scored
SDXL inpainting 0.1legacy mask inpainting6.94 GB fp16openrail++with use restrictionsnot scored

Two rows in that table need reading carefully. FLUX.2 [klein] 9B is the bigger sibling of the model most people should install, and it is the one whose repository licence field reads FLUX non-commercial with access gating, while the 4B in the same family is Apache 2.0 and ungated. The Klein family’s own card says the 4B is “Fully open under Apache 2.0” and lists “Open weights available for commercial use”. On the FLUX.1 side, the Kontext and Fill weights carry the FLUX.1 [dev] Non-Commercial License, but the Kontext model card says “Generated outputs can be used for personal, scientific, and commercial purposes, as described in the FLUX.1 [dev] Non-Commercial License”. You can sell what you make with it; you cannot ship the weights inside your own product.

And the leaderboard is not the whole story. The top global score in the November 5 batch belongs to Qwen-Image-2.1, whose licence file grants use “FOR NON-COMMERCIAL PURPOSES ONLY”. VDEBench also measures dense document pages, so a high score means a model is good at replacing text and table cells while preserving layout. It does not mean the model is good at changing the colour of a jacket.

The pipeline is bigger than the model

Every one of these models is a pipeline: a diffusion transformer, a text encoder and a VAE. The transformer file is the number vendors quote, and it is often the smallest part.

PipelineTransformerText encoderVAEFiles you download
FLUX.2 [klein] 4B7.75 GB8.04 GB, or 3.85 GB fp40.34 GB16.13 GB, or 11.94 GB with the fp4 encoder
FLUX.1 Kontext11.90 GB fp85.16 GB fp8 T5 plus 0.25 GB CLIP-L, or 9.79 GB fp16 T5 plus 0.25 GB CLIP-L0.34 GB17.64 GB, or 22.27 GB with the fp16 encoder
Qwen-Image-Edit-251120.50 GB int89.38 GB fp8, or 6.11 GB nvfp40.25 GB30.14 GB, or 26.87 GB with the nvfp4 encoder

Those are file totals, not published memory floors, and runtime use is higher than the sum. The practical consequence is that quantising the diffusion model buys less than it looks. For FLUX.2 [klein] 4B, the GGUF ladder in the Unsloth repository runs from 1.83 GB at Q2_K to 4.30 GB at Q8_0, but the Qwen3-4B text encoder at 8.04 GB is larger than the BF16 transformer it sits next to, so a Q4_K_M transformer, the fp4 encoder and the VAE still mean 6.79 GB of files before anything is generated.

Only one publisher in this family states a memory floor at all. The FLUX.2 [klein] card says the model “runs on consumer hardware, with as little as 13GB VRAM” and lists “~13GB VRAM” as a key feature. The Kontext and Qwen cards publish no VRAM figure, so any tier advice for those two has to come from file sizes, which is weaker ground.

What fits on which card

12 to 16 GB. FLUX.2 [klein] 4B, on the publisher’s own 13 GB figure. The catch is that the card also calls it “our fastest distilled model”, the reference example runs four inference steps, and ComfyUI’s own editing template names a file (flux-2-klein-base-4b-fp8.safetensors) that the Comfy-Org repackage does not currently list, so check the file list before you plan the download.

16 to 24 GB. FLUX.1 Kontext becomes practical, at 17.64 GB of files with the fp8 T5 encoder. Two catches: the weights are non-commercial and gated, so you have to accept the licence and share your Hugging Face details before the files download, and the card requires that “Filters or manual review must be used with the model under the terms of the FLUX.1 [dev] Non-Commercial License”.

24 GB and up. Qwen-Image-Edit-2511, with the fp8 text encoder, needs 30.14 GB of files, so it wants a 32 GB card or the nvfp4 encoder at 26.87 GB. Its card pitches it at identity-preserving work, listing “Improved Multi-Person Consistency”, “Built-in Support for Community-Created LoRAs” and “Realistic lighting control”, and ComfyUI ships a 2511 workflow that uses the int8 checkpoint with a Lightning 4-step LoRA.

8 GB and below. The realistic pick is the legacy SDXL inpainting model: the fp16 diffusers files total 6.94 GB. Its repository has no licence file at all, only the openrail++ field in the Hugging Face metadata, so read the terms before shipping anything.

Mask inpainting specifically. FLUX.1 Fill is the model built for it, and ComfyUI’s template expects a file called flux1-fill-dev.safetensors. Searching Comfy-Org’s public repositories for a Fill repackage returns nothing, so that file comes from the gated upstream repository (23.81 GB in bf16) or from a community conversion such as YarvixPA/FLUX.1-Fill-dev-GGUF (6.81 GB at Q4_K_S).

The bottom line

If you want one local editor that is commercially clean, ungated and light enough for the 13 GB of VRAM the publisher names, FLUX.2 [klein] 4B is the answer, and its Apache 2.0 licence is the cleanest in the family. If your edits are on documents, VDEBench is the scoreboard worth reading, and klein leads the November 1 batch with a local score of 0.767 against Qwen-Image-Edit-2511’s 0.656. If you need identity preserved across edits and have a 32 GB card, the Qwen-Image-Edit line is the more capable tool, and 2511 is the version to install. If you need a mask rather than a sentence, FLUX.1 Fill is the current model here built for it (SDXL inpainting is the legacy option), and its licence is the one to read twice.

None of this replaces picking a model for the job you are actually doing. The generation guide covers where the weights come from, the OCR and document extraction guide covers reading the pages you want to edit, and the VRAM hub maps every tier to its picks. The Local AI hub collects the rest of the local stack.

Other GPUs and tasks: Local AI by VRAM · RSS