Nodes/Symbiotica/Product Gallery Scrape
ComfyUI Node

Product Gallery Scrape

Turn Any Product Page Into Clean, Sorted Reference Images

By symbiotica-ai·Created 6 months ago·Updated about 12 hours ago· 2
Product Gallery Scrape
    • product_images
    • on_model_images
    • other_images
    • summary
    • report
    • product_count
    • on_model_count
    • other_count
    url
    classifierclip
    clip_modelopenai/clip-vit-base-patch16
    max_images12
    image_size1024

    Ever needed reference images of a product and found yourself screenshotting an e-commerce page, cropping out the badges and the "Add to Cart" button by hand? NS Product Gallery Scrape does the whole job: it fetches a product page, pulls the gallery images, and sorts them into three piles - shots of the product alone, shots with a model wearing/using it, and everything else (packaging, banners, lifestyle clutter).

    It exists because "product" is not a clean signal in e-commerce markup. Alt text is empty, image filenames are arbitrary numbers, and page structure varies from store to store. So the node doesn't trust the page - it trusts a vision model. That's the clever bit and it's worth understanding before you use it.

    How it works

    First, scraping: the node reads the page's structured data (JSON-LD Product markup) to find the gallery, with a DOM fallback for stores that don't ship JSON-LD. It's SSRF-guarded - the code checks that the URL resolves to a public http/https target, so you can't point it at an internal address. Images are downloaded with a 25 MB and 40-megapixel cap (oversized ones are dropped rather than decoded - that's a decompression-bomb guard).

    Then, sorting: with classifier set to clip (the default), each image goes through zero-shot CLIP (openai/clip-vit-base-patch16, downloaded on first run) to decide product vs. on-model vs. other. Set classifier to off and everything lands in product_images - useful when you know the page and just want the batch without the download wait.

    Inputs and outputs

    Required: url and classifier. Optional: clip_model (a different Hugging Face CLIP checkpoint), max_images (cap on downloads, 1–32, default 12), and image_size (longest side in pixels, downscale-only, default 1024 - set lower for fast upstream work).

    Outputs: three IMAGE batches - product_images, on_model_images, other_images - plus a summary (a product description built from the page, ready to feed a script LLM), a report (per-image verdicts with confidence, for debugging), and three INT counts: product_count, on_model_count, other_count.

    One quirk to know: empty categories emit a white placeholder frame, not an empty tensor. Gate your downstream logic on the count outputs so a placeholder doesn't get treated as a real image.

    Install and setup

    This is part of the Symbiotica pack. ComfyUI Manager → search "Symbiotica", or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/symbiotica-ai/comfyui-nodes.git symbiotica
    pip install -r symbiotica/requirements.txt
    

    Restart. First run with the CLIP classifier downloads the model - a few hundred MB, one time. No API key needed; this node is fully local.

    Troubleshooting

    • "no gallery images found" - the page blocked the scraper (403) or has no discoverable gallery. Try a different store or check the URL is public. Some shops hard-block scrapers.
    • First run is slow - that's the CLIP model downloading, then CPU zero-shot inference on up to 12 images. It's a one-time cost.
    • Everything lands in "other" - the CLIP classifier is zero-shot; obscure or heavily branded product shots can confuse it. Switch classifier to off and sort manually, or try a stronger clip_model.
    • Images look tiny - that's image_size downscaling (downscale-only, never upscale). Raise it if you need bigger refs, but keep it small if you're just feeding a ControlNet or an edit model.
    CategorySymbiotica/Commerce

    Inputs (5)

    NameTypeDefaultDescription
    urlSTRINGProduct page URL (public http/https).
    classifierCOMBOclipclip: split by content with zero-shot CLIP (downloads the model on first run). off: everything lands in product_images.
    clip_modeloptSTRINGopenai/clip-vit-base-patch16Hugging Face CLIP checkpoint for the classifier.
    max_imagesoptINT121–32Cap on downloaded gallery images.
    image_sizeoptINT1024256–4096Longest side per image (downscale only).

    Outputs (8)

    NameTypeDescription
    product_imagesIMAGE
    on_model_imagesIMAGE
    other_imagesIMAGE
    summarySTRING
    reportSTRING
    product_countINT
    on_model_countINT
    other_countINT