当前位置: 首页 > Skill >

Cinematic Kling

Cinematic Kling

Cinematic Kling

Generate 5-second cinematic AI videos using Kling via ComfyDeploy. Takes a character image, item image, and location image, then produces a character sheet,...

1.0.2 2026.11.26 872
获取Skill文件查看使用说明
作 者:叶言 许可证: 更新时间:2026.11.26
本文目录展开

Cinematic Kling

Generates a 5-second cinematic video by combining:

  • A character (person/model)
  • An item (product, object, prop)
  • A location (background, environment)

Internally creates a Character Sheet and Item Sheet, then feeds them into Kling for video generation.

Deployment

  • Deployment ID: e5258667-dec2-438f-84d0-f22049692483
  • API: POST https://api.comfydeploy.com/api/run/deployment/queue
  • Auth: Authorization: Bearer $COMFY_DEPLOY_API_KEY

Inputs

Field Type Description
character_base URL Public image URL of the character/person
item_base URL Public image URL of the item/product
location_base URL Public image URL of the location/environment
character_sheet_prompt String Character sheet prompt — only modify the [brackets]
video_prompt String Simple description of the 5-second scene
input_seed Integer -1 for random, fixed number for reproducible results

Character Sheet Prompt Structure

The prompt has two parts — only the [brackets] part changes:

Create a photorealistic character sheet. Include a closeup portrait which is left aligned (the outfit must be visible in the portrait), no borders, with a neutral expression and then also include a full view shot that shows the front, right side view, left side view and back of the character. The character is placed on a white background. Don't include any text. No borders, no soft gradients. [CLOTHING DESCRIPTION HERE]

Rule: Replace [CLOTHING DESCRIPTION HERE] with the outfit appropriate for the scene. Everything before the brackets stays exactly as-is.

Examples:

  • [They are wearing a tailored black suit with a white shirt, no tie, luxury editorial style.]
  • [They are wearing dirty damaged clothes in the style of The Last Of Us, dystopic aesthetic.]
  • [They are wearing a red Nike tracksuit and white sneakers, athletic style.]

Video Prompt Guidelines

  • Keep it simple — describe the action/interaction, not every detail
  • Mention character + item + location implicitly through the action
  • You can suggest 1-2 camera cuts within the 5 seconds
  • Works for: ads, short films, music videos, product demos, action clips

Good examples:

  • "Short cinematic sequence of the character dunking a basketball in the ring while wearing the green Shaq shoes."
  • "Character walks into the desert location, picks up the item from the sand, holds it toward camera. Quick cut to close-up of the item."
  • "Product reveal: character turns around in the urban location, tosses the item to camera in slow motion."

Bad (too detailed):

  • ❌ "Camera starts at f/1.8 aperture, golden hour light at 47 degrees, character moves exactly 3 steps forward..."

Step 0 — Verify Which Image Is Which (MANDATORY)

ALWAYS use the image tool to identify each file before assigning roles. Never assume by order.

image(images=[file1, file2, file3], prompt="Para cada imagen, decí brevemente si es: persona, producto/objeto, o lugar/ambiente")

Then assign:

  • character_base = the person/model
  • item_base = the product/object they interact with
  • location_base = the place/environment/background

Step 1 — Upload Images to ComfyDeploy Storage

ALWAYS upload local files to ComfyDeploy's own storage first. NEVER use external/custom domains.

source ~/clawd/.env

upload_to_comfy() {
  curl -s -X POST "https://api.comfydeploy.com/api/file/upload" 
    -H "Authorization: Bearer $COMFY_DEPLOY_API_KEY" 
    -F "file=@$1" | jq -r '.file_url'
}

URL_CHAR=$(upload_to_comfy /path/to/character.jpg)
URL_ITEM=$(upload_to_comfy /path/to/item.jpg)
URL_LOC=$(upload_to_comfy /path/to/location.jpg)
# Returns: https://comfy-deploy-output.s3.us-east-2.amazonaws.com/inputs/img_XXXX.jpg

Step 2 — Submit Run

RUN_ID=$(curl -s -X POST "https://api.comfydeploy.com/api/run/deployment/queue" 
  -H "Content-Type: application/json" 
  -H "Authorization: Bearer $COMFY_DEPLOY_API_KEY" 
  -d "{
    "deployment_id": "e5258667-dec2-438f-84d0-f22049692483",
    "inputs": {
      "character_base": "$URL_CHAR",
      "item_base": "$URL_ITEM",
      "location_base": "$URL_LOC",
      "character_sheet_prompt": "Create a photorealistic character sheet. Include a closeup portrait which is left aligned (the outfit must be visible in the portrait), no borders, with a neutral expression and then also include a full view shot that shows the front, right side view, left side view and back of the character. The character is placed on a white background. Don't include any text. No borders, no soft gradients. [CLOTHING DESCRIPTION]",
      "video_prompt": "VIDEO_SCENE_DESCRIPTION",
      "input_seed": -1
    }
  }" | jq -r '.run_id')

echo "Run ID: $RUN_ID"

Polling for Results

while true; do
  RESULT=$(curl -s "https://api.comfydeploy.com/api/run/$RUN_ID" 
    -H "Authorization: Bearer $COMFY_DEPLOY_API_KEY")
  STATUS=$(echo $RESULT | jq -r '.status')
  echo "Status: $STATUS"
  if [ "$STATUS" = "success" ]; then
    echo $RESULT | jq '.outputs'
    break
  elif [ "$STATUS" = "failed" ]; then
    echo "Failed!"
    break
  fi
  sleep 10
done

Step 3 — Poll & Download Results

# Poll until success
while true; do
  RESULT=$(curl -s "https://api.comfydeploy.com/api/run/$RUN_ID" 
    -H "Authorization: Bearer $COMFY_DEPLOY_API_KEY")
  STATUS=$(echo $RESULT | jq -r '.status')
  [ "$STATUS" = "success" ] && break
  [ "$STATUS" = "failed" ] && echo "FAILED" && break
  sleep 15
done

# Download outputs to allowed directory
mkdir -p ~/clawd/output/cinematic-kling
BASE_URL="https://comfy-deploy-output.s3.us-east-2.amazonaws.com/outputs/runs/$RUN_ID"
curl -sL "$BASE_URL/CS_2_00001_.png" -o ~/clawd/output/cinematic-kling/character-sheet.png
curl -sL "$BASE_URL/ITEM_00001_.png" -o ~/clawd/output/cinematic-kling/item-sheet.png
curl -sL "$BASE_URL/LOCATION_00001_.png" -o ~/clawd/output/cinematic-kling/location-sheet.png
curl -sL "$BASE_URL/ComfyUI_00001_.mp4" -o ~/clawd/output/cinematic-kling/video.mp4

Step 4 — Send Results as Files

ALWAYS send as file attachments using filePath — NEVER send raw URLs.

message(action=send, channel=telegram, target=USER_ID, filePath=~/clawd/output/cinematic-kling/character-sheet.png, message="Character Sheet")
message(action=send, channel=telegram, target=USER_ID, filePath=~/clawd/output/cinematic-kling/item-sheet.png, message="Item Sheet")
message(action=send, channel=telegram, target=USER_ID, filePath=~/clawd/output/cinematic-kling/location-sheet.png, message="Location Sheet")
message(action=send, channel=telegram, target=USER_ID, filePath=~/clawd/output/cinematic-kling/video.mp4, message="🎬 Video")

Output Structure

Node File Action
4 CS_2_00001_.png Send as file (Character Sheet)
14 ITEM_00001_.png Send as file (Item Sheet)
25 LOCATION_00001_.png Send as file (Location Sheet)
22 ComfyUI_00001_.mp4 Send as file — main output
38 text Internal video prompt used by Kling (ignore)

Python Helper

import requests, os, time

def cinematic_kling(character_url, item_url, location_url, clothing_desc, video_prompt, seed=-1):
    """
    character_url: public URL of character image
    item_url: public URL of item image
    location_url: public URL of location image
    clothing_desc: description for [brackets] in character sheet prompt
    video_prompt: simple scene description
    Returns: dict with 'images' list and 'video' URL
    """
    API_KEY = os.environ['COMFY_DEPLOY_API_KEY']
    
    character_sheet_prompt = (
        "Create a photorealistic character sheet. Include a closeup portrait which is left aligned "
        "(the outfit must be visible in the portrait), no borders, with a neutral expression and then "
        "also include a full view shot that shows the front, right side view, left side view and back "
        "of the character. The character is placed on a white background. Don't include any text. "
        f"No borders, no soft gradients. [{clothing_desc}]"
    )
    
    # Submit job
    r = requests.post(
        "https://api.comfydeploy.com/api/run/deployment/queue",
        headers={"Content-Type": "application/json", "Authorization": f"Bearer {API_KEY}"},
        json={
            "deployment_id": "e5258667-dec2-438f-84d0-f22049692483",
            "inputs": {
                "character_base": character_url,
                "item_base": item_url,
                "location_base": location_url,
                "character_sheet_prompt": character_sheet_prompt,
                "video_prompt": video_prompt,
                "input_seed": seed
            }
        }
    )
    run_id = r.json()['run_id']
    print(f"Run ID: {run_id}")
    
    # Poll
    while True:
        result = requests.get(
            f"https://api.comfydeploy.com/api/run/{run_id}",
            headers={"Authorization": f"Bearer {API_KEY}"}
        ).json()
        status = result.get('status')
        print(f"Status: {status}")
        if status == 'success':
            return result.get('outputs', {})
        elif status == 'failed':
            raise Exception(f"Run failed: {result}")
        time.sleep(10)

Typical Run Time

~3–5 minutes (character sheet generation + Kling video generation)

