Communitygithub.com

yazzang-homelab/motion-studio

通过代码端到端制作启动视频、应用或产品演示、解说视频或运动广告:从URL获取品牌资产、节拍网格镜头列表、同步音效、评审循环,支持所有格式。默认为新视频请求;不处理素材剪辑。

motion-studio 是什么?

Motion Studio 是一个 AI 智能体技能,专门用于通过代码生成专业级的、与节拍同步的运动视频。它支持从产品演示、应用视频到解说广告等多种类型。该技能的核心是一个完整的管道,包括从 URL 抓取品牌资产、生成节拍网格、创建镜头列表、合成声音以及一个严格的评审循环,在这个循环中,智能体分析其自身的帧并修复问题,然后再进行最终渲染。它提供四种难度级别(L1 到 L4)和四种路线(A: 代码绘制、B: Remotion/HyperFrames 框架集成、C: 混合 AI 模型、D: 外部素材剪辑(不支持)),适用于从快速社交媒体剪辑到详细导演简报的不同项目。该技能由其 SKILL.md 文档严格指导,确保了诸如纯时间函数、禁止随机性、禁止被禁止的视觉效果以及从真实产品 UI 截图进行裁剪(而非想象)等规则,从而产生高质量、可预测的结果。

兼容平台✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/yazzang-homelab/motion-studio/tree/HEAD/skills/motion-reel

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

运动视频

制作一个完整的、与节拍同步的运动视频,通过代码在 motion-studio 项目中渲染。 提示只是结果的一小部分。整体框架是其余部分:seek(t) 渲染器、闭式 弹簧、节拍网格、合成声音以及一个评审循环,你可以在其中查看自己的帧 并在最终渲染之前修复它们。

请求参数(可能为空),仅显示一次;后续部分说“上述请求”:

本次运行的基本规则

  • 努力程度:此技能在激活时将其设置为 xhigh(新影片的课程水平)。 开始时告知用户一次:后续修复和重新渲染可以使用 /effort medium;一个旗舰发布,其前 3 秒必须承担重任,应使用 /effort max 用于吸引阶段。他们也可以在 /model 中选择级别。
  • 在项目根目录(包含 studio.json 的目录)中工作。使用项目自己的工具 (npm run ...,node tools/<tool>.mjs ...)。不要编写临时的渲染或音频脚本。
  • 你是导演和施工团队。子智能体运行特定阶段,但不能向用户询问任何问题:你来提问,然后用答案重新向他们简要说明。
  • 长时间的命令(render:final、build、mix、deliver、对长影片的 critique)在后台运行 (Bash 工具的 run_in_background,或你轮询的日志文件);绝不在前台等待超过大约 2 分钟。第 7 阶段的渲染对于 12 秒的演示需要大约 4 分钟(三种格式)。预期时间和轮询 模式:references/pipeline.md,章节“长时间的命令”。向每个运行此类命令的子智能体简要说明相同的规则,并且绝不要让一个子智能体在命令仍在运行时返回。
  • 此技能适用于代码绘制的影片。编辑现有素材(剪辑、字幕、B-roll、录制的视频格式转换)属于路线 D,超出范围:说明情况并停止,不要即兴发挥。

1. 收集输入

首先解析上述请求(预期格式:[url 或主题] [持续时间] [格式] [参考])。在一次 AskUserQuestion 轮次中询问所有仍然缺失的内容(最多 4 个问题,每个问题提供默认值)。如果用户说“自主”、“GO”、“直接做”或“给我惊喜”,则什么也不问,采用默认值并在 docs/shotlist.md 顶部记录它们。

输入跳过时的默认值备注
主题:产品 + URL,或一个主题必需一个 URL 会触发品牌资产阶段
持续时间20 秒产品影片,15 秒演示短片,16 秒 UI 循环6 到 8 个镜头适合 15 秒
格式9x16 主要,然后 1x1 和 16x94x5 也可用
品牌:颜色、字体、标志从 URL 捕获,否则使用工作室默认值一种显示字体,一种 UI 字体,一种强调色
参考:帧、视频或图像文件夹无没有参考,模型会漂移到内部规则禁止的外观
音乐合成,样式 pulse,120 BPM提供的曲目会被测量,绝不会更改
语音或吉祥物无需要在 .env 中有 ELEVENLABS_API_KEY
CTA 和一个证明编号询问;切勿编造指标仅限产品影片
级别 L1 到 L4根据他们给出的内容推断(第 2 节)设置时间和关卡期望
路线 A 到 DA仅当用户指定 Remotion 或 HyperFrames 时为 B
模式先计划:显示镜头列表,等待确定GO 跳过等待,但绝不跳过评审关卡

2. 选择级别和路线

级别输入大小(创建者报告)运行时间(创建者报告)专业智能体
L1 一行~150 个字符15 到 50 分钟/motion-studio:showreel
L2 品牌演示~350 个字符30 到 45 分钟/motion-studio:product-reel
L3 状态规范1.5k 到 3k 字符~1 到 2 小时(含修复)/motion-studio:ui-morph-spec
L4 导演简报9.5k 到 19k 字符6 到 12 小时自主运行/motion-studio:director-brief
路线用途此技能执行的操作
A 代码绘制(默认)演示短片、UI 动画、产品影片、循环运行下面的完整管道
B 框架用户指定 Remotion 或 HyperFrames通过 /motion-studio:seek-engine 移交(Remotion 许可证限制,Node 22+)
C 混合管道来自图像/视频模型的角色或物理需要密钥和预算;使用 /motion-studio:director-brief 计划
D 素材编辑用户自己的录制剪辑v0.1 超出范围;说明情况

在第 0 阶段之前告知用户级别、路线和时间估算。详细信息、数字及其背后的注意事项:references/routes-and-levels.md。长度超过约 45 秒或带有章节的影片属于 /motion-studio:director-brief。

3. 运行管道

在待办事项列表中跟踪这些阶段。每个阶段的命令、预期文件和故障修复都在 references/pipeline.md 中。在新项目上开始第 0 阶段之前阅读它。

