Communitygithub.com

Alemoterani/auto-edit-hyperframes

使用 HyperFrames CLI 开发循环:初始化、添加、目录、捕获、代码检查、检查、快照、比较、评分比较、预览、播放、展示、节拍、关键帧、单次或批量渲染、发布、云、云运行、反馈、Lambda、诊断、浏览器、信息、升级、技能、合成、时间线、历史记录、清理、文档、基准测试、遥测、转录、认证、文本转语音和去除背景。同时也用于诊断构建或渲染失败。

auto-edit-hyperframes 是什么?

这个 HyperFrames CLI 自动编辑技能为 AI 代理(如 Claude Code、Cursor、Codex 等)提供了一个完整的开发循环工作流,用于生成视频合成。它通过 init、capture、catalog 和 add 等命令管理从创建到发布的项目,支持本地、HeyGen 云、AWS Lambda 和 Google Cloud Run 渲染。该技能强调在手动创作之前使用 catalog 查询复用现有原语,同时要求通过 lint 和 check 命令在浏览器预览前进行代码质量验证。它集成了历史管理(begin/undo/end),可以避免覆盖用户的手动编辑,还内置了关键帧动画、音频编辑(淡入淡出、音量自动化、语音旁白)和资产处理的交叉引用指导。输出验证使用 ffprobe 检查文件存在性和非空性,并解析渲染摘要以识别性能问题(如 Linux 上的软件 GPU 慢路径)。该工具适用于快速迭代:质量草稿模式用于探索,外观质量用于首次正式编码,交付质量用于最终输出。它使用 npx hyperframes 运行,需要 Node.js 22+ 和 FFmpeg。

兼容平台✓Claude Code✓Codex CLI~Cursor
npx skills add https://github.com/Alemoterani/auto-edit-hyperframes/tree/HEAD/vendor/hyperframes/skills/hyperframes-cli

在你喜欢的 AI 中提问

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

文档

HyperFrames CLI

按 npx hyperframes ... 运行命令,除非项目说明提供了包装器。若有包装器则遵循包装器。CLI 需要 Node.js 22 或更高版本以及 FFmpeg。

开发循环

  1. 脚手架: npx hyperframes init <project>(居中空白)。或捕获一个站点。仅当从命名示例开始时传递 --example=<name>。
  2. 找到动作: 如果请求涉及资源、声音、图像、语音或快速视觉编辑,在提出方案前先通过 /media-use 解决。否则,在手动编写运动前,先搜索是否已有实现该效果的原始方法:npx hyperframes catalog --query "逐行显示标题"。描述你想要的视觉效果,而非你想到的实现机制。用 npx hyperframes add <name> 安装(参见 /hyperframes-registry)。仅在所有方法都不匹配时才手动编写。
  3. 编写: 使用 /hyperframes-core 编写合成。要了解项目时间线的内容(轨道、片段、开始、结束、播放内容),运行 npx hyperframes timeline --json,而非读取 index.html 和每个子合成文件:嵌套行携带绝对主时间线 absStart/absEnd 及其所属的 file,而不仅仅是每个子合成的本地时间。优先使用 --json 而非文本形式;在相同或更好的正确性下消耗更少令牌。参见 references/upgrade-info-misc.md 中的单行命令,它们无需读取完整输出即可回答常见问题。
  4. 编辑时快速获取反馈: 在第一次 HTML 遍历后及结构变更后运行 npx hyperframes lint。
  5. 运行最终关卡: 运行 npx hyperframes check;它会在打开浏览器前重新运行 lint。不要添加冗余的独立 lint 调用。添加 --snapshots 以获取带注释的概览帧和查找裁剪区域。
  6. 检查子合成: 当 index.html 挂载了 data-composition-src,捕获中间点快照并检查每个挂载的场景。
  7. 打开最终 Studio 预览: 运行 npx hyperframes preview --background,验证 URL 返回 HTTP 200,将时间线项目 URL 交给用户,并询问是修改还是渲染。保持预览运行直至审核结束。
  8. 仅批准后渲染: 迭代时使用 --quality draft,首次实际编码使用 --quality looks(CLI 默认),最终交付使用 --quality delivery。
  9. 将项目交给桌面应用(可选): 当渲染的 Framey 行以 hyperframes open … 结尾时,提供 npx hyperframes open [dir]。这会在 HyperFrames 桌面应用中打开项目并将其添加到首页;在 Claude Code、Codex 或 Grok 下,其聊天会接续当前对话。如果没有该应用,则退出并返回 1 并打印下载链接。--json 用于代理。当 open 提示用户回来后运行 catch-up,或任何命令以命名该命令的行结尾时,在下次变更前运行 npx hyperframes catch-up [dir]:它会列出自交接以来用户在应用中询问和更改的内容。旧版 CLI 没有 catch-up。
  10. 验证输出: 确认文件存在且非空。阅读渲染摘要的第二行(beginframe 对 screenshot、GPU、阶段计时)。Linux 上的 screenshot + software gpu 是慢路径。运行 ffprobe -v error -show_format -show_streams 并将时长(如果要求设置了 fps 则包括 fps)与根 data-duration 比较。

