Communitygithub.com

SingleGrain-Team/video-skills

从一个简短的 UI 画面序列(起始屏、单一计数指标、导航列表、一次点击打开菜单、结束卡)构建 10-14 秒的产品短片,每个剪切传递前一个动作的动量,使其如同一段连续镜头。输出为 1920x1080 的 H.264 MP4 文件及可编辑的单文件 HyperFrames 项目。适用于应用发布、功能预告、社交媒体短视频和网站开场,当你拥有产品 Logo、几张截图、一个重点数字和真实导航标签,希望制作无旁白的精致 UI 动态。

video-skills 是什么?

这是一个用于创建简短、无声、UI 驱动的产品短片的 AI Agent 技能。其核心在于严格遵循运动规则:整个短片使用同一个缓动函数家族(指数缓出/缓入),并在每个剪切点保持运动向量匹配,确保所有动作流畅连贯,没有静止或装饰动效。技能要求收集品牌的 Logo、色彩、字体、两张真实产品截图、一个计数指标、导航标签、一个按钮动作和菜单选项,以及结束卡信息。它支持 HyperFrames 框架,通过 `npx` 命令初始化项目、替换资源、配置品牌变量(如颜色、文本、导航数组、命令字符串等),并执行检查与渲染。最终交付物包括 1920x1080 的 H.264 MP4 视频和一个可重新编辑的 HyperFrames 项目文件夹,用户只需修改数据即可进行再品牌,无需调整动作逻辑。

兼容平台~Claude Code~Codex CLI✓Cursor
npx skills add https://github.com/SingleGrain-Team/video-skills/tree/HEAD/skills/ui-sting

在你喜欢的 AI 中提问

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

文档

UI 短片

一个由 UI 节拍组成的简短、默认无声的影片。外观只取决于两个要素:同一缓动家族,以及每个剪辑处的匹配运动向量。不要添加空闲动效或装饰。

需要收集的输入

  • 品牌:名称、Logo(带透明通道的 PNG 或 SVG)、2-3 种颜色(底色、文字色、强调色)、一个可以合法渲染的字体(开源字体即可;默认使用 Inter)。
  • 两张 1920x1080 的真实产品截图(一个入口/初始页面,一个包含命令、表单或可裁剪标题的详情页面)。
  • 一个值得计数的指标(例如“662 skills”),包含标签和副标题。
  • 真实的顶部导航标签(共 5 个),以及哪个高亮显示(第三个)。
  • 观众应该采取的单个操作(按钮标签)以及它打开的 4 个菜单选项。
  • 结束卡:一个 2 字的口号、网址,以及可选的在放大卡片中键入的命令。

仅使用你拥有或获得授权使用的资源。切勿在影片中出现第三方 Logo 或 UI。

时间槽

槽位帧数(30fps)放置内容
A 标志组合1-35Logo 图标 + 文字标识,两部分先相互弹跳,然后升起
B 入口36-72截图卡片从下方进入,品牌色光泽扫过,向左退出
C 放大73-113卡片以 1.5 倍从右侧进入;显示详情截图裁剪区域并键入命令;然后升起退出
D 计数器114-154指标卡片升起,数字从 0 滚动到 N,向右退出
E 导航155-209行从左侧瀑布般进入,强调色指示条从第 1 行移动到第 3 行
F 操作210-304按钮以超大尺寸出现并收缩,光标点击,菜单打开,高亮移动到选项 3
G 结束卡305-325标语 + 标志组合 + 网址通过回拉、弹簧稳定和标志上的闪光效果出现

总共 325 帧 = 10.83 秒。所有内容以 F(n) = (n - 1) / 30 为基准。

