{
 "10": {
  "inputs": {
   "image": "withered_hydrangeas_still_life_vintage_lit.png"
  },
  "class_type": "LoadImage",
  "_meta": {
   "title": "Load Image (source)"
  }
 },
 "24": {
  "inputs": {
   "compare_view": null,
   "image_a": [
    "10",
    0
   ],
   "image_b": [
    "146:34",
    0
   ]
  },
  "class_type": "ImageCompare",
  "_meta": {
   "title": "Compare Images"
  }
 },
 "146:34": {
  "inputs": {
   "image": [
    "10",
    0
   ],
   "alpha": [
    "146:36",
    0
   ]
  },
  "class_type": "JoinImageWithAlpha",
  "_meta": {
   "title": "Join Image with Alpha"
  }
 },
 "146:5": {
  "inputs": {
   "seed": 42,
   "steps": 4,
   "cfg": 1,
   "sampler_name": "euler",
   "scheduler": "simple",
   "denoise": 1,
   "model": [
    "146:1",
    0
   ],
   "positive": [
    "146:4",
    0
   ],
   "negative": [
    "146:4",
    1
   ],
   "latent_image": [
    "146:4",
    2
   ]
  },
  "class_type": "KSampler",
  "_meta": {
   "title": "KSampler"
  }
 },
 "146:36": {
  "inputs": {
   "mask": [
    "146:148",
    0
   ]
  },
  "class_type": "InvertMask",
  "_meta": {
   "title": "Invert Mask"
  }
 },
 "146:35": {
  "inputs": {
   "channel": "red",
   "image": [
    "146:161",
    0
   ]
  },
  "class_type": "ImageToMask",
  "_meta": {
   "title": "Convert Image to Mask"
  }
 },
 "146:4": {
  "inputs": {
   "negative_prompt": "",
   "width": 0,
   "height": 0,
   "batch_size": 1,
   "clip": [
    "146:2",
    0
   ],
   "prompt": [
    "146:164",
    0
   ],
   "vae": [
    "146:3",
    0
   ],
   "images.image_1": [
    "10",
    0
   ]
  },
  "class_type": "TextEncodeFibo2",
  "_meta": {
   "title": "TextEncodeFibo2"
  }
 },
 "146:6": {
  "inputs": {
   "samples": [
    "146:5",
    0
   ],
   "vae": [
    "146:3",
    0
   ]
  },
  "class_type": "VAEDecode",
  "_meta": {
   "title": "VAEDecode"
  }
 },
 "146:1": {
  "inputs": {
   "unet_name": "rmbg3_int8_convrot.safetensors",
   "weight_dtype": "default"
  },
  "class_type": "UNETLoader",
  "_meta": {
   "title": "Load Diffusion Model"
  }
 },
 "146:2": {
  "inputs": {
   "clip_name": "qwen3vl_4b_int8_convrot.safetensors",
   "type": "fibo2",
   "device": "default"
  },
  "class_type": "CLIPLoader",
  "_meta": {
   "title": "Load CLIP"
  }
 },
 "146:3": {
  "inputs": {
   "vae_name": "flux2-vae.safetensors"
  },
  "class_type": "VAELoader",
  "_meta": {
   "title": "Load VAE"
  }
 },
 "146:147": {
  "inputs": {
   "image": [
    "10",
    0
   ],
   "alpha": [
    "146:148",
    0
   ]
  },
  "class_type": "JoinImageWithAlpha",
  "_meta": {
   "title": "Join Image with Alpha"
  }
 },
 "146:148": {
  "inputs": {
   "expand": 0,
   "tapered_corners": true,
   "mask": [
    "146:163",
    0
   ]
  },
  "class_type": "GrowMask",
  "_meta": {
   "title": "Grow Mask"
  }
 },
 "146:156": {
  "inputs": {
   "clip_name": "qwen3vl_4b_int8_convrot.safetensors",
   "type": "stable_diffusion",
   "device": "default"
  },
  "class_type": "CLIPLoader",
  "_meta": {
   "title": "Load CLIP"
  }
 },
 "146:157": {
  "inputs": {
   "value": "You are the prompt writer for an image matting model (RMBG 3.0). You receive a photo and, optionally, a short note from the user about what the subject is or what material it is made of.\n\nAlways answer with ONE paragraph (max 90 words) that instructs the image model to render a grayscale transparency map of the main subject:\n- pure black background;\n- near-white for every opaque part of the subject, naming them as they appear in this image;\n- middle gray for see-through parts (glass, tulle, sheer fabric, liquid, smoke, mesh), dark gray only for the thinnest of them;\n- the entire subject must stay present and opaque parts must not be turned transparent;\n- keep continuous gray gradients inside the shape, and exclude the backdrop and any reflection or shadow on the ground.\n\nRules that override any other reading:\n- A part the note calls transparent, translucent or glass maps to middle gray (dark gray where it is thinnest) - NEVER to near-white.\n- Colour never implies opacity: coloured glass, coloured liquid and coloured mesh are still see-through and get gray, never white.\n- Only parts that are solid in the note and in the photo (skin, fabric, petals, stems, metal, wood) get near-white.\n\nIf the note is empty, decide the opaque / see-through split from the image alone. If the note names a material or what the thing is, treat it as authoritative and let it override what you would otherwise guess.\n\nReply with the instruction only."
  },
  "class_type": "PrimitiveStringMultiline",
  "_meta": {
   "title": "Text (System Prompt)"
  }
 },
 "146:158": {
  "inputs": {
   "max_length": 512,
   "sampling_mode": "on",
   "thinking": true,
   "use_default_template": true,
   "mtp": "auto",
   "clip": [
    "146:156",
    0
   ],
   "prompt": [
    "146:178",
    0
   ],
   "system_prompt": [
    "146:157",
    0
   ],
   "sampling_mode.temperature": 0.7,
   "sampling_mode.top_k": 64,
   "sampling_mode.top_p": 0.95,
   "sampling_mode.min_p": 0.05,
   "sampling_mode.repetition_penalty": 1.05,
   "sampling_mode.presence_penalty": 0,
   "sampling_mode.seed": 0,
   "images.image1": [
    "10",
    0
   ]
  },
  "class_type": "TextGenerateV2",
  "_meta": {
   "title": "Generate Text"
  }
 },
 "146:159": {
  "inputs": {
   "switch": false,
   "on_false": [
    "146:177",
    0
   ],
   "on_true": [
    "146:158",
    0
   ]
  },
  "class_type": "ComfySwitchNode",
  "_meta": {
   "title": "If/Else Switch"
  }
 },
 "146:160": {
  "inputs": {
   "factor": 1,
   "images": [
    "146:6",
    0
   ]
  },
  "class_type": "AdjustBrightness",
  "_meta": {
   "title": "Adjust Brightness"
  }
 },
 "146:161": {
  "inputs": {
   "factor": 1,
   "images": [
    "146:160",
    0
   ]
  },
  "class_type": "AdjustContrast",
  "_meta": {
   "title": "Adjust Contrast"
  }
 },
 "146:162": {
  "inputs": {
   "value": 0.8500000000000001,
   "mask": [
    "146:35",
    0
   ]
  },
  "class_type": "ThresholdMask",
  "_meta": {
   "title": "Threshold Mask"
  }
 },
 "146:163": {
  "inputs": {
   "switch": false,
   "on_false": [
    "146:35",
    0
   ],
   "on_true": [
    "146:162",
    0
   ]
  },
  "class_type": "ComfySwitchNode",
  "_meta": {
   "title": "If/Else Switch"
  }
 },
 "146:164": {
  "inputs": {
   "source": [
    "146:159",
    0
   ]
  },
  "class_type": "PreviewAny",
  "_meta": {
   "title": "Preview as Text"
  }
 },
 "146:177": {
  "inputs": {
   "value": "{\"edit_instruction\": \"Generate a detailed grayscale alpha matte. Map the opaque foreground to white and the background to black. Produce soft, anti-aliased grayscale gradients at the edges of the subject to represent fine details and transparency.\"}"
  },
  "class_type": "PrimitiveStringMultiline",
  "_meta": {
   "title": "Text (Preset Instruction)"
  }
 },
 "146:178": {
  "inputs": {
   "f_string": "Write the matte instruction for this image.\n\nUser note about the subject (authoritative when present, may be empty): {a}",
   "values.a": [
    "146:179",
    0
   ]
  },
  "class_type": "StringFormat",
  "_meta": {
   "title": "Format Text"
  }
 },
 "146:179": {
  "inputs": {
   "value": ""
  },
  "class_type": "PrimitiveStringMultiline",
  "_meta": {
   "title": "Text ( (User guide))"
  }
 },
 "168": {
  "inputs": {
   "mask": [
    "146:163",
    0
   ]
  },
  "class_type": "MaskPreview",
  "_meta": {
   "title": "Preview Mask"
  }
 },
 "170": {
  "inputs": {
   "filename_prefix": "rmbg3/background",
   "images": [
    "146:147",
    0
   ]
  },
  "class_type": "SaveImage",
  "_meta": {
   "title": "SaveImage"
  }
 },
 "171": {
  "inputs": {
   "filename_prefix": "rmbg3/foreground",
   "images": [
    "146:34",
    0
   ]
  },
  "class_type": "SaveImage",
  "_meta": {
   "title": "SaveImage"
  }
 }
}