Communitygithub.com

comfyui-video

Make a video (or animated clip) with the user's ComfyUI server from a text prompt, using a ComfyUI workflow file the user supplies, and collect finished renders by id. Use when the user asks to generate, render or make a video or clip, or asks to check on or collect a video render.

comfyui-video とは?

comfyui-video is a Claude Code agent skill that make a video (or animated clip) with the user's ComfyUI server from a text prompt, using a ComfyUI workflow file the user supplies, and collect finished renders by id. Use when the user asks to generate, render or make a video or clip, or asks to check on or collect a video render.

対応✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/Obedience-Corp/comfyui-video-skill/tree/HEAD/comfyui-video

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

ComfyUI video skill

Queue a video render on the user's ComfyUI server, wait for it in short steps, and hand back the saved files. Everything goes through one script in this skill's directory:

python3 SKILL_DIR/comfyui_video.py submit ...
python3 SKILL_DIR/comfyui_video.py wait ...

SKILL_DIR is the directory shown when this skill was loaded. Every command prints one JSON object. A failure prints {"error": "..."} and exits non-zero; tell the user the error in plain words.

Prerequisites

  • A running ComfyUI with the video models the workflow needs. The script never installs models or nodes.
  • A workflow file in ComfyUI's API format (Export (API) in ComfyUI). Use the path the user names. If they have not named one, ask for it; do not write or guess a workflow.
  • The workflow marks its inputs with placeholders: {{prompt}} (required, replaced inside any text), and optionally {{seed}}, {{width}} and {{height}} (a text value equal to one of these becomes that number).
  • Server address: --server URL, else $COMFYUI_URL, else http://127.0.0.1:8188.

Steps

  1. Submit once. Pass the user's description as a single quoted argument:

    python3 SKILL_DIR/comfyui_video.py submit --workflow PATH/TO/workflow.json \
      --prompt "a fox running through fresh snow, slow pan"
    

    Optional: --seed N, --width W --height H (required when the workflow uses those placeholders), and --set NODE.INPUT=VALUE (repeatable) for one input on one node, such as a frame count or frame rate: --set 12.length=49 --set 30.frame_rate=16. VALUE is read as JSON when it parses, otherwise as text.

    It prints {"id": "...", "server": "...", "seed": N}. Tell the user in one line that the render is queued.

  2. Wait by running wait again and again with the same id:

    python3 SKILL_DIR/comfyui_video.py wait --id ID
    

    Each call returns within --max-seconds (default 25, under the common 30-second limit on one command) with one of:

    • {"state": "running", ...}: still queued or rendering; run wait again.
    • {"state": "done", "files": [...]}: the outputs were downloaded to --out (default ./comfyui-videos/), in a folder named after the id.
    • {"state": "failed", "error": "..."}: ComfyUI's own error message.
    • {"state": "gone", ...}: ComfyUI no longer knows the id (its queue was cleared or it restarted). Tell the user; do not resubmit unasked.

    Stop waiting early if your tool rounds are running low.

  3. On done, reply with the file paths. The chat cannot play video, so list the paths as plain text; do not use image syntax for them.

  4. If you must stop while it is still running, reply with the id and the output folder, and say that asking again ("check video ID") will collect it. Running wait for an id that is already done returns the same files without downloading them again.

Rules

  • Never start a second render of the same prompt to "retry" one that is still running.
  • Never call ComfyUI's interrupt, free-memory or queue-clearing endpoints, never change its settings, and never install models or nodes. The server may be shared with other work.
  • If renders usually take longer than one wait and your command time limit allows more than 30 seconds, pass a larger --max-seconds that stays a few seconds under that limit.

Install

Copy or link this folder into the skills directory your agent reads, for example <workspace>/.agents/skills/comfyui-video/ or <workspace>/.claude/skills/comfyui-video/. In a camp workspace, copy it to .campaign/skills/comfyui-video/ and run camp skills link.

関連スキル