轮次中的项目历史

每次对项目的写入都保留为一个可撤销的条目。仅在两个时刻使用它,不要在每一步使用:

  • 轮次开始: npx hyperframes history begin --who <your-name> --label "<你将要执行的操作>",然后 npx hyperframes history --since mine --who <your-name> 查看用户自你上一个轮次以来的更改。在他们的编辑基础上构建;永远不要覆盖它们。
  • 检查失败,或用户表示情况变糟: npx hyperframes history undo --who <your-name> 撤销你最新的轮次,保留用户的编辑。不要手动回退。如果冲突,则退出并返回 2 并打印两个选项。

每个轮次结束时运行 npx hyperframes history end,这样你的写入会被识别为你的,而不是“在应用外更改”。轮次开启期间,每次写入都计入你的记录,直到 10 分钟内无写入;之后轮次自动结束。

强制创作者编辑交叉引用

  • 在编写或诊断缩放、切入/切出、重新取景、摄像机移动或任何关键帧运动之前,先阅读 /hyperframes-keyframes。
  • 在 hyperframes keyframes 之前,阅读 /hyperframes-keyframes;该命令显示动画轨迹,但不诊断片段剪切。
  • 对于剪切、修剪、拼接、重新排序或源时间编辑,阅读 /hyperframes-core 并使用其片段/时间线契约。
  • 对于淡入/淡出、交叉淡入淡出、轨道增益、音量自动化、闪避、画外音雕刻或已放置音频上的 FX,阅读 /hyperframes-audio。当片段放置或画面时序也变化时,同时加载核心。
  • 涉及资源、声音、图像、语音或快速视觉编辑的请求在提出方案前通过 /media-use 解决。从 /hyperframes-core 复制创作者编辑标记 → references/creator-editing-recipes.md。
# 快速迭代检查;编写时根据需要重复。
npx hyperframes lint

# 必需的最终关卡;包含 lint。
npx hyperframes check
npx hyperframes preview --background
npx hyperframes render --quality looks --output out.mp4
test -s out.mp4
ffprobe -v error -show_format -show_streams out.mp4

check 先运行 lint,然后使用一个浏览器会话和一个寻道遍来审计运行时错误、失败的请求、布局、*.motion.json 断言和 WCAG 对比度。持久性发现会阻断退出代码;瞬态进入或退出发现仅为信息性。使用 --strict 来阻断警告。validate、inspect 和 layout 仍为别名以保持兼容性,但不得出现在新指令或脚本中。

渲染前预览

