flux2-dev-edit
Training a LoRA that edits — Flux 2 Dev edit, minus the 48GB card
- model
- api_config
- moderation_status
- epochs
- sample_images_prompts
- sample_input_images
- stored_as_assets
- eta
- workflow_id
- raw_json
The Flux 2 family's party trick is editing - single- and multi-reference edits in one checkpoint, with a level of understanding the community still calls "unparalleled" for local models. And the people who swear by it agree on one thing: you need a monster card to run it, let alone train on it. This node is the edit-flavored training recipe: it trains a LoRA for the Flux 2 Dev edit variant, in the cloud, so the "RTX 6000 or nothing" wall disappears.
If you've got a character or a product that keeps needing consistent edits across a set of reference images, this is the node built for exactly that job - and it's one of the most specialized things in the whole Civitai pack.
How it works
Same hosted-training machinery as the plain Flux2Dev node: model (CIVITAI_AIR, wired from a Civitai Model Selector), training_data (a URL to your dataset), and training_data_images_count (cost input). What's different is the extra knob that makes it "edit" training:
reference_image_count- default 1, range 1–4. The number of reference images per training pair, and the tooltip is upfront about what that means: "Affects cost calculation via reference multiplier." Edit training is pair-based - an input image, a target edit, and reference(s) that anchor the identity - so more references per pair trains better consistency but multiplies the bill.
The rest mirrors the Dev node: steps (default 1000, increments of 100), learning_rate (5e-05), lora_name, sample_prompts_json, negative_prompt, default_caption.
Outputs are the training status set: moderation_status, epochs, sample_images_prompts, sample_input_images, stored_as_assets, eta, workflow_id, raw_json.
Inputs you actually touch
reference_image_count- the edit-specific decision. Start at 1 to validate your dataset and costs; raise toward 4 once you know the pipeline works and want stronger identity anchoring.steps- the main quality/cost lever.lora_name- name the artifact something you'll recognize.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/civitai/civitai-comfy-nodes.git
pip install -r civitai-comfy-nodes/requirements.txt
Or ComfyUI Manager → "Civitai Comfy Nodes" → Install → restart. Authenticate (CIVITAI_API_TOKEN or sidebar); training bills in Buzz, and edit training with the reference multiplier bills more.
Gotchas
The reference multiplier is the trap, and it's a real one: reference_image_count isn't a quality dial you can ignore, it's a cost multiplier wired straight into the price. Read the tooltip before you bump it. Also, edit training needs a paired dataset - input/target pairs, not just a folder of pretty images - and the captions (via default_caption or caption files) matter more than in plain LoRA training because the model has to learn the edit relationship, not just the subject. The KB's training doc holds: auto-caption a large set, audit a small one by hand. And it's early preview - training recipes are the pack's newest and most likely-to-change corner, so don't be surprised if output shapes shift between releases.
Inputs (11)
| Name | Type | Default | Description |
|---|---|---|---|
| model | CIVITAI_AIR | The primary model to train upon. | |
| training_data | STRING | A url referring data to use in training. | |
| training_data_images_count | INT | 00–2147483647 | The number of images embedded in this training data. This is used to calculate the cost of training. |
| lora_nameopt | STRING | my-lora | The desired lora name. |
| sample_prompts_jsonopt | STRING | A selection of sample prompts. | |
| negative_promptopt | STRING | An optional negative prompt that will get applied when generating samples | |
| stepsopt | INT | 1000100–10000 | Number of training steps. Must be in increments of 100. |
| learning_rateopt | FLOAT | 0.000–2147483647 | Learning rate for training. |
| default_captionopt | STRING | Default caption to use if caption files are missing from training data. | |
| reference_image_countopt | INT | 11–4 | Number of reference images per training pair (1-4). Affects cost calculation via reference multiplier. |
| api_configopt | CIVITAI_CONFIG | Optional Civitai Auth connection; defaults to CIVITAI_API_TOKEN or stored OAuth login. |
Outputs (8)
| Name | Type | Description |
|---|---|---|
| moderation_status | STRING | — |
| epochs | STRING | — |
| sample_images_prompts | STRING | — |
| sample_input_images | STRING | — |
| stored_as_assets | STRING | — |
| eta | STRING | — |
| workflow_id | STRING | — |
| raw_json | STRING | — |