Home / All Skills / Content & Media Creation / hyperframes-core
Content & Media Creation · heygen-com/hyperframes

hyperframes-core

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. Also covers Tailwind projects and the STORYBOARD.md / SCRIPT.md plan formats. Read before writing composition HTML.

L4 High-Privilege · Graded auth & full auditV1 Commit-PinnedExecute CommandNetwork AccessWrite FileDual-pass Audit
Author heygen-comGitHub heygen-com/hyperframes ↗Stars 48297License Apache-2.0(仓库根 LICENSE;GitHub API spdx Apache-2.0)Commit b8328f9573
Control levels describe skill capabilities and suggested control measures; they do not represent quality or safety certifications, nor do they dictate usability. Usage decisions rest entirely with users and administrators. Different agent hosts apply varying constraints; do not assume hosts provide automatic protection. Third-party skill copyrights belong to their original authors. Use at your own risk.

1How It Works & Mechanism

This skill serves as the "technical contract" for HyperFrames: the complete rulebook for authoring HTML into renderable video—a single paused timeline, `data-*` timing attributes, `class="clip"`, sub-compositions, and deterministic rendering prohibitions. The main text of SKILL.md functions as the build guide, with granular details offloaded on demand across 19 cards in references/.

skills/hyperframes-core/SKILL.md
This skill is the **technical contract** — how to build one hyperframes project. The body below is the build guide; per-topic detail lives in `references/` (index next), read on demand.
A 19-row index table under references/ (covering minimal-composition, data-attributes, tracks-and-clips, sub-compositions, variables-and-media, determinism-rules, storyboard-format, review-loop, production-loop, brief-contract, brief-format, script-format, subagent-dispatch, frame-worker-core, tailwind, etc.).

Core model: composition = HTML file, DOM declares timing via `data-*` attributes, each composition registers exactly one `gsap.timeline({ paused: true })` to `window.__timelines["<id>"]`, and render length is determined by the root `data-duration` (not the timeline duration).

skills/hyperframes-core/SKILL.md
Each composition registers **exactly one** `gsap.timeline({ paused: true })` at `window.__timelines["<id>"]` (key = root `data-composition-id`).
Supporting rule: Render length is the root's `data-duration`, **not** the timeline's length—content exceeding it is clipped, and finishing early holds on the final frame; the runtime initializes the registry prior to executing inline scripts.

Capabilities cover actual lint rulesets: SKILL.md enumerates lint-catchable pitfalls item-by-item (such as gsap_css_transform_conflict, media_crossorigin_breaks_preview, video_nested_in_timed_element, media_missing_id), warning that lint errors will simultaneously disable layout/contrast audits.

skills/hyperframes-core/SKILL.md
Never put `crossorigin` on `<video>`/`<audio>`. `lint` rejects it unconditionally with `media_crossorigin_breaks_preview` (error), including for canvas/WebGL/WebAudio readback. There is no suppression.
These rules correspond directly to the real compiler/validator in packages/core and packages/engine (the SKILL references the hasTemplate gate in packages/core/src/compiler/compositionAssembly.ts to explain assembler behavior); the SKILL represents the contract layer rather than the implementation layer.

Deterministic rendering is a strict rule (not a recommendation): no runtime clocks, unseeded Math.random, network calls, or input state; no `repeat: -1`; no tweening display or raw visibility on clip elements; no `<br>` inside body text.

skills/hyperframes-core/SKILL.md
No render-time clocks / unseeded `Math.random` / network / input-state; no `repeat: -1` (use a finite count).
The SKILL distinguishes between "lint-catchable" issues and "silent bugs automated gates may miss", explicitly listing rules outside automated coverage (such as flat queries searching for video/audio, globally unique IDs across assembled pages, and root fill being discarded under shader transition paths).

The sub-composition assembly contract is strictly defined down to file structure: standalone roots must not be wrapped in `<template>` (lint error standalone_composition_wrapped_in_template), whereas sub-compositions must be wrapped in `<template>` with style/script placed inside the template (the hasTemplate gate strips header style/script), and the host, inner, and timeline keys must share the identical ID.

skills/hyperframes-core/SKILL.md
for a **templated** sub-composition the assembler drops the file's own `<head>` `<style>`/`<script>` (`packages/core/src/compiler/compositionAssembly.ts`, the `hasTemplate` gate), so put `<style>`/`<script>` **inside** the template.
Directly cites source code paths as behavioral evidence—the skill documentation co-evolves with compiler implementation in the same repository to eliminate documentation drift (the same section notes the `data-hf-render-id` mechanism for frame injection and exceptions for `<source>` child elements).

The validation loop is real, structured, and tiered: `npx hyperframes check` runs five audit classes at once (lint, runtime, layout, motion, contrast), snapshot extracts frames for visual inspection, `preview --background` serves human review, and render requires explicit user approval before execution.

skills/hyperframes-core/SKILL.md
- [ ] `npx hyperframes check` passes (0 findings across lint, runtime, layout, motion, and contrast) - [ ] Projects with sub-compositions: `npx hyperframes snapshot --at <midpoints>` and eyeball each frame
The gate specifying that "render executes only after user approval" is baked into the core contract—maintaining consistency with the Gate structure across ecosystem workflows such as music-to-video and product-launch.

2Core Capabilities

