ChatGPT创意视频AI 评分 · 74/100AI 辅助编辑·未发现明显提示词注入风险n8n.io

用 n8n 自动生成 UGC 视频广告:从 Google Sheets 产品图到 Kie.ai Sora 2

输入产品名称、提示词与图片链接 → AI Agent 结合 Tavily 研究生成视频提示词 → Kie.ai Sora 2 输出 10 秒竖屏广告 → 回写 Google Sheets

有一点经验步骤流程提示词贴士
给谁
电商运营、UGC 营销人员、AI 自动化自由职业者、希望批量生成短视频广告的产品团队
你会得到
在 Google Sheets 中填入产品信息后,一键触发 n8n 工作流,自动研究趋势、生成优化提示词、调用 Kie.ai Sora 2 生成 10 秒无水印竖屏视频,并将结果链接写回表格
你需要
n8n · google-sheets · tavily · kie.ai

硬约束

前置条件:n8n Cloud 或自托管实例;Google Sheets OAuth 2.0 凭证;OpenAI API Key;Tavily Search API(Header Auth);Kie.ai Sora 2 API(Header Auth)。Google Sheets 需包含列:ID、Product Name、Prompt、Image Link、Video Link、Processed。费用:OpenAI 按 token 计费,Kie.ai 与 Tavily 按各自平台定价,来源未提供具体金额。执行方式:手动触发,每次处理一行未处理数据。

他们做了什么

作者 kingsley 在 n8n 官方模板平台发布了一个工作流模板,将 Google Sheets 作为产品信息 CRM,通过 AI Agent(OpenAI gpt-4.1-mini)结合 Tavily 搜索研究产品趋势,自动生成针对 Kie.ai Sora 2 的详细视频提示词,再调用 Kie.ai API 生成 10 秒竖屏无水印视频,最后将结果回写 Google Sheets 并标记处理状态。工作流包含手动触发、错误处理(500 错误捕获)与循环等待机制。

效果如何

作者自述该工作流可自动生成 10 秒 UGC 风格竖屏视频广告,输出无水印视频链接,并能自动处理重试与错误跟踪(author_report)。模板在 n8n.io 上获得一定浏览量,但未提供第三方质量评测或 ROI 数据。

值得知道

1. 提示词可修改:sticky note 明确说明 AI Agent 的 system prompt 可根据业务目标调整。2. 图片链接处理:Create Video 节点对 Google Drive 分享链接做了自动提取 ID 转直链的处理,但非 Drive 链接会原样传入,需自行确保可访问。3. 节点名称不一致:workflow.json 中 Error Message 节点引用 $('Grab Ffff'),而实际节点名为 Grab Video,导入后建议核对并修正。4. 轮询间隔固定为 15 秒,若 Kie.ai 生成时间更长可能需要多次循环;来源未说明最大重试次数。5. 来源未提供 Kie.ai Sora 2 与 Tavily 的具体定价、速率限制及可用区域,使用前需自行确认。

n8n 工作流模板

结构已检查 · 未实际运行

下载后在 n8n 选择“Import from File”,或复制 JSON 后粘贴到编辑器。先配置自己的账号,再用测试数据运行;模板默认未启用。

配置与测试清单

需要绑定的凭证

  • Get row(s) in sheet 节点:绑定Google Sheets OAuth2 凭证。
  • OpenAI Chat Model 节点:绑定OpenAI API 凭证。
  • Tavily 节点:绑定HTTP Header Auth 凭证。
  • Append or update row in sheet 节点:绑定Google Sheets OAuth2 凭证。
  • Create Video 节点:绑定HTTP Header Auth 凭证。
  • Grab Video 节点:绑定HTTP Header Auth 凭证。

需要替换的配置

  • 源模板来自 n8n 公开库 #10536(约 20 个节点)。导入后先保持未启用,核对触发器、表达式与外部 API 端点。
  • Sticky Note 中的说明仅供参考;按自己的账号、表结构或频道 ID 替换占位配置。

测试输入与预期结果

  • 在测试环境手动执行一次主路径,确认每个需凭证的节点已连接且无鉴权错误。
  • 用一条合成/脱敏样例数据跑通,核对输出字段与下游写入目标,再考虑生产启用。

模板处理说明

  • 已移除原作者凭证绑定、webhookId 与执行数据,工作流设为未启用;节点、连线与原文提示词保持原样。未在 n8n 中实际运行。
  • 未改业务逻辑;运行前请自行核对密钥、配额与隐私合规。

模板获取日期: 2026-10-24

