digitalsamba/claude-code-video-toolkit / .claude/skills/qwen-edit
qwen-edit
UnverifiedAI image editing prompting patterns for Qwen-Image (Qwen-Image-Edit-2511 by default, Qwen-Image-2.1 as a non-commercial Modal opt-in). Use when editing photos while preserving identity, reframing cropped images, changing clothing or accessories, adjusting poses, applying style transfers, or character transformations. Provides prompt patterns, parameter tuning, and examples.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 7.0 KB |
| examples.md | markdown | 6.6 KB |
| parameters.md | markdown | 4.4 KB |
| prompting.md | markdown | 2.9 KB |
parameters.md
View on GitHub# Qwen-Edit Parameters
> **Which model?** Modal runs **Qwen-Image-Edit-2511** unless the app was deployed with
> `IMAGE_EDIT_MODEL=qwen-image-2.1`; `--cloud runpod` runs **Qwen-Image-Edit-2511 +
> Lightning LoRA**. The tables below the first one were measured on 2511. See
> "Qwen-Image-2.1 (Modal opt-in)" at the end for how 2.1 differs.
## Available Parameters
| Parameter | CLI Flag | Default | Range | Notes |
|-----------|----------|---------|-------|-------|
| `num_inference_steps` | `--steps` | 8 (Qwen-Image-Edit-2511, Modal and RunPod); 40 only on a Modal app deployed with `IMAGE_EDIT_MODEL=qwen-image-2.1` | 4-50 | More = higher quality, slower |
| `guidance_scale` | `--guidance` | 1.0 | 1.0-7.0 | Higher = follows prompt more strictly. On 2.1 this is true CFG, off at 1.0 |
| `negative_prompt` | `--negative` | "" | text | Things to avoid |
| `seed` | `--seed` | random | int | For reproducibility |
## Steps (`--steps`)
Controls number of denoising passes. (2511 / RunPod figures -- 2.1 defaults to 40.)
| Value | Use Case | Inference Time |
|-------|----------|----------------|
| 4 | Quick preview, Lightning LoRA | ~10s |
| 8 | Default, good balance | ~18s |
| 16 | Higher quality, finer detail | ~34s |
| 25+ | Diminishing returns | 45s+ |
**Recommendation:** Start with 8. Use 16 for final renders if detail matters.
## Guidance Scale (`--guidance`)
Controls how strictly the model follows your prompt.
| Value | Behavior |
|-------|----------|
| 1.0 | Default, more creative freedom |
| 3.0 | Stronger adherence, more dramatic |
| 4-5 | Recommended max for Qwen-Edit |
| 7.0+ | Risk of artifacts, over-saturation |
**Note:** Qwen-Edit uses lower guidance than typical diffusion models. Don't go above 5-6.
**Recommendation:** Start with 1.0. Try 3.0 for more literal interpretation.
## Negative Prompt (`--negative`)
Critical for avoiding artifacts. Always consider using one.
### Common Negative Prompts
**For portraits/reframing:**
```
blur, blurry, ghostly, distortion, abstract, haze, fog, out of focus
```
**For zoom/scale changes:**
```
black borders, letterbox, vignette, dark edges, frames, cropped
```
**For viewpoint changes:**
```
silhouette, dark figure, no face, shadow, faceless, artifacts, distortion, black
```
**General quality:**
```
deformed, disfigured, bad anatomy, extra limbs, blurry, low quality
```
## Seed (`--seed`)
Use for reproducibility when iterating on prompts.
```bash
# First attempt
uv run tools/image_edit.py --input photo.jpg --prompt "..." --seed 12345
# Same seed, different prompt - compare results
uv run tools/image_edit.py --input photo.jpg --prompt "..." --seed 12345
```
## Cost vs Quality Tradeoffs
| Profile | Steps | Guidance | Time | Cost |
|---------|-------|----------|------|------|
| Quick preview | 4 | 1.0 | ~10s | ~$0.001 |
| Default | 8 | 1.0 | ~18s | ~$0.002 |
| Quality | 16 | 1.0 | ~34s | ~$0.004 |
| Dramatic | 8 | 3.0 | ~18s | ~$0.002 |
| Best | 16 | 3.0 | ~34s | ~$0.004 |
(Costs based on L4 GPU @ $0.34/hr)
## Experimental Parameters
These are supported by the handler but not yet exposed in the CLI:
| Parameter | Default | Notes |
|-----------|---------|-------|
| `use_fp8` | true | FP8 quantization (false = BF16 full quality) |
| `auto_resize` | true | Auto-resize input for optimal processing |
| `true_cfg_scale` | 4.0 | Internal CFG scale |
To expose these, edit `tools/image_edit.py`.
## Qwen-Image-2.1 (Modal opt-in)
| Parameter | Default | Notes |
|-----------|---------|-------|
| `--steps` | 40 | Model card default, used whenever `--steps` is not given. 2.1 is not step-distilled and there is no Lightning LoRA for it here, so low step counts degrade faster than on 2511 |
| `--guidance` | 1.0 | Maps to the pipeline's `true_cfg_scale`. 2.1 is meant to be sampled **without** guidance; `>1` enables true CFG (the endpoint supplies a blank negative prompt if `--negative` is missing) and doubles per-step cost |
| `--negative` | none | Only used when `--guidance > 1` |
| inputs | 1-10 | First is edited, the rest are references or masks |
Endpoint-only extras (not exposed in the CLI): `output_resolution` (default 1024,
output area ~= its square; the model is native up to 2K) and explicit `width`/`height`.
Measured on the Modal A100-80GB ($0.000694/s), 640x640 input -> 1024x1024 output:
27s inference at 40 steps (~$0.02 warm). A cold call took 111s end to end (~85s of it
loading ~33GB of weights), plus the 60s scaledown window -- ~$0.12 for a one-off edit.
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 471k | Updated | Claude CodeCodex | Unverified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |