NA - Sketch to Photo Orchestrator
Turn a Flat Garment Sketch Into a Photoreal Product Shot (for a Price)
- talent_image
- flat_sketch_image
- material_image
- pattern_image
- template_master_1
- template_master_2
- image
- log
- flash_request_json
- nanobana_request_json
This is the node Neural Atelier is named after. NA - Sketch to Photo Orchestrator takes a technical flat sketch - the boring line drawing a patternmaker draws - and turns it into a photorealistic product shot, with a ghost mannequin view, an isometric schematic, or an editorial campaign photo if you prefer. It's aimed squarely at fashion e-commerce and product photography, and it does the whole job with Google's cloud models, not a local checkpoint.
How it works - two-stage, and that's the clever bit. The pipeline is: sketch + brief + reference images → Gemini 3 Flash → one perfect prompt → Nano Banana → final image. ComfyUI runs all the usual local stuff (torch, samplers, VRAM), but the actual generation happens on Google's paid Gemini API. First, Gemini 3 Flash (gemini-3-flash-preview) receives a master prompt from the pack's configs/ folder - each of the 42 profiles is a hand-written "you are a senior fashion tech engineer" system prompt - plus your brief_text and any images you've attached. Flash is forced to reply with a single strict JSON object, {"nano_banana_prompt": "..."}. That generated prompt then goes to the image model, default Nano Banana Pro (gemini-3-pro-image-preview), alongside your images as references, with your chosen aspect_ratio, resolution, and top_p. The image comes back as a normal IMAGE tensor you can save or feed into the rest of your graph.
Nano Banana Pro is worth knowing about even if you never touch this node: it's Google's flagship image model, native 4K output, strong at editing from multiple reference images (the KB doc on closed-source models has the full background). The flip side: it's heavily censored, and every image costs real money - roughly $0.04–$0.24 per image depending on resolution. Recolor and re-run workflows add up fast.
The inputs that matter (it's a lot - start here):
prompt_profile- the 42-profile dropdown that sets the whole job (sketch-to-photo, ghost mannequin, exploded view, e-commerce pack…). This is the single most important knob.brief_text- your creative brief. Flash treats it as authoritative for color, material, and fit.gemini_api_key- your Google AI API key. Or set theGEMINI_API_KEYenv var and leave it blank.image_model,aspect_ratio,resolution(1K/2K/4K),top_p(default 0.95) - generation settings.rerun_nonce- bump this (or hit the "🔄 Re-run from here" button the pack adds) to force a fresh API call; ComfyUI caches node output, and the node'sIS_CHANGEDonly fires on this value.- Optional reference slots:
talent_image,flat_sketch_image,material_image,pattern_image,template_master_1,template_master_2.
Outputs: image (wire to Save Image), plus three strings worth keeping around: log (the run summary with timings), and flash_request_json / nanobana_request_json - the exact request payloads sent to Google. If you're debugging why a shot went sideways, those two JSONs are your audit trail.
Install (same for the whole pack): ComfyUI Manager → search "Neural Atelier", or
cd ComfyUI/custom_nodes
git clone https://github.com/valsecchi75/comfyui_neural_atelier
cd comfyui_neural_atelier && pip install -r requirements.txt
then restart ComfyUI. Only deps are google-genai, Pillow, torch, numpy - no model files to download, because the models live on Google's side.
Where people get burned: missing or bad API key is the #1 failure - the node returns a tiny 64×64 black image plus an error in log, which reads as "it broke" rather than "my key is wrong." Run the pack's NA - Verify API Key node (or the Verify button on the node) first. Expect Google's safety filters to reject some prompts outright - fashion is usually fine, but the model is strict about IP and celebrities. And watch your bill: at 4K, a long iteration session is genuinely not free. Start at 1K while you dial in the prompt profile.
Inputs (15)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt_profile | COMBO | 01_Sketch_to_Photo | 42 options: 01_Sketch_to_Photo, 02_Ghost_Mannequin, 03_Hanger, 04_Grid_2x2, 05_Grid_3x3, 06_Isometric_Schematic, +36 |
| brief_text | STRING | — | |
| gemini_api_key | STRING | — | |
| api_key_status | STRING | Not Verified | — |
| image_model | COMBO | Nano Banana Pro (gemini-3-pro-image-preview) | 2 options: Nano Banana Pro (gemini-3-pro-image-preview), Nano Banana 2 (gemini-3.1-flash-image-preview) |
| aspect_ratio | COMBO | 1:1 | 10 options: 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, +4 |
| resolution | COMBO | 1K | 3 options: 1K, 2K, 4K |
| top_p | FLOAT | 0.950–1 | — |
| rerun_nonce | INT | 00–999999 | — |
| talent_imageopt | IMAGE | — | |
| flat_sketch_imageopt | IMAGE | — | |
| material_imageopt | IMAGE | — | |
| pattern_imageopt | IMAGE | — | |
| template_master_1opt | IMAGE | — | |
| template_master_2opt | IMAGE | — |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| log | STRING | — |
| flash_request_json | STRING | — |
| nanobana_request_json | STRING | — |