arkennemasis fal · Flux LoRA Fill · $0.035/MP
The inpainter that can be handed elements to insert
- image
- mask
- fill_image_fill_image_1
- fill_image_fill_image_2
- fill_image_fill_image_3
- fill_image_fill_image_4
- fill_image_fill_image_5
- fill_image_fill_image_6
- images
- image_paths
- timings
- has_nsfw_concepts
- prompt
- seed
- info
Flux Fill is BFL's purpose-trained inpainting and outpainting model, and it's the last one that was actually trained for masks - nothing comparable has shipped since, which is why it's still the answer when an edit model's whole-frame rewrite isn't acceptable. This node exposes the LoRA flavour of it, and it goes one step further than a normal inpaint: you can hand it pictures to place inside the hole.
What makes it different
Most inpainters generate something plausible in the masked region. Fill can be given a reference element and told to fit that in - the six fill_image_fill_image_1…_6 sockets on the node are exactly that, and each can carry a batch. The tooltip is precise about ordering: socket 1 first, then socket 2, and within a socket, in order. That's how you tell it "put this lamp here and that rug there" instead of hoping.
The second thing to know is guidance_scale, which defaults to 30 here with a range of 28–35. If you've internalised Flux's usual 3.5, that number will look like a typo. It isn't - it's the Fill endpoint's own convention, and it's why trying to be clever with a low guidance value produces mush.
The inputs that matter
image- the picture being edited.mask- a ComfyUIMASK; the node converts it to the RGBA convention fal expects (transparent where you painted) and resizes it to your image.prompt- tooltip says empty leaves it out, so a mask-only fill with no text is legitimate.paste_back(default true) - composite the original back over everything outside the mask. This is the setting that gives you bit-identical surroundings, so leave it on unless you specifically want the whole frame re-rendered.fill_image_in_context_fill(default false) - uses the provided fill image in context with the base image "to fill in more faithfully", and the tooltip warns it increases the price. This is the one to flip when the inserted element keeps landing in the wrong lighting.fill_image_use_prompt(default false) - use the prompt as well as the reference image.resize_to_original(default false) - turn on to get the exact original dimensions back. Handy when the endpoint's chosen size keeps nudging your framing.loras- multiline JSON of LoRA entries with weights and scale, merged together. Empty leaves them out.
Plus image_size / image_size_width / image_size_height, num_inference_steps (28), seed, num_images, enable_safety_checker, output_format, acceleration, and the pack's shared max_cost_usd, reuse_identical_run, extra_json and max_concurrent.
Outputs
images → preview or save. image_paths → output/fal/fal-ai_flux-lora-fill/. Then has_nsfw_concepts, prompt, seed, timings and info.
Install
cd ComfyUI/custom_nodes
git clone https://github.com/Hishamahmer/comfyui-arkennemasis
or search comfyui-arkennemasis in Manager. Restart, then find it under arkennemasis/fal/Image/Flux. Keys go in .env next to run_nvidia_gpu.bat:
FAL_KEY=your-key-from-fal.ai/dashboard/keys
Realistic problems
Guidance at 3.5. A common first mistake, carried over from local Flux habits. The Fill range starts at 28 for a reason.
Prices that jump when you connect a fill image. fill_image_in_context_fill explicitly costs more, and it's the kind of setting you enable for a hard composite and forget to switch off. Also note the whole image's megapixels are billed, not the masked area.
Mask and image disagreeing. The mask is resized to the image, so it lines up - but paint the region you want changed, not the region you want to keep.
Empty output region. If the fill produces something blank or nonsensical, check whether paste_back is fighting you, and whether a stray reference socket is carrying a placeholder tile. The pack treats placeholder tiles as "no image", which is the right behaviour and also means a connected-but-empty socket quietly does nothing.
Inputs (28)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | The prompt to generate an image from. Empty leaves it out. | |
| image_size | COMBO | square_hd | The size of the generated image. 'custom' uses the width and height below. |
| image_size_width | INT | 102416–14142 | Width in pixels when image_size is 'custom'. |
| image_size_height | INT | 102416–14142 | Height in pixels when image_size is 'custom'. |
| num_inference_steps | INT | 281–50 | The number of inference steps to perform. |
| seed | INT | -1-1–2147483647 | The same seed and the same prompt given to the same version of the model will output the same image every time. -1 leaves it to the model. |
| loras | STRING | The LoRAs to use for the image generation. You can use any number of LoRAs and they will be merged together to generate the final image. JSON. Empty leaves it out. | |
| guidance_scale | FLOAT | 30.0028–35 | The CFG (Classifier Free Guidance) scale is a measure of how close you want the model to stick to your prompt when looking for a related image to show you. |
| num_images | INT | 11–4 | The number of images to generate. This is always set to 1 for streaming output. |
| enable_safety_checker | BOOLEAN | true | If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked, and images flagged as unsafe are returned as black images. |
| output_format | COMBO | jpeg | The format of the generated image. |
| acceleration | COMBO | none | Acceleration level for image generation. 'regular' balances speed and quality. |
| image | IMAGE | URL of image to use for fill operation | |
| mask | MASK | The mask to area to Inpaint in. | |
| paste_back | BOOLEAN | true | Specifies whether to paste-back the original image onto to the non-inpainted areas of the output |
| fill_image_in_context_fill | BOOLEAN | false | Uses the provided fill image in context with the base image to fill in more faithfully. Will increase price. |
| fill_image_use_prompt | BOOLEAN | false | Whether to use the prompt as well in the generation, along with the redux image. |
| resize_to_original | BOOLEAN | false | Resizes the image back to the original size. Use when you wish to preserve the exact image size as the originally provided image. |
| fill_image_fill_image_1opt | IMAGE | URLs of images to be filled into the masked area. Each socket may carry a batch; they are sent in socket order (the first picture of socket 1 is number 1). | |
| fill_image_fill_image_2opt | IMAGE | URLs of images to be filled into the masked area. Each socket may carry a batch; they are sent in socket order (the first picture of socket 1 is number 1). | |
| fill_image_fill_image_3opt | IMAGE | URLs of images to be filled into the masked area. Each socket may carry a batch; they are sent in socket order (the first picture of socket 1 is number 1). | |
| fill_image_fill_image_4opt | IMAGE | URLs of images to be filled into the masked area. Each socket may carry a batch; they are sent in socket order (the first picture of socket 1 is number 1). | |
| fill_image_fill_image_5opt | IMAGE | URLs of images to be filled into the masked area. Each socket may carry a batch; they are sent in socket order (the first picture of socket 1 is number 1). | |
| fill_image_fill_image_6opt | IMAGE | URLs of images to be filled into the masked area. Each socket may carry a batch; they are sent in socket order (the first picture of socket 1 is number 1). | |
| max_cost_usdopt | FLOAT | 20.00–100000 | Safety cap. If the estimated cost of this run is above this many US dollars the node stops BEFORE sending anything to fal. 0 = no cap. |
| reuse_identical_runopt | BOOLEAN | true | If these exact inputs (the settings AND the same pictures/clips/audio) were already paid for and the files are still in output/fal, return them instead of paying again - also after a ComfyUI restart. Turn off for a fresh take with the same settings. |
| extra_jsonopt | STRING | Advanced: a JSON object merged into the request last, for any fal field this node has no box for. Example: {"seed": 7}. Leave empty normally. | |
| max_concurrentopt | INT | 11–32 | How many paid fal calls may run at the same time in one run, across every fal node. 1 (default) = one after another. This node starts its paid part only while fewer than this many fal calls are running. Once any fal node fails, the ones still waiting are not started, so nothing more is billed. |
Outputs (7)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| image_paths | STRING | — |
| timings | STRING | — |
| has_nsfw_concepts | STRING | — |
| prompt | STRING | — |
| seed | INT | — |
| info | STRING | JSON: request id, cost estimate, saved files and fal's full answer. |