The Recap AI - UGC Ads With Consistent Characters

    Shared 11/13/2025

    245 views

    Visual Workflow

    JSON Code

    {
      "id": "6hBFlv1QdzJfMSeF",
      "meta": {
        "instanceId": "06e5009344f682419c20ccd4ecdcb5223bbb91761882af93ac6d468dbc2cbf8d",
        "templateCredsSetupCompleted": true
      },
      "name": "The Recap AI - UGC Ads With Consistent Characters",
      "tags": [],
      "nodes": [
        {
          "id": "aed37212-7e05-46a8-a3e5-b81381f34529",
          "name": "form_trigger",
          "type": "n8n-nodes-base.formTrigger",
          "position": [
            0,
            0
          ],
          "webhookId": "83a940f8-54f2-46b4-b81d-8069056d1169",
          "parameters": {
            "options": {},
            "formTitle": "UGC Consistent Character Form",
            "formFields": {
              "values": [
                {
                  "fieldLabel": "Sora 2 Character Username",
                  "placeholder": "@olipop.ashley",
                  "requiredField": true
                },
                {
                  "fieldType": "file",
                  "fieldLabel": "Product Image",
                  "multipleFiles": false,
                  "requiredField": true,
                  "acceptFileTypes": ".png"
                },
                {
                  "fieldLabel": "Website Url",
                  "placeholder": "https://gruns.co/",
                  "requiredField": true
                }
              ]
            }
          },
          "typeVersion": 2.3
        },
        {
          "id": "d524a8d8-a1b3-466d-950f-85f625167148",
          "name": "generate_ugc_ad_prompts",
          "type": "n8n-nodes-base.httpRequest",
          "position": [
            1360,
            0
          ],
          "parameters": {
            "url": "https://generativelanguage.googleapis.com/v1beta/models/gemini-2.5-pro:generateContent",
            "method": "POST",
            "options": {},
            "jsonBody": "={\n  \"contents\": [{\n    \"parts\": [\n      { \"text\": {{ JSON.stringify($json.prompt) }} }\n    ]\n  }]\n}",
            "sendBody": true,
            "specifyBody": "json",
            "authentication": "genericCredentialType",
            "genericAuthType": "httpHeaderAuth"
          },
          "credentials": {
            "httpHeaderAuth": {
              "id": "abcMckGk9RG9i0Ba",
              "name": "Google Gemini"
            }
          },
          "retryOnFail": true,
          "typeVersion": 4.2,
          "waitBetweenTries": 5000
        },
        {
          "id": "aac92b54-fdbe-49f4-9e57-a68ea82558f2",
          "name": "build_prompt",
          "type": "n8n-nodes-base.set",
          "position": [
            1104,
            0
          ],
          "parameters": {
            "options": {},
            "assignments": {
              "assignments": [
                {
                  "id": "a4100a8c-1a19-4b66-8690-4867068c2fb4",
                  "name": "prompt",
                  "type": "string",
                  "value": "=<identity>\nYou are an expert AI Creative Director specializing in generating high-impact, direct-response video ads using generative models like SORA. Your task is to translate a creative brief into three distinct, ready-to-use SORA prompts for short, UGC-style video ads.\n</identity>\n\n<core_task>\nFirst, analyze the provided **Creative Brief**, including the raw text and product image, to synthesize the product's core message and visual identity. Then, for each of the three **UGC Ad Archetypes**, generate a **Prompt Packet** according to the specified **Output Format**. All generated content must strictly adhere to both the **SORA Prompting Guide** and the **Core Directives**.\n</core_task>\n\n<output_format>\nFor each of the three archetypes, you must generate a complete \"Prompt Packet\" using the following markdown structure:\n\n---\n### **[Archetype Name]**\n\n**SORA Prompt:**\n[Insert the generated SORA prompt text here.]\n\n**Production Notes:**\n*   **Camera:** The entire scene must be filmed to look as if it were shot on an iPhone in a vertical 9:16 aspect ratio. The style must be authentic UGC, not cinematic.\n*   **Audio:** Any spoken dialogue described in the prompt must be accurately and naturally lip-synced by the protagonist (`@username`).\n*   **Product Scale & Fidelity:** The product's appearance, particularly its scale and proportions, must be rendered with high fidelity to the provided product image. Ensure it looks true-to-life in the hands of the protagonist and within the scene's environment.\n---\n</output_format>\n\n<creative_brief>\nYou will be provided with the following inputs:\n\n1.  **Raw Website Content:** [User will insert scraped, markdown-formatted content from the product's homepage. You must analyze this to extract the core value proposition, key features, and target audience.]\n2.  **Product Image:** [User will insert the product image for visual reference.]\n3.  **Protagonist:** [User will insert the @username of the character to be featured.]\n4.  **SORA Prompting Guide:** [User will insert the official prompting guide for the SORA 2 model, which you must follow.]\n</creative_brief>\n\n<ugc_ad_archetypes>\n1.  **The On-the-Go Testimonial (Walk-and-talk)**\n2.  **The Driver's Seat Review**\n3.  **The At-Home Demo**\n</ugc_ad_archetypes>\n\n<core_directives>\n1.  **iPhone Production Aesthetic:** This is a non-negotiable constraint. All SORA prompts must explicitly describe a scene that is **shot entirely on an iPhone**. The visual language should be authentic to this format. Use specific descriptors such as: \"selfie-style perspective shot on an iPhone,\" \"vertical 9:16 aspect ratio,\" \"crisp smartphone video quality,\" \"natural lighting,\" and \"slight, realistic handheld camera shake.\"\n2.  **Tone & Performance:** The protagonist's energy must be high and their delivery authentic, enthusiastic, and conversational. The feeling should be a genuine recommendation, not a polished advertisement.\n3.  **Timing & Pacing:** The total video duration described in the prompt must be approximately 15 seconds. Crucially, include a 1-2 second buffer of ambient, non-dialogue action at both the beginning and the end.\n4.  **Clarity & Focus:** Each prompt must be descriptive, evocative, and laser-focused on a single, clear scene. The protagonist (`@username`) must be the central figure, and the product, matching the provided **Product Image**, should be featured clearly and positively.\n5.  **Brand Safety & Content Guardrails:** All generated prompts and the scenes they describe must be strictly PG and family-friendly. Avoid any suggestive, controversial, or inappropriate language, visuals, or themes. The overall tone must remain positive, safe for all audiences, and aligned with a mainstream brand image.\n</core_directives>\n\n<protagonist_username>\n{{ $node['form_trigger'].json['Sora 2 Character Username'] }}\n</protagonist_username>\n\n<product_home_page>\n{{ $node['scrape_home_page'].json.data.markdown }}\n</product_home_page>\n\n<sora2_prompting_guide>\n{{ $node['scrape_sora2_prompting_guide'].json.data.markdown }}\n</sora2_prompting_guide>"
                }
              ]
            }
          },
          "typeVersion": 3.4
        },
        {
          "id": "cbd1046a-f3ef-4c57-8ffe-b3bdafe41955",
          "name": "scrape_home_page",
          "type": "@mendable/n8n-nodes-firecrawl.firecrawl",
          "position": [
            544,
            0
          ],
          "parameters": {
            "url": "={{ $node['form_trigger'].json['Website Url'] }}",
            "operation": "scrape",
            "scrapeOptions": {
              "options": {
                "formats": {
                  "format": [
                    {}
                  ]
                },
                "headers": {}
              }
            },
            "requestOptions": {}
          },
          "credentials": {
            "firecrawlApi": {
              "id": "tTXd52Qm4ZR6N7sq",
              "name": "Firecrawl"
            }
          },
          "typeVersion": 1
        },
        {
          "id": "cd5c4fe0-493a-48df-b2c6-6d84a1bd30f2",
          "name": "scrape_sora2_prompting_guide",
          "type": "@mendable/n8n-nodes-firecrawl.firecrawl",
          "position": [
            816,
            0
          ],
          "parameters": {
            "url": "=https://cookbook.openai.com/examples/sora/sora2_prompting_guide",
            "operation": "scrape",
            "scrapeOptions": {
              "options": {
                "formats": {
                  "format": [
                    {}
                  ]
                },
                "headers": {}
              }
            },
            "requestOptions": {}
          },
          "credentials": {
            "firecrawlApi": {
              "id": "tTXd52Qm4ZR6N7sq",
              "name": "Firecrawl"
            }
          },
          "typeVersion": 1
        },
        {
          "id": "1a69d2d9-3bb0-468f-8a6b-0465990b9edf",
          "name": "extract_sora2_prompts",
          "type": "@n8n/n8n-nodes-langchain.chainLlm",
          "position": [
            1616,
            0
          ],
          "parameters": {
            "text": "=Please extract the full three prompts for generating AI video ads from the provided text. Please include production notes for each prompt. Each full prompt will be separated by `---` so include the contents between each.\n\n{{ $json.candidates[0].content.parts[0].text }}",
            "batching": {},
            "promptType": "define",
            "hasOutputParser": true
          },
          "typeVersion": 1.7
        },
        {
          "id": "fca04c0a-4268-44dd-af43-2e936d568b7f",
          "name": "gemini-2.5-pro",
          "type": "@n8n/n8n-nodes-langchain.lmChatGoogleGemini",
          "position": [
            1616,
            624
          ],
          "parameters": {
            "options": {},
            "modelName": "models/gemini-2.5-pro"
          },
          "credentials": {
            "googlePalmApi": {
              "id": "qp1NlMiIctmGD0Uu",
              "name": "Google Gemini (PaLM)"
            }
          },
          "typeVersion": 1
        },
        {
          "id": "eae4cf97-2be8-4b42-bd64-3aca2d4038df",
          "name": "video-prompts-parser",
          "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
          "position": [
            1680,
            256
          ],
          "parameters": {
            "autoFix": true,
            "schemaType": "manual",
            "inputSchema": "{\n\t\"type\": \"object\",\n\t\"properties\": {\n\t\t\"prompts\": {\n\t\t\t\"type\": \"array\",\n\t\t\t\"items\": {\n\t\t\t\t\"type\": \"string\",\n                \"description\": \"An individual UGC video ad prompt to be provided to an AI video generator\"\n\t\t\t}\n\t\t}\n\t}\n}"
          },
          "typeVersion": 1.3
        },
        {
          "id": "7f657cec-e252-4be0-8718-d31872cbd6cb",
          "name": "split_prompts",
          "type": "n8n-nodes-base.splitOut",
          "position": [
            2016,
            0
          ],
          "parameters": {
            "options": {},
            "fieldToSplitOut": "output.prompts"
          },
          "typeVersion": 1
        },
        {
          "id": "ff62cf18-6530-4e8c-a486-51f7eaa4e24f",
          "name": "iterate_prompts",
          "type": "n8n-nodes-base.splitInBatches",
          "position": [
            0,
            336
          ],
          "parameters": {
            "options": {}
          },
          "typeVersion": 3
        },
        {
          "id": "5d9b0407-5ca2-4bac-a34e-87522b06c77f",
          "name": "generate_video",
          "type": "n8n-nodes-base.httpRequest",
          "position": [
            288,
            352
          ],
          "parameters": {
            "url": "https://api.kie.ai/api/v1/jobs/createTask",
            "method": "POST",
            "options": {},
            "jsonBody": "={\n  \"model\": \"sora-2-pro-image-to-video\",\n  \"input\": {\n    \"prompt\": {{ JSON.stringify($json['output.prompts']) }},\n    \"image_urls\": [\n      \"{{ $node['upload_image'].json.data.url }}\"\n    ], \n    \"size\": \"standard\",\n    \"aspect_ratio\": \"portrait\",\n    \"n_frames\": \"15\",\n    \"remove_watermark\": true\n  }\n}",
            "sendBody": true,
            "specifyBody": "json",
            "authentication": "genericCredentialType",
            "genericAuthType": "httpHeaderAuth"
          },
          "credentials": {
            "httpHeaderAuth": {
              "id": "X7Ie31bIzoAaVoj1",
              "name": "Kie AI API"
            }
          },
          "typeVersion": 4.3
        },
        {
          "id": "b37edeaf-49c1-4b44-8fba-89f2b2e5ef51",
          "name": "wait",
          "type": "n8n-nodes-base.wait",
          "position": [
            544,
            352
          ],
          "webhookId": "4fe28b03-40c5-4523-bf47-6ac182561d9f",
          "parameters": {
            "amount": 10
          },
          "typeVersion": 1.1
        },
        {
          "id": "0b396aca-be2e-41d9-9ff9-b6270c6b45dc",
          "name": "get_status",
          "type": "n8n-nodes-base.httpRequest",
          "position": [
            816,
            352
          ],
          "parameters": {
            "url": "https://api.kie.ai/api/v1/jobs/recordInfo",
            "options": {},
            "sendQuery": true,
            "authentication": "genericCredentialType",
            "genericAuthType": "httpHeaderAuth",
            "queryParameters": {
              "parameters": [
                {
                  "name": "taskId",
                  "value": "={{ $node['generate_video'].json.data.taskId }}"
                }
              ]
            }
          },
          "credentials": {
            "httpHeaderAuth": {
              "id": "X7Ie31bIzoAaVoj1",
              "name": "Kie AI API"
            }
          },
          "typeVersion": 4.3
        },
        {
          "id": "94ae1815-30b6-47ce-9737-87636b70540a",
          "name": "switch_status",
          "type": "n8n-nodes-base.switch",
          "position": [
            1104,
            368
          ],
          "parameters": {
            "rules": {
              "values": [
                {
                  "outputKey": "success",
                  "conditions": {
                    "options": {
                      "version": 2,
                      "leftValue": "",
                      "caseSensitive": true,
                      "typeValidation": "strict"
                    },
                    "combinator": "and",
                    "conditions": [
                      {
                        "id": "e96b9197-f90e-4dc6-903a-cd3b908f175c",
                        "operator": {
                          "type": "string",
                          "operation": "equals"
                        },
                        "leftValue": "={{ $json.data.state }}",
                        "rightValue": "success"
                      }
                    ]
                  },
                  "renameOutput": true
                },
                {
                  "outputKey": "generating",
                  "conditions": {
                    "options": {
                      "version": 2,
                      "leftValue": "",
                      "caseSensitive": true,
                      "typeValidation": "strict"
                    },
                    "combinator": "and",
                    "conditions": [
                      {
                        "id": "d0020e71-3860-4069-a2ac-1c10245b5c85",
                        "operator": {
                          "name": "filter.operator.equals",
                          "type": "string",
                          "operation": "equals"
                        },
                        "leftValue": "={{ $json.data.state }}",
                        "rightValue": "generating"
                      }
                    ]
                  },
                  "renameOutput": true
                },
                {
                  "outputKey": "fail",
                  "conditions": {
                    "options": {
                      "version": 2,
                      "leftValue": "",
                      "caseSensitive": true,
                      "typeValidation": "strict"
                    },
                    "combinator": "and",
                    "conditions": [
                      {
                        "id": "48a71f7c-b1d7-4c65-87e1-526a86105f0c",
                        "operator": {
                          "name": "filter.operator.equals",
                          "type": "string",
                          "operation": "equals"
                        },
                        "leftValue": "={{ $json.data.state }}",
                        "rightValue": "fail"
                      }
                    ]
                  },
                  "renameOutput": true
                }
              ]
            },
            "options": {}
          },
          "typeVersion": 3.3
        },
        {
          "id": "ba98920e-f19e-4c73-a2e4-2d33c13e21cb",
          "name": "upload_image",
          "type": "n8n-nodes-base.httpRequest",
          "position": [
            288,
            0
          ],
          "parameters": {
            "url": "https://tmpfiles.org/api/v1/upload",
            "method": "POST",
            "options": {},
            "sendBody": true,
            "contentType": "multipart-form-data",
            "bodyParameters": {
              "parameters": [
                {
                  "name": "file",
                  "parameterType": "formBinaryData",
                  "inputDataFieldName": "Product_Image"
                }
              ]
            }
          },
          "typeVersion": 4.3
        },
        {
          "id": "bb89c281-7351-472e-8544-5449a47e76c6",
          "name": "upload_result_video",
          "type": "n8n-nodes-base.googleDrive",
          "position": [
            2016,
            416
          ],
          "parameters": {
            "name": "=UGC Ad #{{ $runIndex + 1 }}",
            "driveId": {
              "__rl": true,
              "mode": "list",
              "value": "My Drive",
              "cachedResultUrl": "https://drive.google.com/drive/my-drive",
              "cachedResultName": "My Drive"
            },
            "options": {},
            "folderId": {
              "__rl": true,
              "mode": "url",
              "value": "https://drive.google.com/drive/u/0/folders/1jrUIQPciYsgzXrtTAqTlhbNtAGF55-GH"
            }
          },
          "credentials": {
            "googleDriveOAuth2Api": {
              "id": "PgwI1k1VFnoEhOi6",
              "name": "Google Drive account"
            }
          },
          "typeVersion": 3
        },
        {
          "id": "597718c1-0cd5-4e12-8ea0-aeff1278111a",
          "name": "Sticky Note",
          "type": "n8n-nodes-base.stickyNote",
          "position": [
            -80,
            -96
          ],
          "parameters": {
            "color": 4,
            "width": 2304,
            "height": 848,
            "content": "## Sora 2 UGC Consistent Character Video Ad Generator"
          },
          "typeVersion": 1
        },
        {
          "id": "f9039f88-7098-4dec-bc5c-350e80feb4c3",
          "name": "download_video",
          "type": "n8n-nodes-base.httpRequest",
          "position": [
            1360,
            352
          ],
          "parameters": {
            "url": "={{ $json.resultJson.resultUrls.first() }}",
            "options": {}
          },
          "typeVersion": 4.2
        }
      ],
      "active": false,
      "pinData": {},
      "settings": {
        "executionOrder": "v1"
      },
      "versionId": "5bdcc93a-b69d-41dd-8fe1-4fd903a80ce6",
      "connections": {
        "wait": {
          "main": [
            [
              {
                "node": "get_status",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "get_status": {
          "main": [
            [
              {
                "node": "switch_status",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "build_prompt": {
          "main": [
            [
              {
                "node": "generate_ugc_ad_prompts",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "form_trigger": {
          "main": [
            [
              {
                "node": "upload_image",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "upload_image": {
          "main": [
            [
              {
                "node": "scrape_home_page",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "split_prompts": {
          "main": [
            [
              {
                "node": "iterate_prompts",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "switch_status": {
          "main": [
            [
              {
                "node": "download_video",
                "type": "main",
                "index": 0
              }
            ],
            [
              {
                "node": "wait",
                "type": "main",
                "index": 0
              }
            ],
            [
              {
                "node": "iterate_prompts",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "download_video": {
          "main": [
            [
              {
                "node": "upload_result_video",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "gemini-2.5-pro": {
          "ai_languageModel": [
            [
              {
                "node": "extract_sora2_prompts",
                "type": "ai_languageModel",
                "index": 0
              },
              {
                "node": "video-prompts-parser",
                "type": "ai_languageModel",
                "index": 0
              }
            ]
          ]
        },
        "generate_video": {
          "main": [
            [
              {
                "node": "wait",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "iterate_prompts": {
          "main": [
            [],
            [
              {
                "node": "generate_video",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "scrape_home_page": {
          "main": [
            [
              {
                "node": "scrape_sora2_prompting_guide",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "upload_result_video": {
          "main": [
            [
              {
                "node": "iterate_prompts",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "video-prompts-parser": {
          "ai_outputParser": [
            [
              {
                "node": "extract_sora2_prompts",
                "type": "ai_outputParser",
                "index": 0
              }
            ]
          ]
        },
        "extract_sora2_prompts": {
          "main": [
            [
              {
                "node": "split_prompts",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "generate_ugc_ad_prompts": {
          "main": [
            [
              {
                "node": "extract_sora2_prompts",
                "type": "main",
                "index": 0
              }
            ]
          ]
        },
        "scrape_sora2_prompting_guide": {
          "main": [
            [
              {
                "node": "build_prompt",
                "type": "main",
                "index": 0
              }
            ]
          ]
        }
      }
    }