CoolFace
Modelpublic

Airmongsity/Qwen-Image-2.1-Sts2-Cards-Drawer

sourceHugging Faceotherupdated 2d agoView on Hugging Face
0likes
Model Card

Deckbuilder Card Art Style LoRA (Qwen-Image-2.1)

Built with Qwen. A rank-32 style LoRA for Qwen/Qwen-Image-2.1 that produces flat, hard-edged vector-like illustrations in the visual idiom of modern roguelike deckbuilder card art: big faceted colour planes, solid dark shadow masses, a thin bright rim-light tracing the subject, and abstract two-hue backgrounds.

Non-commercial only. Research and evaluation use only. See License below.

Base modelQwen/Qwen-Image-2.1 (7B DiT)
Rank / alpha32 / 32
Patched modulesto_q, to_k, to_v, to_out.0, img_mlp.out (32 blocks, 320 tensors, 50.3M params)
Filedeckbuilder_cardart_style_lora_v1_fp16.safetensors (100 MB, fp16)
Triggerstart the prompt with sts2 card art, <class> card.

Usage (ComfyUI)

Put the file in ComfyUI/models/loras/, add a LoraLoaderModelOnly node after the model loader. It works with any quantisation of the base model (bf16, fp8, GGUF Q4/Q5/Q8) — the adapter is applied at inference time, so you keep the ability to change its strength.

These settings matter far more than the LoRA itself:

lora strength : 0.9
cfg           : 3.0          # the single most important knob; at cfg 1.0 the model
                             # largely ignores the prompt and output degrades badly
negative      : flat, plain, simple, blurry, smooth gradients, empty background,
                low detail, deformed, extra limbs
steps         : 25           # 40 steps measured no better, just slower
resolution    : 1024x768 (1280x960 gives slightly flatter, more vector-like shapes)
sampler       : euler / simple

Write concrete detail words (chipped metal edges, rivets, red outline tracing the weapon, flying stone chips). Vague words (highly detailed, masterpiece) do nothing.

Known weak spots: complex mechanical structures and faces are the first things to break; generate several seeds and pick. Objects, weapons, hands, effects and hooded/backlit figures are the strongest cases.

Training

Trained on Kaggle (2×T4) with DiffSynth-Studio (commit 7686e54d), 598 images, captions written by Qwen3-VL-8B-Instruct describing content and colour only (never style, so the style binds to the trigger phrase).

resolution 768x576 · 4 epochs · 1196 steps · lr 1e-4 · AdamW wd 0.01 · rank 32
fp16 model weights + fp32 LoRA params + accelerate --mixed_precision fp16 (GradScaler)
stage 1: cache text embeddings + VAE latents · stage 2: DiT quantised to NF4 (bitsandbytes)

Four things cost a lot of time and are worth knowing if you reproduce this:

  1. 1.fp16 without loss scaling silently destroys the LoRA. A first run (no GradScaler) showed loss climbing from 0.16 to 0.41 and produced weights that wreck any image they touch. accelerate --mixed_precision fp16 fixes it; bf16 also works but is ~7x slower on a T4 (no bf16 tensor cores).
  2. 2.T4 cannot compile flex_attention (64 KB shared-memory limit) — force FLEX_ATTN_AVAILABLE = False to fall back to the SDPA split-attention path.
  3. 3.Kaggle's preinstalled torchao 0.10 makes peft refuse to inject the LoRA — uninstall it.
  4. 4.DiffSynth's disk offload breaks on the text encoder's embedding layer — quantise the encoder to NF4 instead.

scripts/ contains everything needed to reproduce: build_notebook.py (generates the Kaggle notebook with all of the above applied), prepare_dataset.py (dataset filtering), captions.csv (the 598 captions), qig.py (a small ComfyUI API client for single/batch generation) and the generated notebook.

Dataset and copyright

The training images were card illustrations from a commercial game, extracted locally. They are not distributed here, and will not be — only the captions (machine-generated text) and the recipe. If you reproduce this, use images you have the right to use.

Whether model weights derived from copyrighted images are themselves a derivative work is legally unsettled and differs by jurisdiction; this release takes no position on that question. It is published for research and evaluation, non-commercially. If the rights holder of the source artwork objects, contact the uploader and this repository will be taken down.

Artistic style as such is generally not protected by copyright, but that observation does not resolve the status of the weights, and nothing here is legal advice.

License

The base model is licensed under the Qwen RESEARCH LICENSE AGREEMENT, which permits derivative works for non-commercial purposes only (research or evaluation). This adapter inherits that restriction: neither it nor its outputs may be used commercially.

Qwen is licensed under the Qwen RESEARCH LICENSE AGREEMENT, Copyright (c) 2026 Hangzhou Tongyi Laboratory Technology Co., Ltd. All Rights Reserved.

See NOTICE and the full license.