kulkas2pintu/QWEN_EDIT_IMAGE

Space

246

stars

267

commits

Jul 30, 2026

updated

gradio
mcp-server

README

Prompt-based image editing on Qwen-Image-Edit-2511, with identity preservation (change pose/clothes/scene while keeping the person's face), HD output, and an anti-deformed-hands option.

Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference


API

The Space exposes one endpoint: /edit. Base URL / Space id: kulkas2pintu/QWEN_EDIT_IMAGE.

Parameters

nametypedefaultmeaning
imageimage (filepath/URL)required. The image to edit (the person/subject whose identity is kept).
promptstrrequired. What to change, e.g. "change her outfit to a red dress; turn to look left".
lora_adapterstr""Optional style LoRA name (see list below). "" = no style / base edit.
image2imageNoneOptional 2nd reference image (e.g. a style or lighting reference).
seedint0Seed; ignored when randomize_seed=True.
randomize_seedboolTruePick a new random seed each call.
guidance_scalefloat1.0true-CFG. 1.0 = fastest. >1 (e.g. 2.5) activates the negative prompt that suppresses extra fingers / identity drift (slower, ~2×).
stepsint4Denoise steps. 4 is native for this distilled model.
preserve_identityboolTrueKeep the person's face while pose/head can change.
identity_strengthint650-100, how forcefully identity is locked.
output_sizeint1280Long-side pixels 1024-2048. Higher = more HD detail, slower (~quadratic).
fix_handsboolFalseRaise CFG/steps to suppress extra/fused fingers (slower).

Returns: [result_image, seed_used].

Available lora_adapter names

Multiple-Angles, Fal-Multiple-Angles (best for pose/angle changes), Photo-to-Anime, Anime-V2, Light-Migration, Any-light, Studio-DeLight, Cinematic-FlatLog, Upscaler, Unblur-Anything, Style-Transfer, Manga-Tone, Anything2Real, Polaroid-Photo, Midnight-Noir-Eyes-Spotlight, Hyper-Realistic-Portrait, Ultra-Realistic-Portrait, Pixar-Inspired-3D, Noir-Comic-Book.

Tip: for realistic edits keep preserve_identity=True. Uncheck it (preserve_identity=False) for full-transform styles like Photo-to-Anime / Pixar-Inspired-3D.

Python (gradio_client)

pip install gradio_client
from gradio_client import Client, handle_file

client = Client("kulkas2pintu/QWEN_EDIT_IMAGE")  # add hf_token="hf_..." for a private Space

result_image, seed_used = client.predict(
    image=handle_file("https://example.com/person.jpg"),  # or a local path
    prompt="change her outfit to an elegant red dress; turn her head to the left",
    lora_adapter="",            # or e.g. "Fal-Multiple-Angles" for pose changes
    image2=None,
    seed=0,
    randomize_seed=True,
    guidance_scale=2.5,          # >1 turns on hand/identity negatives
    steps=6,
    preserve_identity=True,
    identity_strength=80,
    output_size=1536,            # HD
    fix_hands=True,
    api_name="/edit",
)
print("saved to:", result_image, "| seed:", seed_used)

result_image is a local filepath to the PNG result.

JavaScript (@gradio/client)

npm i @gradio/client
import { Client } from "@gradio/client";

const image = await (await fetch("https://example.com/person.jpg")).blob();
const client = await Client.connect("kulkas2pintu/QWEN_EDIT_IMAGE");

const res = await client.predict("/edit", {
  image,
  prompt: "change her outfit to a red dress",
  lora_adapter: "",
  guidance_scale: 2.5,
  steps: 6,
  output_size: 1536,
  fix_hands: true,
});
console.log(res.data);   // [result_image, seed_used]

curl (raw REST)

Gradio's REST API is a two-step call (queue → result):

# 1) submit the job (image can be a public URL)
curl -s -X POST https://kulkas2pintu-qwen-edit-image.hf.space/gradio_api/call/edit \
  -H "Content-Type: application/json" \
  -d '{"data":[
        {"path":"https://example.com/person.jpg"},
        "change her outfit to a red dress",
        "", null, 0, true, 2.5, 6, true, 80, 1536, true
      ]}'
# -> {"event_id":"<id>"}

# 2) stream the result
curl -N https://kulkas2pintu-qwen-edit-image.hf.space/gradio_api/call/edit/<id>

The data array is positional, in the same order as the parameter table above.

The live, always-up-to-date schema is at https://kulkas2pintu-qwen-edit-image.hf.space/gradio_api/ (the "view API" JSON). This Space also runs as an MCP server (/gradio_api/mcp/), so /edit is usable as a tool from MCP-compatible clients.

Contributors

prithivMLmods

254 commits

kulkas2pintu

12 commits

rancat26

1 commits

kulkas2pintu/QWEN_EDIT_IMAGE

Space

246

stars

267

commits

Jul 30, 2026

updated

gradio
mcp-server

README

Prompt-based image editing on Qwen-Image-Edit-2511, with identity preservation (change pose/clothes/scene while keeping the person's face), HD output, and an anti-deformed-hands option.

Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference


API

The Space exposes one endpoint: /edit. Base URL / Space id: kulkas2pintu/QWEN_EDIT_IMAGE.

Parameters

nametypedefaultmeaning
imageimage (filepath/URL)required. The image to edit (the person/subject whose identity is kept).
promptstrrequired. What to change, e.g. "change her outfit to a red dress; turn to look left".
lora_adapterstr""Optional style LoRA name (see list below). "" = no style / base edit.
image2imageNoneOptional 2nd reference image (e.g. a style or lighting reference).
seedint0Seed; ignored when randomize_seed=True.
randomize_seedboolTruePick a new random seed each call.
guidance_scalefloat1.0true-CFG. 1.0 = fastest. >1 (e.g. 2.5) activates the negative prompt that suppresses extra fingers / identity drift (slower, ~2×).
stepsint4Denoise steps. 4 is native for this distilled model.
preserve_identityboolTrueKeep the person's face while pose/head can change.
identity_strengthint650-100, how forcefully identity is locked.
output_sizeint1280Long-side pixels 1024-2048. Higher = more HD detail, slower (~quadratic).
fix_handsboolFalseRaise CFG/steps to suppress extra/fused fingers (slower).

Returns: [result_image, seed_used].

Available lora_adapter names

Multiple-Angles, Fal-Multiple-Angles (best for pose/angle changes), Photo-to-Anime, Anime-V2, Light-Migration, Any-light, Studio-DeLight, Cinematic-FlatLog, Upscaler, Unblur-Anything, Style-Transfer, Manga-Tone, Anything2Real, Polaroid-Photo, Midnight-Noir-Eyes-Spotlight, Hyper-Realistic-Portrait, Ultra-Realistic-Portrait, Pixar-Inspired-3D, Noir-Comic-Book.

Tip: for realistic edits keep preserve_identity=True. Uncheck it (preserve_identity=False) for full-transform styles like Photo-to-Anime / Pixar-Inspired-3D.

Python (gradio_client)

pip install gradio_client
from gradio_client import Client, handle_file

client = Client("kulkas2pintu/QWEN_EDIT_IMAGE")  # add hf_token="hf_..." for a private Space

result_image, seed_used = client.predict(
    image=handle_file("https://example.com/person.jpg"),  # or a local path
    prompt="change her outfit to an elegant red dress; turn her head to the left",
    lora_adapter="",            # or e.g. "Fal-Multiple-Angles" for pose changes
    image2=None,
    seed=0,
    randomize_seed=True,
    guidance_scale=2.5,          # >1 turns on hand/identity negatives
    steps=6,
    preserve_identity=True,
    identity_strength=80,
    output_size=1536,            # HD
    fix_hands=True,
    api_name="/edit",
)
print("saved to:", result_image, "| seed:", seed_used)

result_image is a local filepath to the PNG result.

JavaScript (@gradio/client)

npm i @gradio/client
import { Client } from "@gradio/client";

const image = await (await fetch("https://example.com/person.jpg")).blob();
const client = await Client.connect("kulkas2pintu/QWEN_EDIT_IMAGE");

const res = await client.predict("/edit", {
  image,
  prompt: "change her outfit to a red dress",
  lora_adapter: "",
  guidance_scale: 2.5,
  steps: 6,
  output_size: 1536,
  fix_hands: true,
});
console.log(res.data);   // [result_image, seed_used]

curl (raw REST)

Gradio's REST API is a two-step call (queue → result):

# 1) submit the job (image can be a public URL)
curl -s -X POST https://kulkas2pintu-qwen-edit-image.hf.space/gradio_api/call/edit \
  -H "Content-Type: application/json" \
  -d '{"data":[
        {"path":"https://example.com/person.jpg"},
        "change her outfit to a red dress",
        "", null, 0, true, 2.5, 6, true, 80, 1536, true
      ]}'
# -> {"event_id":"<id>"}

# 2) stream the result
curl -N https://kulkas2pintu-qwen-edit-image.hf.space/gradio_api/call/edit/<id>

The data array is positional, in the same order as the parameter table above.

The live, always-up-to-date schema is at https://kulkas2pintu-qwen-edit-image.hf.space/gradio_api/ (the "view API" JSON). This Space also runs as an MCP server (/gradio_api/mcp/), so /edit is usable as a tool from MCP-compatible clients.

Contributors

prithivMLmods

254 commits

kulkas2pintu

12 commits

rancat26

1 commits