Use Cases

  • Product ads: character using/wearing the item in a branded location
  • Short films: character interacting with a prop in a cinematic environment
  • Music videos: artist + instrument/prop + stage/location
  • Fashion: model wearing clothing item in a specific setting
  • Gaming/dystopian: character in Last-of-Us style with game item in post-apocalyptic location

Notes

  • The character_sheet_prompt fixed portion must never be modified — only the [brackets]
  • input_seed: -1 = random each time; set a fixed integer to reproduce results
  • 5 seconds is the fixed video length
  • Outputs come from ComfyDeploy's built-in S3 storage — no manual upload needed

推荐文章

更多
PHP时间戳与日期字符串相互转换方法详解

本文介绍PHP中时间数值(Unix时间戳)与日期字符串之间的相互转换方法。通过strtotime和date函数,实现将当前时间、指定日期转换为时间戳,以及将时间戳格式化为可读的日期时间字符串,并提供相关在线计算工具推荐。

2025.11.30 1,016
PHP跨域配置:怎么安全地允许指定域名而非使用通配符

在 PHP 中安全地允许指定域名跨域,核心是解析请求头中的 Origin ,验证其是否在白名单内,然后动态设置 Access-Control-Allow-Origin 响应头。不要使用通配符 * ,也不要硬编码单一域名。

2025.03.29 1,004
JavaScript中利用replace结合正则实现replaceAll效果

JavaScript原生仅支持replace()进行单次或全局替换,缺乏类似Java的replaceAll()便捷方法。本文总结四种在JS中实现全量替换的方案:使用带g标志的正则、带gm标志的正则、扩展String原型以及split后join。通过对比代码示例,展示各方法的实现细节与适用场景,帮助开发者根据需求选择最优解。

2025.04.29 1,002
PHP日期转时间戳时区偏差怎么解决

在 PHP 中将日期字符串转换为时间戳时,若未显式指定时区,默认使用脚本配置的 date.timezone 或系统时区。当服务器时区与业务逻辑预期(如 UTC )不一致时,会产生偏差。解决核心是确保输入字符串携带明确时区信息,或在转换前统一设置时区上下文。

2026.10.24 1,001
PHP集成RabbitMQ实现消息队列的完整步骤

使用 php-amqplib 库,通过建立连接、声明交换机与队列并绑定,即可在 PHP 中实现消息的发送与消费。

2026.05.24 1,001
Apache开启.htaccess及使用方法详解

本文介绍如何在本地Apache环境中启用.htaccess文件,主要涉及修改httpd.conf中的AllowOverride参数。同时详细解析.htaccess的多种实用功能,包括自定义错误页面、目录密码保护、IP访问限制、URL自动转向、默认首页设置以及防止图片盗链等配置方法,并分析了使用.htaccess对服务器性能和安全性的潜在影响。

2026.05.09 1,001
Skill 文件
  • SKILL.md
    • Cinematic Kling
    • Deployment
    • Inputs
    • Character Sheet Prompt Structure
    • Video Prompt Guidelines
    • Step 0 — Verify Which Image Is Which (MANDATORY)
    • Step 1 — Upload Images to ComfyDeploy Storage
    • Step 2 — Submit Run
    • Polling for Results
    • Step 3 — Poll & Download Results
    • Step 4 — Send Results as Files
    • Output Structure
    • Python Helper
    • Typical Run Time
    • Use Cases
    • Notes
  • 项目或源文件

相关 Skill

更多
Character Sheet Character Sheet 角色设定图/三视图生成器。将角色描述转化为四区角色设定板:主视觉(正面+侧面+背面)、补充信息(面部特写+配色板)、局部细节(配饰/关键识别元素)、全身比例照。用户说“角色设定”“三视图”“人物设计”“画角色”时触发。
service-qa-coach service-qa-coach Review support quality for chat, email, phone, social DM, or marketplace service teams. Use when a team needs a QA scorecard, failure-mode analysis, coaching plan, calibration checklist, or service-improvement brief without live ticketing, CRM, or contact-center system access.
高中数学作业批改助手 高中数学作业批改助手 >图片识别 直接读取学生手写作答照片,识别公式、符号、步骤 🧮 自动推导 根据题目自动生成参考答案和评分细则,无需教师预设 📊 逐步给分 每个关键步骤独立评分,体现过程分 📝 结构化报告 输出含识别内容、参考答案、逐步评分、改进建议的完整报告 🗂 批量批改 支持一次性批改多道题,最终汇总得分表
Vibration Analysis Vibration Analysis 分析来自CMS趋势、RMS/峰值、频谱及SCADA报警的风机传动链(主轴、齿轮箱、发电机)振动数据。
Traditional Bone Tool Making Basics Traditional Bone Tool Making Basics Use when you need custom, durable, repairable tools like awls, needles, scrapers, harpoons, or fishing hooks made from local animal bones or antlers and comm...