01Minimal renderable composition scaffold instruction (standalone root, sized box, clip + tween)
02`data-*` timing/track/media attribute reference tables and `class="clip"` semantics
03Sub-composition assembly (host attrs, `<template>`, per-instance vars, animation boundaries)
04Deterministic rendering rules and seek-safe timeline construction (single timeline, `data-duration`, finite repeat, zero runtime measurements)
05Creator editing recipes (cut, trim, reorder, retime, freeze, camera, mask, crossfade, audio)
06Planning and script formats (STORYBOARD.md, SCRIPT.md, BRIEF.md contracts) alongside review-loop and production-loop workflows
07Frame-worker role contracts and subagent dispatch primitives (shared across narrative workflows)
08Five validation gates: lint, runtime, layout, motion, contrast + snapshot visual inspection + preview

3External Dependencies

KindDependency / Endpoint
clihyperframes CLI(check/snapshot/preview/render;命令细节在 /hyperframes-cli)
networkGSAP 经 CDN 进 composition(示例/骨架引 jsdelivr gsap;渲染时在 headless 浏览器加载——产物运行依赖,非 skill 自身外发)
package@hyperframes/core / engine(同仓 packages/,真实校验/装配/渲染实现)

4Recommended Governance & Evidence

Suggested Controls for Safe Operation
For Agent Runtime
Graded/per-use authorization, sandbox recommended
For Administrators
Approval workflow, rollback support, full audit
Evidence & Triggers (File Paths & Excerpts)
  • scripts/: Executes local scripts or commands: npx hyperframes check / snapshot / preview --background / render (local CLI: lin
  • 网络端点: Declares external network access: During rendering and preview, compositions fetch runtime libraries like gsap from CDNs (jsdelivr; artifact-level dependencies that can be vendored to prevent network requests) as authored
  • 本地工作目录: File read/write and artifact output: Author output: index.html / compositions/*.html / STORYBOARD.md / SCRIPT.md / frame.m
Audit Notes: Pure local contract and file I/O skill: no credential reading, no third-party data exfiltration. It executes official hyperframes CLI local checks (lint, runtime, snapshot, preview, render; render requires user approval, preview leaves a local server process running), outputting in-project HTML and planning files. The only network access consists of compositions fetching public CDN libraries like gsap from jsdelivr at runtime (artifact-level dependencies that can be vendored locally) and official CLI updates, neither of which touches tokens or private keys.

5Second-Pass Verification

  • [ok] lint 规则名与真实校验器对应 — SKILL.md 引用的编译器路径 packages/core/src/compiler/compositionAssembly.ts 在仓库 packages/core 下实测存在(仓库级 glob 复核);规则命名风格与 .oxlintrc/engine 校验一致。
  • [discrepancy] 『document.fonts.ready 内构建可接受』与『禁 async 构建』是否矛盾 — 首轮将两条规则并置易误读:SKILL.md 正文允许在 async callback(fonts.ready)里构建但『register only after the build completes』;animation SKILL.md 的『no timeline construction inside async/setTimeout』指不能把注册放进未完成的异步流。两条实质一致(注册须在构建完成后同步完成),已在 how_it_works 注明而非判定矛盾。
  • [ok] preview 进程存活行为 — SKILL.md 'the server survives the invoking command' 复核一致——preview 是常驻本地服务,属预期行为已列入 file_writes 描述。
  • [ok] 有无隐藏脚本/网络(纯文档声称) — find 实测 skills/hyperframes-core 含 1 个共享 lib(scripts/lib/frame-packets-core.mjs,packet 数据组装,无 IO 外发);无网络代码。
  • [ok] 与其它 skill 的契约引用一致性 — music-to-video frame-worker.md、hyperframes 路由、hyperframes-audio SKILL 均引用 core 的 determinism/sub-composition 契约且无互相矛盾的定义。

6Verdict & Scenarios

  • Explicitly transforms tacit "HTML to video" knowledge (timing attributes, seek-safety, determinism) into look-up tables and lintable contracts
  • Honestly separates automated coverage from mandatory manual checks, preventing the illusion of safety from all-green checks
  • Provides shared workflow primitives (review-loop, brief-contract, frame-worker-core, storyboard-format) so 10 workflows avoid reinventing the wheel
  • Deterministic rigor (no randomness, no clocks, finite repeat) directly ensures render reproducibility: "same input, identical frame"
  • Best for: Ideal for any agent session authoring HyperFrames compositions (the mandatory contract layer to review before writing HTML), creator workflows requiring editing recipes like cuts and crossfades, and skill authors seeking to understand the "documentation as contract, contracts are lintable" design paradigm.
    Not for: Not intended for contexts where authoring compositions is unnecessary (pure audio mixing -> audio, asset acquisition -> media-use, pure visual direction -> creative); command execution specifics (render, publish, Studio) belong to hyperframes-cli; runtime API specifics (GSAP, Lottie, Three) belong to hyperframes-animation/adapters.
    Install Agent-Ready
    ① Verified Mirror 2026-09-09
    Option A · Direct DownloadDownload hyperframes-core.tar.gz
    sha256: 74bec24a87c21ea7…
    Option B · Copy Guide for Agent
    install.json
    Agents automatically download and verify mirrors from this JSON guide.
    ② Upstream GitHub
    GitHub Repo ↗
    Pinned to commit b8328f9573.