步骤

  1. 准备 Google Sheets 与产品数据

    创建或打开一个 Google Sheets,确保包含以下列:ID、Product Name、Prompt、Image Link、Video Link、Processed。在各行填入产品名称、简短提示词或创意、产品图片链接,并将 Processed 列留空或设为 No,以便工作流识别未处理行。

  2. 配置凭证与 Header Auth

    在 n8n 中创建并连接以下凭证: - Google Sheets OAuth 2.0 - OpenAI API Key - Tavily Search API:使用 Generic Credential Type → Header Auth,Name 填 Authorization,Value 填 Bearer YOUR_TAVILY_TOKEN - Kie.ai Sora 2 API:同样使用 Header Auth,Name 填 Authorization,Value 填 Bearer YOUR_KIEAI_TOKEN 将上述凭证分别绑定到对应节点。

  3. 导入工作流并绑定表格

    下载模板 workflow JSON 并导入 n8n。打开 'Get row(s) in sheet' 与 'Append or update row in sheet' 节点,将 documentId 和 sheetName 替换为你自己的 Google Sheets ID 与工作表名称。确认节点中映射的列名与表格一致。

  4. 执行工作流:读取未处理产品行

    点击 'Execute Workflow' 手动触发。工作流从 Google Sheets 中查找 Processed 列为空/No 的首行,读取 Product Name、Prompt、Image Link 等字段,传入后续节点。

  5. AI Agent 生成视频提示词(调用 Tavily 研究)

    AI Agent 节点接收产品信息,先调用 Tavily 搜索该产品类别的最新趋势与营销洞察,再结合 OpenAI Chat Model(gpt-4.1-mini)生成详细的 Sora 2 视频提示词。提示词涵盖主体外观、场景、镜头风格、情绪基调与灯光。

    运行提示词 · 来源原文。AI Agent 节点的 System Message 字段

    =You are an expert AI video prompt engineer trained to design optimized prompts for Sora 2 video generation on Kie.ai.
    Your role is to take a raw product concept, a short idea, and an image link and transform them into a highly detailed, realistic, and visually rich video prompt that aligns with modern marketing standards.
    
    
    🎯 Objective
    Generate a prompt that helps Sora 2 produce a realistic, natural-looking short video matching the intent of the product or service.
    The result should look like it was filmed by a real person or a professional ad team — depending on the desired style.
    
    
    🧩 Your Rules
    1. Before generating the video prompt, always use the Tavily tool to search for the latest trends, product type, related products or categories, and current market insights of the product or product category. Use this information to ensure the video prompt reflects the most current and effective styles in video advertising, avoiding outdated approaches.
    2. Understand the product — analyze what it is, who it’s for, and its emotional appeal (use any research insight provided).
    3. Always describe:
    - Main subject(s): appearance, clothing, expression, action.
    - Setting: location, lighting, time of day, atmosphere.
    - Camera style: framing, motion, handheld vs cinematic, lens type, realism.
    - Tone: emotional mood (friendly, elegant, cinematic, testimonial, etc.).
    - Lighting: realistic natural or studio lighting, with mood consistency.
    4. If the user specifies “UGC” or “influencer-style”, simulate a smartphone or handheld camera perspective, vertical 9:16 format, and a natural, authentic tone.
    5. If no style is specified, default to a cinematic ad style that looks visually stunning and brand-ready.
    6. Avoid repetition, keep every sentence meaningful, and ensure the description reads like a cinematographer describing the shot to a director.
  6. 调用 Kie.ai Sora 2 生成视频

    'Create Video' 节点将 AI Agent 生成的提示词与产品图片一并发送至 Kie.ai API(https://api.kie.ai/api/v1/jobs/createTask)。请求参数包括:model 为 sora-2-image-to-video、aspect_ratio 为 portrait、n_frames 为 10、remove_watermark 为 true。图片链接若含 Google Drive 分享格式,节点会自动提取文件 ID 转为直链。

  7. 等待并轮询获取视频结果

    工作流通过 Wait 节点暂停 15 秒,随后 'Grab Video' 节点用 taskId 查询 Kie.ai 任务状态。Switch 节点判断返回状态: - success → 提取视频链接继续 - 500 错误 → 记录错误信息 - 仍在处理 → 循环回到 Wait 节点再次等待

  8. 回写 Google Sheets 并标记完成

    成功获取视频后,'Edit Fields' 节点从 resultJson 中提取无水印视频链接,'Append or update row in sheet' 节点将 Video Link 与 Processed = Yes 写回原行,完成单次处理。

可复制提示词

搭建指导 · 本站建议版本。交给搭建助手,先确认输入和权限

这一段是提示词,页面不会在这里插入广告。

你正在搭建一个 n8n 工作流,用于从 Google Sheets 产品数据自动生成 UGC 风格短视频广告。请先确认你已准备好:n8n 实例、包含指定列的 Google Sheets、Google Sheets OAuth 2.0 凭证、OpenAI API Key、Tavily API Key(Header Auth)、Kie.ai Sora 2 API Key(Header Auth)。然后按步骤导入工作流、替换表格 ID、绑定凭证,最后手动执行测试一行数据。

执行前请检查 Error Message 节点引用的节点名称是否与你的 Grab Video 节点名称一致;若不一致需手动修正。

来源

Generate UGC video ads from product images with Kie.ai Sora 2 + Tavily Research · kingsley · n8n.io · 2025-11-05

留言与反馈

试过这个方法吗?分享效果、遇到的问题或改进建议。留言审核后公开,请勿填写敏感信息。

正在加载…

    相关用例