工作流

  1. 脚手架:npx --yes hyperframes init <dir> --non-interactive --resolution landscape。这将创建项目文件;然后替换 index.html 并添加 assets/ 目录。
  2. 从本技能复制 template/index.html 和 template/assets/ 到项目中。用真实的 Logo 和截图替换三个占位图片(保持文件名,或更新 src/url() 引用)。
  3. 只重新品牌品牌层::root 颜色标记、文本字符串、NAV 和 MENU 数组、ICO 路径数据(24x24 viewBox,1.7 描边,圆头端点;绘制通用图形,绝不绘制其他公司的标志)、命令字符串 CMD、计数器目标(AMT 中的 662)和裁剪区域(#c-crop 的 background 位置/大小:选择要在详情截图显示的区域;大小 = 截图宽度 x 缩放比例,位置 = 裁剪区域在缩放像素中的负偏移)。
  4. 重新测量两个导航数字。更改标签后,渲染一次,打开一个稳定的导航帧(大约在第 6.5 秒),读取每个标签的右边缘。将 NAV[i].w 设置为行的宽度(图标 + 标签),前三行的 pw = w + 46。高亮落在第 3 行并且必须适应它。
  5. npx --yes hyperframes check。单文件布局会产生 nested_structure_needs_subcomposition 警告;这种格式是预期的。错误和对比度部分必须干净。
  6. 渲染:npx --yes hyperframes render --quality looks --workers 2 --output final.mp4。
  7. 审查帧(参见验证),修复,重新渲染。交付 final.mp4 和项目文件夹。

音乐是可选的。如果使用,通过媒体使用目录或生成来解决,确认许可证允许商业用途,将其作为 <audio id="bed" class="clip" ...> 片段添加到自己的轨道上(需要 id),并保持低音量。影片无声也能正常工作。

运动规则(不得违反)

  1. 同一缓动家族:入场使用 EO = 1 - 2^(-10p),退场使用其镜像 EI = 2^(10(p-1))。将它们作为函数传递。字符串 "expo.out"/"expo.in" 是不同的曲线,会使每次退场偏移几个像素。无过冲、无线性、无默认弹性或弹回缓动。
  2. 每个剪辑处的匹配向量(参见 references/seams.md)。剪辑前没有静止状态;剪辑后没有从静止开始。两侧的轴和方向必须一致。
  3. 曲线是补间,决策是时间戳。打字节奏、里程表数值和高亮路径通过 tl.set 逐帧标记,保持精确且可安全读取。
  4. 有意的不均匀:导航行间距不等,打字包含三个双帧。
  5. 快速移动带有模糊,模糊程度随同一缓动曲线增加,在速度达到峰值时达到最大值。
  6. 两部分标志的对应弹跳:阻尼弹簧 A * e^(-t/0.279) * sin(2*pi*t/0.5),一部分为 +A,另一部分为 -A。结束卡中单词通过同一弹簧延迟 2 帧交错出现。
  7. 计数器的最后一位数字带有垂直方向的模糊(SVG feGaussianBlur stdDeviation="0 4")。
  8. 无空闲动效。如果一个节拍感觉空洞,应添加信息,而不是晃动。
  9. 不要更改帧数、持续时间、剪辑的 data-start/data-duration、EO/EI、标记数组的长度或场景包装器的补间,除非你重新规划两侧的接缝。

技术说明

  • 创作是在 720x720 的正方形(“世界”)中进行,每个 .scene 将其缩放 1.5 倍到 1920x1080,正方形通过 .w 包装器居中(偏移 280)。因此,屏幕外的退出使用较大的像素值。
  • 剪辑边界略低于帧时间(1.166,而不是 1.1667)。
  • 深色主题需要第二层导航:浅色文字在亮色指示条上会消失。相反,在强调色指示条上使用深色文字,并在浅色背景上为任何使用强调色的小文字使用文字色(而不是强调色):例如,橙色配乳白色会通过 3:1 对比度门限。
  • 永远不要在运行时测量文本;它会与字体加载发生竞争。从渲染中烘焙出数字。
  • 如果字体不是系统字体,请将其注册到你自己控制的字体族名下。

验证

  1. npx --yes hyperframes check 通过(运行时、布局、运动、对比度)。
  2. 提取 6-8 帧并观察:ffmpeg -ss <t> -i final.mp4 -frames:v 1 f.png 大约在 0.5、1.8、3.1、4.4、6.5、8.5、9.4、10.7 秒。使用 hstack/vstack 平铺同时查看。
  3. 确认:Logo 居中;入口截图可读;键入的命令不被裁剪;计数器以目标值结束;指示条停在预期的行上并且足够宽;菜单从按钮的一角打开并且高亮移动到选项 3;结束卡文本居中且清晰可见。
  4. 按照 references/seams.md 抽查两处接缝。
  5. ffprobe 输出:1920x1080,h264,30 fps,时长约 10.83 秒。

交付物

final.mp4 (1920x1080 H.264) 以及项目文件夹(index.html, assets/)。项目是可编辑的:通过更改数据而不是动作来重新品牌。

Individual skills in this repo

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

SingleGrain-Team/video-skills

Make a 30-45 second launch film for a product by staging it inside one persistent, neutral chat window. A user types a request, the assistant answers and calls the product as a connected tool, a progress card runs, a follow-up triggers a second tool action, and the result lands as a count-up headline number before closing on the logo, tagline and call to action. Use when you need a launch, feature or integration announcement video for something that plugs into AI assistants (a skill, MCP server, plugin, connector, CLI). Delivers a rendered 1920x1080 MP4 plus an editable single-file HyperFrames project.

SingleGrain-Team/video-skills

Build a motion graphic where a screen recording plays in a large frame beside a checklist, and each checklist item ticks off at the exact moment that step happens in the recording, ending with every item checked and a short hold. Use when someone has a screen recording (product walkthrough, tutorial, onboarding, install demo) plus a list of steps with timestamps and wants a "watch the steps get done" film. Input is a recording, step labels with timestamps, a title and an optional palette; output is a 1920x1080 H.264 MP4 and the editable HyperFrames project.

SingleGrain-Team/video-skills

Build a 15-20 second product launch film that shows the product's real screen on a laptop built from plain CSS (no 3D model, no generation model) in a dark studio, scrolls the page, zooms into the interface for one key action such as typing a search, and resolves to the logo lockup. Use when someone has a full-page screenshot or screen recording of their product, one action worth showing, and a logo, and wants a short silent-friendly launch teaser rendered as a 1920x1080 MP4 with an editable HyperFrames project.

SingleGrain-Team/video-skills

Builds a 6-8 second logo sting in which the brand mark rides inside a refracting liquid bead (distorted past legibility), the bead swells, holds still for a beat, then ruptures into droplets and leaves the logo lockup (mark plus wordmark) crisp and upright on screen. Delivered as a 1920x1080 H.264 MP4 plus the editable HyperFrames project, with no 3D model, stock footage or generation model. Use it for brand intros and outros, product-launch openers, channel stings and any "reveal our logo" moment, from an SVG or PNG logo (including raster-only logos), a wordmark string and a palette.

SingleGrain-Team/video-skills

Make a 20-30 second launch film for a product that is not tied to one interface, such as a CLI, package, plugin or agent skill. The identical prompt or command is typed into four visually different surfaces in turn (a wide terminal, a tall chat card, a floating palette, an editor cell), the film then hard-cuts into a fast reel of real outputs on a beat or fixed tempo grid, and it closes on the command in a large pill. Delivered as a rendered 1920x1080 MP4 plus the editable HyperFrames project. Music is optional - with a track the cuts land on detected beats, without one they land on a 120 bpm grid.

SingleGrain-Team/video-skills

Make a roughly 30-second film that explains a code change (a pull request, release or uncommitted diff) to people who will never read the diff. It opens by showing the real diff scrolling past too fast to follow, cuts to a plain-language summary, fires four capability beats each pinned to a real code snippet, and closes on how to get it (install command and URL). Delivered as a 1920x1080 H.264 MP4 plus the editable HyperFrames project. Use when asked to turn a PR, changelog or release into a launch or explainer video.

SingleGrain-Team/video-skills

Render a 5-6 second motion graphic in which an oversized condensed headline (2-4 words) punches in behind a presenter, using a background-removed cutout of the presenter layered on top of the lettering. A hard cut then removes the presenter while the same headline holds the exact same size and position, and a short supporting line appears for a reading hold. Use it for talking-head intros, chapter openers, launch announcements and social hooks when you have one presenter clip, a headline, a supporting line and a palette. Built on HyperFrames; delivers a 1920x1080 H.264 MP4 plus the editable project.

相关技能