Nodes/GPT img/GPT img API Generate Advanced
ComfyUI Node

GPT img API Generate Advanced

The Advanced GPT generate node that thinks in specs

By hub2vu·Created 4 months ago·Updated 4 months ago· 3
GPT img API Generate Advanced
  • reference_image
  • image
  • revised_prompt
design_requestMen's navy summer suit.
generation_instructionsCreate a product-only apparel design image for fashion planning. Output format: Show exactly two views of the same garment in one image: - front view on the left - back view on the right The garment must be shown alone on a clean white or very light gray background. The result should look like a professional e-commerce product catalog image or a fashion technical presentation image. The front and back views must represent the same garment design. Use the same color, fabric, sleeve shape, collar type, hem shape, and overall silhouette in both views.
reference_instructionsUse the first reference image, if provided, as a layout reference only for the front/back side-by-side composition. Use the other reference images only for garment category, silhouette, color, material feel, fabric texture, collar, sleeve, button, pocket, seam, and hem details. Do not copy the exact product design, brand, logo, text, watermark, person, pose, background, or photography artifacts. If reference images contain a human model, ignore the person and use only the garment design cues. The user design request has priority over the reference images if there is any conflict.
hard_constraintsNo human model. No mannequin. No hanger. No body parts. No face. No arms. No legs. No person wearing the garment. No lifestyle background. No studio props. No table. No folded garment. No flat lay. No extra accessories. No text labels. No logo. No watermark.
api_key
modelgpt-5.5
qualitymedium
size1024x1024
moderationlow
n1
timeout_sec300
system_promptYou are an image generation assistant. Use the image_generation tool to create the requested image. Preserve the user's prompt, requested style, language, subject, and composition as closely as possible. Return image output, not explanatory text.
system_prompt_input
user_prompt_input

If you've ever tried to get an open model to render a clean front-and-back product shot of a garment, you know the pain: logos where they shouldn't be, a "model" appearing out of nowhere, the back view being a different color than the front. GPT img API Generate Advanced is aimed squarely at that problem. Its defaults are tuned for fashion planning - a garment alone on a white background, front view left, back view right, no person, no props, no logo. It's the most opinionated node in this pack, and the opinions are the point.

Like the plain API Generate, this bills your OpenAI API key per image. The OAuth version (GPT img OAuth Generate Advanced) runs the same pipeline against your ChatGPT subscription.

How it works

The node doesn't just paste one prompt. It composes a structured instruction block from four separate text inputs, then sends it through OpenAI's image_generation tool. The clever bit: an explicit conflict rule is inserted so your design_request always wins if generation_instructions or reference_instructions contradicts it. If you feed it reference_image frames, up to five are base64-encoded and sent as visual context, with the README's default rules saying "use them for garment cues, don't copy the brand."

The inputs that matter

  • design_request - the authoritative description of the garment, in any language. This has priority.
  • generation_instructions - reusable rules about output format and quality. The default is the front/back catalog layout.
  • hard_constraints - the negative list: no model, no mannequin, no text, no logo. This is where the "person appeared anyway" problem gets fought.
  • reference_image - optional IMAGE input; the first frame is used for layout, the rest for design cues.

Plus the usual api_key, model, quality, size, moderation, n, and timeout_sec, and the system_prompt widget with its optional socket overrides.

Outputs

  • image - the catalog-style result as a ComfyUI IMAGE (batched if n > 1).
  • revised_prompt - the rewritten prompt. Worth checking here especially, because a lot of instruction is being compressed into it.

Install

Manager may not list this pack yet (registry version is Pending), so the reliable path is manual:

cd ComfyUI/custom_nodes
git clone https://github.com/hub2vu/Comfyui-GPT-img-node.git GPT-img

Restart ComfyUI. No extra Python dependencies - the pack's dependency list is empty.

Common issues

The trap is forgetting the design request is authoritative. If hard_constraints says no flat lay but design_request mentions a flat lay, the design request wins by design - so phrase what you actually want in that field. And remember this is billed per generated image; the default n is 1, and it's worth keeping it there while you tune the instructions, since a wrong spec costs you a credit every run.

CategoryGPT img

Inputs (15)

NameTypeDefaultDescription
design_requestSTRINGMen's navy summer suit.
generation_instructionsSTRINGCreate a product-only apparel design image for fashion planning. Output format: Show exactly two views of the same garment in one image: - front view on the left - back view on the right The garment must be shown alone on a clean white or very light gray background. The result should look like a professional e-commerce product catalog image or a fashion technical presentation image. The front and back views must represent the same garment design. Use the same color, fabric, sleeve shape, collar type, hem shape, and overall silhouette in both views.
reference_instructionsSTRINGUse the first reference image, if provided, as a layout reference only for the front/back side-by-side composition. Use the other reference images only for garment category, silhouette, color, material feel, fabric texture, collar, sleeve, button, pocket, seam, and hem details. Do not copy the exact product design, brand, logo, text, watermark, person, pose, background, or photography artifacts. If reference images contain a human model, ignore the person and use only the garment design cues. The user design request has priority over the reference images if there is any conflict.
hard_constraintsSTRINGNo human model. No mannequin. No hanger. No body parts. No face. No arms. No legs. No person wearing the garment. No lifestyle background. No studio props. No table. No folded garment. No flat lay. No extra accessories. No text labels. No logo. No watermark.
api_keySTRING
modelCOMBOgpt-5.54 options: gpt-5.5, gpt-5, gpt-5.4, gpt-5.4-mini
qualityCOMBOmedium3 options: low, medium, high
sizeCOMBO1024x102413 options: 1024x1024, 1536x1024, 1024x1536, 1360x1024, 1024x1360, 1824x1024, +7
moderationCOMBOlow2 options: low, auto
nINT11–8
timeout_secINT30030–3600
system_promptSTRINGYou are an image generation assistant. Use the image_generation tool to create the requested image. Preserve the user's prompt, requested style, language, subject, and composition as closely as possible. Return image output, not explanatory text.
system_prompt_inputoptSTRING
user_prompt_inputoptSTRING
reference_imageoptIMAGE

Outputs (2)

NameTypeDescription
imageIMAGE
revised_promptSTRING