Ad-Ready: AI Advertising Image Generator
Generate professional advertising images from product URLs using a 4-phase AI pipeline on ComfyDeploy.
Source: github.com/PauldeLavallaz/ads_SV
Pipeline Architecture
The pipeline runs as a ComfyUI custom node deployed on ComfyDeploy. A single ProductToAds_Manual node executes 4 phases internally:
CODEBLOCK0
Phase 2: Campaign Brief (The Creative Brain)
The Brief Generator is the most critical intermediate step. It acts as a "Senior Art Director" that translates raw data into actionable creative direction using a 10-point framework:
- 1. Strategic Objective — Why this campaign exists (awareness/positioning/launch)
- Central Message — One idea perceivable without text
- Visual Tone of Voice — Register: calm/energetic/intimate/monumental
- Product Role — Hero vs co-protagonist vs implicit presence
- Visual Language & Brand Coherence — Non-negotiable brand codes
- Photographer & Equipment — Photography as concept, not execution
- Extended Art Direction — Styling, casting, poses, hair/makeup, layout
- Environment & Context — Where and why (conceptual, never decorative)
- Texture, Material & Product Render — How surfaces are perceived
- Final Image Signature — Finish, grain, temporal positioning
Without the brief, the Master Prompt must guess creative strategy. With it, the Master Prompt only executes.
The brief prompt template is included at {baseDir}/configs/Brief_Generator/brief_prompt.json.
Phase 3: Master Prompts (8 Funnel Stages)
Each funnel stage has a specialized Master Prompt that generates a production-ready JSON Blueprint. All share the same internal simulation:
- - ROUND -1: Brand Identity Forensics (stages 03+) — Unified Brand Style Manifest
- ROUND 0: Fidelity Lock — Product geometry & talent identity are IMMUTABLE
- ROUND 1: Stage Strategy — Strategic approach specific to funnel position
- ROUND 2: Graphic Design — UI, typography, CTA engineering
The Blueprint JSON covers: scene production, talent lock, camera perspective, subject action/pose/wardrobe, lighting, product constraints, layout architecture, typography, CTA engineering, and brand asset placement.
Master prompt files are included at {baseDir}/configs/Product_to_Ads/.
Reference Analyzer
Reference images (referencia) are optional and off by default. The pipeline generates creative direction internally from Brand Identity + Campaign Brief. Only use a reference when the user explicitly asks to clone a specific ad's style.
When used, the reference is analyzed for pose, photographic style, and location cues.
⚠️ CRITICAL: Required Inputs Checklist
Before running ANY ad generation, ensure these are provided:
| Input | Required? | How to Get It |
|---|
| INLINECODE4 | ✅ ALWAYS | User provides the product page URL |
| INLINECODE5 |
✅ ALWAYS | Download from the product page, or user provides |
|
--brand-profile | ✅ NEVER EMPTY | Pick from catalog or run brand-analyzer first. NEVER leave as "No Brand" if a brand is known |
|
--prompt-profile | ✅ ALWAYS | Choose based on campaign objective |
|
--aspect-ratio | Default: 4:5 | Change if needed for platform |
|
--model | 🔶 OPTIONAL | Model/talent face. Ads with talent perform much better. Empty = product-only ad (no person). When used, pick from
~/clawd/models-catalog/catalog/images/ (114 models available) |
|
--logo | 🔶 OPTIONAL | Try to find it. Use if good quality & easy to get. Skip if low-res or hard to find. Empty = bypassed |
|
--reference | 🔶 OPTIONAL (off) | Only when user explicitly asks to clone a reference ad. Empty = bypassed |
|
--creative-brief | 🔶 ON-DEMAND | Only when user gives explicit creative direction. Omit to let pipeline auto-generate from brand profile |
|
--language | 🔶 ON-DEMAND | Only when user requests a specific language. Omit to use default (es) |
🚨 NEVER Skip These Steps:
- 1. Product image — Download the main product photo from the product URL. The scraper is fragile; always provide a product image explicitly.
- Brand profile — If the brand doesn't exist in the catalog, run
brand-analyzer skill FIRST to generate one. Never submit with "No Brand" when a brand is known. - Brand logo — TRY to find it (Clearbit, logo.dev, brand website). Use if good quality. If not found or low-res, skip it — the variable accepts empty string (bypassed server-side).
- Reference — Do NOT search for references by default. Only provide when the user explicitly asks to clone a specific ad or says "find a good ad to clone".
Auto-Preparation Workflow
When the user asks to generate an ad:
CODEBLOCK1
Usage
Full command (recommended):
CODEBLOCK2
With reference (only when explicitly requested):
CODEBLOCK3
Auto-fetch mode (downloads product image and logo automatically):
CODEBLOCK4
List available brands:
uv run {baseDir}/scripts/generate.py --list-brands
API Details
Endpoint: https://api.comfydeploy.com/api/run/deployment/queue
Deployment ID: INLINECODE17
ComfyDeploy Input Variables
| Variable | Type | Description |
|---|
| INLINECODE18 | string | Product page URL to scrape |
| INLINECODE19 |
image URL | Product image (uploaded to ComfyDeploy) |
|
model | image URL | Model/talent face reference.
OPTIONAL — empty = product-only ad without a person. When used, select from models catalog (
~/clawd/models-catalog/catalog/images/model_XX.jpg, 114 available) |
|
referencia | image URL | Style reference ad — OPTIONAL, empty = bypassed. Only when user asks to clone a reference |
|
marca | image URL | Brand logo — OPTIONAL, empty = bypassed. Use if found easily in good quality |
|
brand_profile | enum | Brand name from catalog (70+ brands) |
|
prompt_profile | enum | Funnel stage master prompt |
|
aspect_ratio | enum | Output format (1:1, 4:5, 5:4, 9:16, etc.) |
|
language | string |
ON-DEMAND ONLY. Output language for ad copy/CTA. Default:
es. Only send when the user explicitly requests a different language. Otherwise, DO NOT include this parameter — let the pipeline use its default. |
|
creative_brief | string |
ON-DEMAND ONLY. Free-text creative direction override. Only use when the user explicitly asks for a specific creative direction, scene, mood, or concept. Otherwise, DO NOT include this parameter — let the pipeline generate its own brief from the Brand Identity profile automatically. |
Funnel Stages — Strategic Detail
01 — Awareness
Goal: Scroll-stop, curiosity, brand introduction
Reject: Generic "product on table" concepts
Strategy: Dynamic camera angles, world-building environments, high-concept creativity
CTA: Soft or optional
Visual Hierarchy: Talent → Product → Optional CTA
02 — Interest
Goal: Sustained attention, introduce value proposition
Reject: Abstract visuals that hide the product
Strategy: One clear visual idea, believable micro-world hinting at use-case
CTA: Learn More, Discover, See Details
Visual Hierarchy: Talent → Product → Headline → CTA
03 — Consideration
Goal: Informed evaluation, reduce uncertainty
Reject: Pure mood storytelling, vague emotional content
Strategy: Communicate WHAT product does, ONE primary differentiator, ONE proof cue
CTA: Compare, See Details, Explore
Visual Hierarchy: Talent → Product → Key Benefit → Proof Cue → CTA
New: Adds Brand Identity Manifest to Blueprint JSON
04 — Evaluation
Goal: Validate purchase decision, proof & trust
Reject: Pure mood, unsupportable claims, visual clutter
Strategy: One trust anchor (quality/legitimacy/authority), one proof cue (reviews/certification)
CTA: See Reviews, Verified Quality, Learn More
Visual Hierarchy: Trust Anchor → Proof Cue → Product → Talent → CTA
05 — Conversion
Goal: Trigger decisive action, remove friction
Reject: New hesitation-inducing info, complex compositions
Strategy: One hero (product), one action, optional micro-reassurance
CTA: Buy Now, Get Yours, Complete Order (PRIMARY visual element)
Visual Hierarchy: Product → CTA → Optional Reassurance → Brand → Talent
06 — Retention
Goal: Post-purchase confidence, reduce churn
Reject: Hard-sell, urgency, price talk
Strategy: "You made the right choice" + "Here is the next step"
CTA: Start, Set Up, Learn, Track (guidance, not purchase)
Visual Hierarchy: Confirmation → Next Step → Product → Talent
07 — Loyalty
Goal: Strengthen emotional bond over time
Reject: Sales layouts, instructional tone, aggressive CTAs
Strategy: "This brand is part of who you are" — habitual engagement
CTA: Optional: Explore, Be Part Of, Continue
Visual Hierarchy: Brand World/Mood → Talent (identity mirror) → Product → Brand
08 — Advocacy
Goal: Turn customers into voluntary brand ambassadors
Reject: Sales language, instructional tone, forced testimonials
Strategy: Signal belonging, create share-worthy imagery, enable organic sharing
CTA: Optional or absent: Join the Movement, Part of Us
Visual Hierarchy: Mood → Talent (identity proxy) → Product (symbol) → Brand
09 — Morfeo Creative 🎨 (DEFAULT)
Goal: Maximum visual impact, narrative-rich, cinematic quality
Reject: White backgrounds, studio shots, "product on table", generic poses, sterile compositions
Strategy: Build immersive WORLDS, not backgrounds. Talent is a CHARACTER with emotion and action. Subtle surreal/magical elements elevate the mundane. Think movie stills + magical realism + high fashion.
CTA: Present but integrated into scene aesthetics
Visual Hierarchy: Scene → Talent (as character) → Product (organic in scene) → CTA
Creative Philosophy:
- - NEVER a white background or studio
- Every image has depth (foreground/midground/background layers)
- Lighting is narrative (golden hour, practicals, colored atmosphere)
- One subtle surreal element per scene (impossible beauty, dream-logic detail)
- Wardrobe is costume design, not "simple clothes"
- Camera has personality (specific film stocks, intentional imperfections)
Creating New Ad Types
To create a new funnel stage or specialized ad type:
- 1. Copy the closest existing Master Prompt from INLINECODE30
- Redefine ROUND 1 with the new strategic objective
- Adjust ROUND 2 UI hierarchy accordingly
- Shift talent/product narrative roles
- Modify CTA philosophy and copy voice
- Keep the JSON output structure identical for pipeline compatibility
- Maintain the Fidelity Lock (ROUND 0) — product and talent are always immutable
- Save as
Master_prompt_XX_NewStage.json — the node auto-discovers new profiles
Key Evolution Pattern Across Stages:
| Aspect | Early (01-02) | Mid (03-05) | Late (06-08) | Morfeo (09) |
|---|
| Talent role | Attention anchor | Credibility anchor | Identity mirror | Character in story |
| Product role |
Secondary hero | Evaluation hero | Familiar symbol | Organic in world |
| CTA | Soft/exploratory | Proof-led → Decisive | Guidance → Optional | Integrated/aesthetic |
| Copy voice | Intriguing | Clarity, proof, action | Supportive → Proud | Evocative/poetic |
| Visual density | High-concept | Structured, scannable | Editorial, spacious | Cinematic/layered |
| Environment | World-building | Context-rich | Lifestyle | Immersive + surreal |
| Environment | World-building | Context-rich | Lifestyle, intimate |
Image Input Types
Binding Images (strict fidelity — immutable)
- - talent: Face/body locked, no deviation in facial structure, ethnicity, proportions
- product1-4: Shape, label text, material, proportions preserved 1:1
- brandlogo: UI/button style derived from logo geometry
Soft References (optional, off by default)
Reference image input (
referencia) is optional. When provided, it's analyzed for:
- - POSEREF → Body position, limbs, weight, gaze, micro-gestures
- PHOTOSTYLEREF → Camera, lens, lighting, grading, grain
- LOCATIONREF → Setting, materials, colors, mood
When empty (default), creative direction comes from Brand Identity + Campaign Brief alone.
Brand Profiles
Catalog (70+ brands):
CODEBLOCK6
Creating new brand profiles:
Use the
brand-analyzer skill:
CODEBLOCK7
The Brand Analyzer uses a 3-phase methodology:
- 1. Phase 1: Official research via Google Search (canonical data: name, founding, positioning, vision, mission, tagline)
- Phase 1.1: Independent campaign research (10+ distinct campaigns via Google Images/Pinterest)
- Phase 2-3: Visual analysis → JSON profile following the standard template
Output covers: brandinfo, brandvalues, targetaudience, toneofvoice, visualidentity, photography, campaignguidelines, brandbehavior, channel_expression, compliance.
Aspect Ratios
| Ratio | Use Case |
|---|
| INLINECODE34 | Default. Instagram feed, Facebook |
| INLINECODE35 |
Stories, Reels, TikTok |
|
1:1 | Square posts |
|
16:9 | YouTube, landscape banners |
|
5:4 | Alternative landscape |
|
2:3 | Pinterest |
|
3:4 | Portrait |
Config Files Reference
The skill includes reference copies of all pipeline configuration files:
CODEBLOCK8
These configs are the canonical reference for the pipeline's behavior. The actual live configs are stored in the ComfyUI deployment at ads_SV/configs/.
Known Limitations
- 1. Product image scraping is fragile — always provide product images manually
- Some websites block scraping — provide product data manually when scraping fails
- Gemini hallucinations — occasional issues in complex reasoning steps
- No brief editing — brief is generated automatically; manual override not yet supported
- Logo & reference are optional — both use server-side bypass; empty string = not used. Logo: use if good quality. Reference: only on explicit request
Ad-Ready vs Morpheus
| Feature | Ad-Ready | Morpheus |
|---|
| Input | Product URL (auto-scrapes) | Manual product image |
| Brand intelligence |
70+ brand profiles | None |
| Funnel targeting | 8 funnel stages | None |
| Brief generation | Auto (10-point creative direction) | None |
| Creative direction | Objective-driven (brief → blueprint) | Pack-based (camera, lens, lighting) |
| Best for | Product advertising campaigns | Fashion/lifestyle editorial photography |
| Control level | High-level (strategy-first) | Granular (every visual parameter) |
API Key
Uses ComfyDeploy API key. Set via COMFY_DEPLOY_API_KEY environment variable.
Source Repository
-
ProductToAds_Manual — Full manual control, single format
-
ProductToAds_Auto — Auto-downloads images, generates 4 formats
-
BrandIdentityAnalyzer — Analyzes brands via Gemini + Google Search
Ad-Ready: AI广告图片生成器
通过ComfyDeploy上的4阶段AI流水线,从产品URL生成专业广告图片。
来源: github.com/PauldeLavallaz/ads_SV
流水线架构
该流水线作为部署在ComfyDeploy上的ComfyUI自定义节点运行。单个ProductToAds_Manual节点在内部执行4个阶段:
┌─────────────────────────────────────────────────────────────┐
│ ProductToAds_Manual 节点 │
│ │
│ 阶段 1: 产品抓取 (Gemini Flash) │
│ ───────────────────────────────────────── │
│ 抓取产品URL → 提取标题、描述、 │
│ 特性、价格、材质、图片URL │
│ 同时抓取HTML以获取高分辨率产品图片 (≥1000px) │
│ │
│ 阶段 2: 广告简报生成 (Gemini Flash) │
│ ──────────────────────────────────────────────── │
│ 品牌身份 + 产品数据 + 参考 → │
│ 10点广告简报 (创意方向) │
│ │
│ 阶段 3: 蓝图生成 (Gemini Flash) │
│ ────────────────────────────────────────────── │
│ 主提示词 (漏斗阶段) + 简报 + 关键词 → │
│ 可投产的JSON蓝图 │
│ │
│ 阶段 4: 图片生成 (Nano Banana Pro / Imagen 3) │
│ ────────────────────────────────────────────────── │
│ 蓝图 + 所有参考图片 → 最终广告图片 │
│ │
└─────────────────────────────────────────────────────────────┘
阶段 2: 广告简报 (创意大脑)
简报生成器是最关键的中间步骤。它扮演高级艺术总监的角色,使用10点框架将原始数据转化为可执行的创意方向:
- 1. 战略目标 — 此广告活动存在的原因 (认知/定位/发布)
- 核心信息 — 无需文字即可感知的一个想法
- 视觉语调 — 风格:平静/充满活力/亲密/宏大
- 产品角色 — 主角 vs 共同主角 vs 隐含存在
- 视觉语言与品牌一致性 — 不可妥协的品牌代码
- 摄影师与设备 — 摄影作为概念,而非执行
- 扩展艺术指导 — 造型、选角、姿势、发型/化妆、布局
- 环境与背景 — 地点与原因 (概念性,绝不装饰性)
- 纹理、材质与产品渲染 — 表面如何被感知
- 最终图像特征 — 后期处理、颗粒感、时间定位
没有简报,主提示词必须猜测创意策略。有了简报,主提示词只需执行。
简报提示词模板位于{baseDir}/configs/BriefGenerator/briefprompt.json。
阶段 3: 主提示词 (8个漏斗阶段)
每个漏斗阶段都有一个专门的主提示词,用于生成可投产的JSON蓝图。所有提示词共享相同的内部模拟:
- - 第-1轮: 品牌身份取证 (阶段03+) — 统一品牌风格宣言
- 第0轮: 保真度锁定 — 产品几何与模特身份不可更改
- 第1轮: 阶段策略 — 针对漏斗位置的具体策略方法
- 第2轮: 平面设计 — UI、排版、CTA设计
蓝图JSON涵盖:场景制作、模特锁定、相机视角、主体动作/姿势/服装、灯光、产品约束、布局架构、排版、CTA设计以及品牌资产放置。
主提示词文件位于{baseDir}/configs/ProducttoAds/。
参考分析器
参考图片 (referencia) 是可选的,默认关闭。流水线从品牌身份+广告简报内部生成创意方向。仅在用户明确要求克隆特定广告风格时使用参考。
使用时,参考图片会被分析其姿势、摄影风格和地点线索。
⚠️ 关键: 必需输入检查清单
在运行任何广告生成之前,确保已提供以下内容:
| 输入 | 必需? | 如何获取 |
|---|
| --product-url | ✅ 始终 | 用户提供产品页面URL |
| --product-image |
✅ 始终 | 从产品页面下载,或用户提供 |
| --brand-profile | ✅ 绝不为空 | 从目录中选择或先运行品牌分析器。如果已知品牌,绝不留为无品牌 |
| --prompt-profile | ✅ 始终 | 根据广告活动目标选择 |
| --aspect-ratio | 默认: 4:5 | 根据平台需要更改 |
| --model | 🔶 可选 | 模特/人才面孔。有模特的广告表现更好。空值 = 仅产品广告 (无人)。使用时,从~/clawd/models-catalog/catalog/images/中选择 (114个模特可用) |
| --logo | 🔶 可选 | 尝试找到它。如果质量好且易于获取则使用。如果分辨率低或难以找到则跳过。空值 = 绕过 |
| --reference | 🔶 可选 (关闭) | 仅当用户明确要求克隆参考广告时。空值 = 绕过 |
| --creative-brief | 🔶 按需 | 仅当用户给出明确的创意方向时。省略则让流水线从品牌档案自动生成 |
| --language | 🔶 按需 | 仅当用户要求特定语言时。省略则使用默认值 (es) |
🚨 切勿跳过以下步骤:
- 1. 产品图片 — 从产品URL下载主产品照片。抓取器不稳定;始终明确提供产品图片。
- 品牌档案 — 如果品牌在目录中不存在,先运行brand-analyzer技能生成一个。当已知品牌时,切勿提交无品牌。
- 品牌标志 — 尝试找到它 (Clearbit、logo.dev、品牌网站)。如果质量好则使用。如果未找到或分辨率低,则跳过 — 变量接受空字符串 (服务器端绕过)。
- 参考 — 默认不搜索参考。仅在用户明确要求克隆特定广告或说找一个好的广告来克隆时提供。
自动准备工作流程
当用户要求生成广告时:
- 1. 用户提供: 产品URL + 品牌名称 + 目标
- 2. 检查品牌档案是否存在:
→ ls ~/clawd/ad-ready/configs/Brands/ | grep -i {品牌}
→ 如果未找到: 先运行品牌分析器技能
- 3. 下载产品图片:
→ 访问产品URL或获取页面
→ 找到并下载主产品图片
→ 保存到 /tmp/ad-ready-product.jpg
- 4. 下载品牌标志:
→ 搜索{品牌名称} logo PNG或从品牌网站获取
→ 下载清晰的标志图片
→ 保存到 /tmp/ad-ready-logo.png
- 5. 根据目标选择提示词档案:
→ 🎨 Morfeo_Creative: 默认 — 电影感、叙事丰富、略带超现实。最佳视觉效果。
→ Awareness: 品牌发现、动态场景、世界构建、吸引眼球
→ Interest: 持续关注、微世界暗示使用场景
→ Consideration: 功能传达、证明线索、信息丰富
→ Evaluation: 信任、权威、评价、认证
→ Conversion: ⚠️ 按设计最小化 — 简洁、CTA主导、白色背景
→ Retention: 购买后信心、引导入门
→ Loyalty: 编辑风格、生活方式、情感纽带
→ Advocacy: 值得分享、社区、归属感
默认选择逻辑:
- 通用生成广告 → Morfeo_Creative (09)
- 认知 / 品牌发现 → Awareness (01)
- 转化 / 立即购买 / CTA聚焦 → Conversion (05)
- 创意 / 原创 / 超现实 → Morfeo_Creative (09)
- 生活方式 / 编辑风格 → Loyalty (07)
- 不确定时 → Morfeo_Creative (09),而非Conversion
5b. 选择模特 (可选):
→ 如果用户希望广告中有人: 从 ~/clawd/models-catalog/catalog/images/model_XX.jpg 中选择 (114个可用)
→ 如果用户希望仅产品广告 (无人): 将 --model 留空
→ 如果用户未指定: 询问是否需要模特或仅产品
→ 目录预览: catalog.json 位于 ~/clawd/models-catalog/catalog/catalog.json
- 6. 使用所有输入运行生成
使用方法
完整命令 (推荐):
bash
CO