仅在 check 通过后打开最终合成预览(#project/<name>),以查看已组装的时间线。聊天中的计划及 storyboard.html 草图不是最终视频的批准。渲染始终需要 hyperframes/references/review-loop.md 定义的最终批准。

子合成烟雾测试

静态审计无法捕获所有挂载失败。当项目使用子合成时,为每个宿主槽至少捕获一个可见中间点:

npx hyperframes snapshot --at <t1>,<t2>,<t3>

将微小未样式内容、画布大小图标、缺失英雄元素或时间线注册超时视为阻止渲染的挂载缺陷。参见 hyperframes-core/references/sub-compositions.md 获取相应修复方法。

代理约定

  • 在手动编写运动前先搜索目录。 npx hyperframes catalog --query "<节拍描述,用英文>"。搜索完全本地化:没有托管层、没有账户,查询文本从不发送到任何地方。默认情况下,它根据与项目名称、标题、描述和标签共享的词汇进行排名,这可能会遗漏任何未复用目录自身措辞的表述。添加 --on-device 以根据含义排名(见下面的离线层)。

  • 即使视频不是英文,也用英文查询。 两个层都索引英文目录,因此用其他脚本查询不会产生可搜索的词汇并返回空结果。用英文描述动作;屏幕上的复制内容保持视频所需的语言。查询中无可搜索词汇 正是这种情况,不是组件缺失,所以不要将其报告为目录缺口。

  • 阅读哪个层回答了;绝不要从出现的结果推断。 使用 --json 时,信封包含 query、tier(on-device 或 words)、tier_detail、dropped、unindexed、shown、total 和 results,以及当回答层产生 top_score 时的 top_score 和当请求某层但无法运行时或当搜索无结果且更好的层仍在等待用户同意时的 warnings。words 层的弱结果是预期的;on-device 层的相同结果是一个 bug。top_score 仅用于 on-device 层,并且背后没有阈值:排序器为每个查询按某种顺序返回整个目录,因此将其视为证据,而非通过或失败标志。

  • dropped 和 unindexed 是注册表与设备上索引之间的相反偏差,重新措辞查询不能解决任何一个。 dropped 计数该注册表无法安装的已排名名称,因此最符合条件的匹配正在丢失。unindexed 计数索引完全看不到的注册表动作,任何查询都无法返回。刷新注册表不是这两者的解决方案:其清单具有 24 小时 TTL 并可自愈,而向量是单独发布的工件,获取到 ~/.hyperframes/catalog/。当 unindexed 大于零时,重新运行 --on-device 会重新获取该索引,因此这是提供给用户的补救措施。纯过度覆盖偏差(dropped 大于零而 unindexed 为零)不会触发重新获取;清除 ~/.hyperframes/catalog/ 是唯一的解决方法。两个计数都是名称计数而非结果计数,因此任一都可能超过 total。

  • 当搜索返回的结果不值得安装时,请说出来。 npx hyperframes feedback --search-miss "<你运行的查询>" --wanted "<你需要的动作>" --tier <回答的层>。你无需自己组装该行:catalog --query 会打印预填充的行,并且每个 --json 搜索信封都携带 report_gap,其中查询和层已正确填入——填写 --wanted 并发送。这是唯一能将查询发送到任何地方的路径,并且它是一个单独的故意命令,正因如此,普通的 catalog --query 才能保持其不发送任何内容的承诺。在任一层上报告,无论何时结果无法满足需求;不要坚持使用 on-device 层,该层需要用户同意的 33 MB 下载,因此在大多数代理运行中处于关闭状态——等待它意味着永远不报告。层信息会包含在报告中,因此词汇遗漏与含义遗漏之间的区别不需要你判断自己命中了哪种。返回的是目录中尚不存在的动作列表,直接读取而非根据安装计数猜测,因此重要的措辞是你需要的效果,而不是你想象的项名称。它不携带评分,也永远不会进入评分指标。

  • 提供离线层;绝不要静默启用。 一次性约 33 MB 下载(bge-small-en-v1.5 的量化 ONNX 构建及其分词器,固定到特定修订版)以及注册表中的目录向量,都缓存在 ~/.hyperframes/ 下,既不添加到项目也不添加到任何包中。缓存后,它会根据含义进行排名,且不发送任何内容。说出大小大小,让用户决定,然后一旦他们同意,传递 --on-device(加上 -y 跳过提示)。交互式提议仅在 TTY 上触发。在 --json 下没有提示,但未找到结果的搜索会在 warnings 中放置相同的请求,因此读取该数组并将决定交给用户自己。当用户询问下载内容、为什么是这个模型或什么离开机器时,请将他们指向 https://hyperframes.heygen.com/developers/catalog-search。

  • 优先对代理和 CI 调用使用 --json。服务器模式下的 render、preview 和 play 不提供普通的 JSON 输出;preview --selection --json 和 preview --context --json 是查询模式例外。

  • doctor --json 始终以退出码 0 退出。根据其有效负载进行门控:

    npx hyperframes doctor --json | jq -e '.ok' >/dev/null
    
  • 非 TTY 模式是自动的,并搭建居中空白模板。仅当从命名示例开始时传递 --example。使用 --non-interactive 强制在 TTY 上使用仅标志模式。

  • 在同一个验证循环的所有命令中使用一个 HYPERFRAMES_RUN_ID。

  • 当磁盘空间紧张时,运行 npx hyperframes clean(使用 --dry-run 先列出);它会移除死渲染留下的内容以及可自重建的空闲缓存,从不删除输出、源文件或正在进行的渲染使用的任何内容。将 QC 帧写入临时目录,而非项目。

  • 当相应的警告、变量或 CI 条件必须阻断渲染时,使用 --strict、--strict-all 和 --strict-variables。

  • JSON 路径将主目录编辑为 $HOME;不要尝试逆转编辑。

  • 当托管云项目接近或超过 200 MB 上传限制时,使用 cloud render --dry-run --json 并遵循 references/cloud.md 中的 .hyperframesignore 调查。切勿仅仅因为资产大就忽略它。

  • 切勿仅因检查通过就渲染。在最终预览处暂停并等待批准。

Studio 指导编辑

当用户提到“这个元素”或当前选择时,查询 Studio 而非猜测:

npx hyperframes preview --context --json --context-fields selection

尽可能使用 selection.target.hfId,否则使用其选择器和源文件。如果结果报告 no-selection,请用户单击该元素并重新运行。仅请求你需要的上下文切片;仅对计算样式或可编辑文本元数据使用 --context-detail full。完整行为和失败代码在 references/preview-render.md 中。

渲染选择

需求命令
快速本地迭代npx hyperframes render --quality draft
首次实际编码`npx h

…

[已截断以供翻译]

Individual skills in this repo

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

Alemoterani/auto-edit-hyperframes

Overlay doctrine for the embedded-captions workflow — the caption MODEL (drop / rail / embed) and the rule that captions are an OVERLAY composited on top of the film, never a reserved bottom band you shift content up to avoid. Load when adding captions/subtitles to a talking-head or launch video, when deciding whether a phrase should be dropped, ride the verbatim rail, or be promoted to a scarce embedded climax, when laying out a composition that will carry captions (do NOT reserve a keep-out band), or when centering a composition on the true frame center under captions. Quotes the rail+embed model from embedded-captions and constraint #13 (captions overlay, keep-out band retired) from the product-launch-video scene agent. Applies ON TOP of embedded-captions.

Alemoterani/auto-edit-hyperframes

Turn a weekly changelog .md into a finished branded changelog video (square 1080, ~45-60s, Annie VO, animated brand background, mock-UI visualizations, lowkey captions). Use when the user provides a changelog/digest markdown and wants the weekly video, or says "changelog video". Self-contained — fonts, background, lexicon, and scripts ship in this skill.

Alemoterani/auto-edit-hyperframes

The technique catalog: five velocity-matched SEAMS (zoom-through, INVERSE zoom-through, cut-the-curve, waterfall cut, rack-focus blur-cut) plus the two in-scene techniques — waterfall ENTRY (staggered arrival cascades for title cards / segment openers) and the nudge curve (slow-fast-slow three-phase group slides). Covers partial-travel (~12% of frame) velocity matching via mirrored power4 eases, the Z scale-sign rule, size-scaled blur (10px text / 18-20px full-frame), word-by-word staggered cuts, cascade pacing by element weight, and the 10/65/25 slide ratio. Read before authoring any transition, text-beat handoff, kinetic text entry, or group reposition. [depth, zoom, inverse-zoom, scale-sign, mirrored-zoom, rack-focus, pacing, velocity, cut-the-curve, waterfall, stagger, cascade, kinetic-text, title-card, segment-opener, nudge, slide, easing, group-motion, z-depth, motion-graphics, cinematic, transition, blur, directional-continuity]

Alemoterani/auto-edit-hyperframes

GATEWAY — load FIRST before composing any HyperFrames animation or video. The high-level motion law that makes a multi-scene video feel like ONE continuous camera move instead of a stack of independently-animated slides. Covers the vector law (how you exit determines how you enter, incl. the Z scale-sign rule), the film's current, carrier elements, causal motion, the Seam Gate (build-gate enforcement), the ban on idle wobble (motion must PERFORM, not breathe), stillness-before-climax, and the sustained-motion routes. Routes to the low-level technique skills (cut-the-curve — the full catalog incl. waterfall entry + nudge curve, oversized-cursor, seam-craft). These rules SUPERSEDE generic / upstream motion guidance. [continuity, direction, vector, momentum, seam, transition, ease, performance, idle-motion, narrative-motion, film-grammar]

Alemoterani/auto-edit-hyperframes

House-style oversized macOS cursor technique for HyperFrames launch videos. Load whenever a scene involves cursors or a pointer-led action, when kicking off a UI scene, when igniting a morph/transition/typing run with a click, or when a scene reads as static, dead, or stale and needs a cheap high-yield source of motion to carry the viewer's eye and segment them out of the stale state. Covers cursor size/look (incl. brand-motif cursors), the off-screen entry law, tip-targeting and the click tap, click-ignites-the-next-beat, and exit / cross-scene handoff.

Alemoterani/auto-edit-hyperframes

Render-correctness doctrine for scene-to-scene seams in HyperFrames launch videos — the prerequisites that make transitions composite correctly on the master timeline. Load when assembling the master timeline / index.html, when a white flash appears at a cut or crossfade seam (especially on dark films), when reasoning about why a transition opacity dip shows through, or when verifying the render-side mechanics of how overlapping scene wrappers blend. Covers the opaque stage-ground (#root background) white-flash guard and how the injector overlaps wrappers, holds final frames, ping-pongs tracks, and stamps lint-clean template code onto the master timeline. Does NOT contain the per-transition catalog — see the transition registry for individual transition entries.

Alemoterani/auto-edit-hyperframes

Leaves sweep through the frame and part to reveal the headline. HyperFrames block, 1920×1080, 12s, 11 variables.

Alemoterani/auto-edit-hyperframes

A tiled headline surface flips cell by cell under a sweeping depth field to reveal the rear headline. HyperFrames block, 1920×1080, 8s, 18 variables.

Alemoterani/auto-edit-hyperframes

A chain of bevelled cuboids rides a travelling wave as a content carousel. HyperFrames block, 1920×1080, 6.666666666666667s, 40 variables.

Alemoterani/auto-edit-hyperframes

An orbiting camera follows an ice logo as it breaks apart, reforms into two text moments, and fades. HyperFrames block, 1920×1080, 22.5s, 216 variables.

Alemoterani/auto-edit-hyperframes

Glass shards fly in through fog and tile themselves into the headline. HyperFrames block, 1920×1080, 12.16s, 19 variables.

Alemoterani/auto-edit-hyperframes

A single feature card orbits a dot sphere on approved Blender camera motion. HyperFrames block, 1920×1080, 10s, 4 variables.

Alemoterani/auto-edit-hyperframes

A wireframe portal bursts open, the title comes through, then its letters swap into a second phrase. HyperFrames block, 1920×1080, 8s, 9 variables.

Alemoterani/auto-edit-hyperframes

Add captions or subtitles to an existing single-subject talking-head video without editing the footage. Use for plain verbatim captions, cinematic captions embedded behind the subject, VFX captions, “炸/特效/酷炫字幕,” or a named identity from the 35-style catalog. Route by visual identity, not by backend engine. The quiet `anchor` rail is the default; embed every word only when the user explicitly wants a fully cinematic treatment. The workflow runs locally end to end, including transcription and subject matting; split multi-shot footage before applying it.

Alemoterani/auto-edit-hyperframes

Turn arbitrary text — an article, notes, a topic, a brief — into a faceless explainer video: there is no site or footage to capture, so the visuals are invented per scene (typography, abstract graphics, diagrams, data-viz). Use for topic explainers, concept breakdowns, how-tos, listicles. Not a video built from a website (/product-launch-video — promo or tour). Unclear → /hyperframes.

Alemoterani/auto-edit-hyperframes

Import Figma content into a HyperFrames composition — rendered assets, brand tokens, components, storyboard sections → reconstructed motion (frames read as states, not slides) (REST/CLI), connector-assisted motion when available, and shaders from a connector or native export. Use when the user pastes a figma.com link or asks to bring a Figma design, frame, logo, brand, or animation into a video/composition.

Alemoterani/auto-edit-hyperframes

Author or edit a custom HyperFrames composition when no specialized workflow fits, or when BRIEF.md sets flow: companion. Use for longer or multi-scene pieces, brand and sizzle reels, montages, static loops, static title cards, footage remixes, and freeform builds. Use motion-graphics instead for a short unnarrated motion-first unit, including an animated title. Route fresh creation through hyperframes before using this skill.

Alemoterani/auto-edit-hyperframes

All animation knowledge for HyperFrames — atomic motion rules, multi-phase scene blueprints, scene transitions, broader motion-design techniques, AND the seven runtime adapters (GSAP default, plus Lottie, Three.js, Anime.js, CSS keyframes, Web Animations API, TypeGPU). Use for any motion or animation task: pick 2-4 rules and compose, or load a blueprint, or look up runtime-specific API (e.g. GSAP eases / Lottie player / Three.js mixer). Also covers auditing an existing composition's choreography (animation map) and 24 named text-animation effects. HyperFrames-native: single paused timeline, seek-safe, deterministic.

Alemoterani/auto-edit-hyperframes

Use when audio already placed in a HyperFrames composition needs to be mixed: fade-in/fade-out, crossfade, track gain or volume, volume automation, ducking, a music bed that fights a voiceover (voiceover carve), effects on a track (EQ, compressor, limiter, gate, saturation, delay, reverb, chorus, phaser, bitcrush), automation envelopes drawn on a track's volume or any effect parameter, or one submix bus carrying a chain, a fader and an automation clock for several tracks at once (`<hf-audio-group>`). Don't use for sourcing or generating audio — finding BGM, SFX, or making a voiceover is `/media-use`. Don't use for clip timing or track layout, which is `/hyperframes-core`.

Alemoterani/auto-edit-hyperframes

The HyperFrames composition contract — build one renderable project. Use for composition structure, the `data-*` timing attributes, `class="clip"`, tracks, sub-compositions, variables, framework-owned media playback, deterministic-render rules, and validation. Read before writing composition HTML.

相关技能