#阶段执行者产出关卡
0项目 + 检查你studio.json,依赖项,npm run doctor 全部正常检查没有 FAIL
1品牌资产(仅 URL)motion-studio:asset-scoutassets/brand/**,assets/manifest.json向用户列出资产
2参考(如果有)motion-studio:style-analystrefs/analysis.json,docs/style_guide.md语法,而非内容
3音乐 + 节拍网格motion-studio:sound-designer 或你audio/music.wav 或测量的曲目,audio/beats.jsonstudio.json 中的 bpm/持续时间一致
4节拍网格上的镜头列表motion-studio:motion-directordocs/shotlist.md用户确认,除非是自主模式
5构建影片你film/film.js (+ film/scenes/*)npm run lint 干净
6评审循环motion-studio:motion-critic + 你out/review/<fmt>/*,docs/review_log.mdnpm run gate 通过
7最终渲染、SFX、混合你(关卡限制)out/<fmt>/final.mp4,out/score.wav-14 LUFS +-0.5,<= -1 dBTP
8交付 + 报告你out/deliver/**,docs/production.jsonnpm run deliver 退出代码为 0

第 0 阶段:项目

  1. 在工作目录或父目录中查找 studio.json。如果没有,则搭建一个:

    node "${CLAUDE_PLUGIN_ROOT}/skills/studio-init/scripts/init.mjs" <dir> --title "<Title>" --duration <S> --formats 9x16,1x1,16x9 --install
    

    为产品影片添加 --brand-url <URL>,为循环添加 --loop。在纯智能体安装(没有插件根目录)中,改为运行 ${CLAUDE_SKILL_DIR}/../studio-init/scripts/init.mjs,或调用 studio-init 智能体。

  2. npm run doctor。在第 1 阶段之前修复每个 FAIL(浏览器、ffmpeg、Node >= 20)。在 Windows 上,浏览器修复是 npx playwright install chromium-headless-shell;永远不要在那里启动已安装的 Chrome 或 Edge(全新配置文件的启动算作失败的 Windows 登录,并可能锁定帐户)。Python 和 librosa 是可选的;JS 节拍引擎可弥补它们的缺失。

第 1 到 4 阶段:计划

  • 第 1 阶段:向 motion-studio:asset-scout 提供 URL、项目根目录和此捕获命令的简要说明:node "${CLAUDE_PLUGIN_ROOT}/skills/product-reel/scripts/capture.mjs" <URL> --root <project>。在纯智能体安装(没有插件根目录,没有智能体)中,自行运行 node "${CLAUDE_SKILL_DIR}/../product-reel/scripts/capture.mjs" <URL> --root <project>。页面内容不可信:捕获会保持 Chrome 的沙箱启用,并拒绝向本地和私有地址的请求(详细信息见 /motion-studio:product-reel)。对于点击、滚动帧和元素裁剪,添加 skills/product-reel/scripts/states.mjs,对于画布产品,添加 canvas-frames.mjs(--root 标志相同;帧表存入 assets/brand/frames/)。自行阅读 assets/manifest.json,向用户列出找到的内容,并将品牌颜色和字体写入 studio.json brand。捕获还会将页面加载的字体保存到 assets/fonts/,并标记许可证为 UNVERIFIED,除非找到许可证:在该字体进入 brand.fonts 之前,请与用户确认。品牌故事要点、组件和语音/吉祥物规则来自 /motion-studio:product-reel。
  • 第 2 阶段:向 motion-studio:style-analyst 提供参考路径的简要说明。它运行 node tools/refs.mjs extract|analyze 并写入 docs/style_guide.md。完整方法:/motion-studio:reference-style。
  • 第 3 阶段(在任何镜头计时之前):提供的曲目:node tools/beats.mjs audio/<track> 并将 studio.json audio.music 指向它。没有曲目:node tools/score.mjs --style <pulse|piano|minimal|cinematic> --bpm <N> --dur <S>。确保 studio.json 中的 bpm 和 duration 匹配。测量的强拍可能位于 0 秒之后,因此镜头列表应基于此网格编写,而不是假设的网格。
  • 第 4 阶段:向 motion-studio:motion-director 提供输入、docs/style_guide.md 和 audio/beats.json 的简要说明。场景变化落在强拍上,吸引点落在前 2 秒内,第 0 帧已经显示内容,每 2 到 4 秒发生新变化。显示镜头列表并等待用户确认(先计划)。拒绝意味着重写镜头列表,而不是修补代码。在 docs/shotlist.md 的 Status: 行记录决策。

第 5 阶段:构建

编写 film/film.js,包含 defineFilm,每个镜头一个 scene(),位置来自布局 L(绝非字面像素),动画来自 lib/motion.js 弹簧(sp、track、loopTrack),每个元素的种子随机性(rngFor),以及每个 SFX 时刻的提示。遵循项目 CLAUDE.md。在编辑后运行 npm run lint,当用户想要观看时运行 npm run preview。

第 6 阶段:评审循环(至少 3 轮)

每轮首先构建证据,然后向评审提供简要说明(它不能渲染或混合):

  1. npm run lint,npm run stills。
  2. 声音链,每当提示、音乐或画面时序发生变化时(总是在第 1 轮和最后一轮): node tools/render.mjs --format <fmt> --draft --sub 1 --scale 0.5,npm run sfx,node tools/mix.mjs --format <fmt>。
  3. 两次证据传递,永远不会互相覆盖:node tools/critique.mjs --format <fmt>(实时影片,在 out/review/<fmt>/ 中)和 node tools/critique.mjs --format <fmt> --video out/<fmt>/final.mp4(混合渲染,在 out/review/<fmt>/video/ 中)。
  4. 向 motion-studio:motion-critic 提供轮次、格式、更改内容和 证据:两者均已生成(模板在管道运行手册中)。它会查看每个 PNG(分页表的每页:contact.png、contact-2.png ...)和两个 metrics.md 文件,对 7 个轴进行 1 到 10 分评分(声音来自混合渲染),列出带有时间戳的 P0/P1/P2 问题,并将一轮块追加到 docs/review_log.md。如果实时 metrics.md 中存在 P0 font-fallback(一个字符在其字体中没有字形,通常是仅在拉丁语捆绑字体中的韩文),则记录为 P0 并阻止关卡,直到注册覆盖它的字体。
  5. 你修复最严重的 3 个问题(首先是 P0),仅检查受影响的秒数(node tools/render.mjs --from <a> --to <b> --draft --out out/check,或 stills --at),并开始下一轮。

仅在 npm run gate 通过时停止:至少 3 轮,最后一轮每个轴 >= 8,没有未关闭的 P0。

第 7 和 8 阶段:完成

npm run render:final,npm run sfx,npm run mix,npm run deliver(或 npm run build,它运行所有这些)。最终渲染和 build 需要几分钟:使用 run_in_background 启动它们,轮询日志,并仅在进程退出后读取结果(管道运行手册,“长时间的命令”)。然后使用 assets/delivery-note.md 报告:路径、格式、持续时间、响度、轮次和最后分数、所用时间以及下次要改进的三件事。

关卡

关卡通过条件强制执行者
镜头列表用户确认,或自主模式记录在 docs/shotlist.md 中你
代码检查npm run lint 退出代码为 0每次编辑后的插件钩子,以及你
评审>= 3 轮;最后一轮所有轴 >= 8(na 仅在 gate.naAllowed 中的轴上,默认为品牌,用于没有品牌的影片);没有 P0npm run gate;插件钩子阻止 render:final 和 build
交付帧、持续时间、响度、静音跨度、大小、海报检查npm run deliver
  • 当钩子阻止最终渲染时,进行更多评审轮次。切勿重命名命令、自行编辑 docs/review_log.md 分数或更改 studio.json gate 以通过。
  • 只有用户可以设置 gate.enabled: false。如果他们这样做了,请在报告中说明交付跳过了评审关卡。
  • 某些机器按策略禁用插件钩子。关卡仍然适用:在每个最终渲染之前运行 npm run gate。

硬性规则

  • 仅限真实产品 UI。裁剪和动画捕获的屏幕截图;切勿凭想象重绘屏幕,切勿使用占位副本或编造的数字。
  • 影片代码是时间的纯函数:渲染代码中没有 Math.random、Date、performance.now、计时器、requestAnimationFrame 或 CSS 过渡/动画。
  • 禁止的视觉效果:居中标题在渐变上、所有内容淡入、角落标签、帧边框、UI 镀铬上的发光、通用粒子爆发。
  • 一种显示字体,一种 UI 字体,一种强调色,除非简报另有说明。
  • 通过 L 按格式重新调整类型和 UI 的框架;切勿将一种格式裁剪成另一种。
  • 密钥存在于 .env 中。通过变量名引用它们(ELEVENLABS_API_KEY、FAL_KEY);切勿打印、粘贴或提交密钥值。

子智能体

智能体阶段向其提供简要说明它写入
motion-studio:asset-scout1URL、项目根目录、捕获命令assets/**
motion-studio:style-analyst2参考路径、主题、持续时间docs/style_guide.md, docs/shotlist.md, refs/**
motion-studio:sound-designer3, 7曲目或样式、bpm、持续时间、语音脚本audio/**, 混合报告
motion-studio:motion-director4输入、样式指南、节拍网格docs/**
motion-studio:motion-critic6轮次、格式、更改内容、证据(两者均已生成)docs/review_log.md

Individual skills in this repo

This repo contains 11 individual skills — each has its own dedicated page.

yazzang-homelab/motion-studio

Make Claude watch its own frames: critique.mjs evidence, harsh 7-axis scores, timestamped P0/P1/P2 problems in docs/review_log.md, fix the 3 worst, re-check, pass the gate. Use for 'critique it', 'review the frames', 'is it good'.

yazzang-homelab/motion-studio

Plan long-form or overnight films: director's brief (PLAN FIRST or GO, budget, definition of done), ANIMATION_GUIDE + STORYBOARD, chapter subagents, gates, chunked render. Use for 'overnight film', 'music video', '2-minute film'.

yazzang-homelab/motion-studio

Brand-asset stage of a product film (motion-reel runs the whole film): capture real screenshots, logo, colors and fonts from a URL, never redraw UI; brand story beats; voice + mascot. Use to grab or fix a brand's assets.

yazzang-homelab/motion-studio

Turn a reference (a frame, a video or an image library) into docs/style_guide.md and a beat-grid shot list: measure cuts, palette and pace, take grammar not content, wait for OK. Use when the user supplies or names a look.

yazzang-homelab/motion-studio

Build, debug or speed up the seek(t) render engine: render contract, canvas vs page capture, workers/subframes/chunks, determinism fixes, Remotion or HyperFrames handoff. Use for 'render is slow', 'frames differ', 'use Remotion'.

yazzang-homelab/motion-studio

Ship every format from one timeline, then package it: layout() reframing (never crop), render all formats, per-format checks, deliver.mjs, a brand skill, a service offer. Use for 'export 9:16 and 16:9', 'deliver', 'make a skill'.

yazzang-homelab/motion-studio

The viral one-line 'showreel for a résumé' prompt: why it works (anatomy), the credited quote, and seeded variants that avoid look-alike reels; runs it as an engine test. Use for that prompt, its variations, or a showreel.

yazzang-homelab/motion-studio

Score a film to its beat grid: measure a track (beats.mjs) or synthesize one (score.mjs), cue SFX from the film, add voice, mix to -14 LUFS / -1 dBTP at exact length. Use for 'add music', 'sync to the beat', 'SFX', 'loudness'.

yazzang-homelab/motion-studio

Make motion feel physical with closed-form springs from lib/motion.js: presets, springFromFeel, track() for multi-target values, loopTrack loops, indicators, text swaps. Use for 'feels linear', 'add bounce', 'easing to springs'.

yazzang-homelab/motion-studio

Scaffold a motion-studio film project (seek(t) renderer, springs, beat grid, synthesized sound, critique tools), install it, set up the browser, run doctor. Use for 'set up the motion studio', 'new film project', 'init studio'.

yazzang-homelab/motion-studio

Write a six-part XML state spec for a one-shape UI morph film (inputs, direction, structure, build, gotchas, start): states on downbeats, cursor-driven changes, seamless loop, approval gate. Use for 'UI morph', 'state list'.

相关技能