The open-source full-stack studio for Opus 5.5 motion video. Reverse engineering for any video. Code video with HTML: recreate, edit and render. BYOA + BYOK · Motion.md · Images, Video, Music & Voice.
TypeScript agent-skillsagentic-aiai-agentsai-videobyokclaude-codecodexdeepseek-harnessdsh-plugingenerative-ailocal-firstmcpmotionmotion-graphicsmultimodalopenmotionreverse-engineeringvideo-editingvideo-generationworkbuddy
fix(motion): unify preview handoff for creation and continued edits
bone3deep1962-collab0a53e1a108ce
diff --git a/docs/product/architecture.md b/docs/product/architecture.mdindex b18c71bf..5f219e54 100644--- a/docs/product/architecture.md+++ b/docs/product/architecture.md@@ -44,7 +44,7 @@ Model Gateway 是共用的素材生成服务,可由 Motion Viewer 或 MCP 调1. 用户在首页切到 Motion 模式,选择 Motion 模板并提交需求创建会话;也可直接新建空白创作,或打开左侧已有会话。内置模板复制为该会话的工程,外部参考由 Agent 制作。2. 需要 Agent 时选择 Codex、Claude Code、DeepSeek Harness 或通用 stdio 客户端。接入配置绑定当前工作区;Agent 验证工具和数据目录,读取当前工程与制作规范。 安装后先介绍能力、邀请并等待选择;接受首次体验即确认 `product-promo` 示例内容、独立 20 秒工程、MP4 导出及右侧可编辑页面。Agent 不再问素材/模板/导出确认,实际打开宿主面板,等待并验证成片,最终回复交付 MP4 与简短说明。宿主没有面板能力时明确提供链接作为降级,不能冒称已打开;实际行为按客户端验证。-3. 用户在会话补充需求并复制给外部 Agent。一期 Agent 用 `motion_get_project` 读取明确工程及其 sessionId、需求、来源与版本,按本轮意图选择入口或直接继续已选范围;编辑前校验工程归属,仅需编辑器时用 `motion_open_preview({projectId})` 打开。旧 design_* handler 仅留内部兼容。+3. 用户在会话补充需求并复制给外部 Agent。一期 Agent 用 `motion_get_project` 读取明确工程及其 sessionId、需求、来源与版本,按本轮意图选择入口或直接继续已选范围;编辑前校验工程归属。For original creation, reference-video recreation and editable-template production, the Agent automatically calls `motion_open_preview({projectId})` after the requested HTML is saved and visibly opens its exact `previewUrl` in the host browser, before export or delivery; no extra user request is required. The shared [editable preview handoff](../../skills/motion-production/references/native.md#editable-preview-handoff) defines readiness, host checks and capability limitations. Continued content edits, including motion-production work, confirm the same project is visible before writing, reopen a closed tab as needed, reuse an existing tab and inspect the latest visible content after saving; explicit background requests suppress opening/focusing the editor. 旧 design_* handler 仅留内部兼容。4. Agent 根据本轮目标直接选择 Skill:motion-director 负责原创、局部/整体叙事动作声音重新设计和创作审片;motion-template-to-video 负责已有模板出片;motion-recreate 负责参考作品重建(已接入实际流程、独立参考与测量脚本);motion-video-to-template 负责可复用模板生产;motion-production 承接既定决定下的工程操作、预览、技术检查、排错和导出。共享规则同源引用,已有 production/start 保留导航,无需前置总路由。项目来源与画面锁定不固定入口;保持项和已完成操作继续有效。5. Agent 导入素材或通过 Model Gateway 生成图片/视频/音频,完成后写入原生工程。用户在右侧浏览器 Tab 的 Motion Artifact Viewer 预览与编辑,可从空时间轴、素材面板或时间轴选区生成并放入指定时段;选中图片可交给 Codex 参考修改,确认后只替换素材引用并保留原生撤销。也可新增同会话的另一个工程,关闭浏览器继续会话、收起会话沉浸浏览。发生 revision 冲突时重新读取并合并。 按共享 context 补齐缺少的正文并先返回模型再执行;修改按共享 edit 核对保持项、相邻关系与后续延续。6. 完成画面、文案、声音检查后,按用户要求导出固定 revision 的快照,等待真实产物并验证。@@ -153,7 +153,7 @@ flowchart LR- **界面状态:** 浏览器 Tabs、左右面板与宽度按会话保存;关闭 Tab 不删除产物。原生 Dock 按工程保存,主题沿用 Studio 偏好;语言单独保存为 `motion.studio.locale`,均不写入影片源文件。- **参考数据:** 模板原始目录、封面和热度快照与用户工程分开。热度按模板 ID、视频地址和原帖身份匹配;同源片段不累加查看量。- **导出输入:** 后台任务使用不可变快照并记录期望规格;后续编辑不改变该任务的本地输入。远程媒体需要稳定复现时先导入本地。-- **后台与编辑器启动:** 仅导出启动后台服务,不初始化或补写当前工程;冷启动套模板直接创建选中的模板工程。显式打开预览时才初始化空工程或启动 Studio,已有后台服务原地升级。健康检查区分服务 `ready` 与 `editorReady`,不靠自动替换 expectedRevision 消除冲突。+- **后台与编辑器启动:** 仅导出启动后台服务,不初始化或补写当前工程;冷启动套模板直接创建选中的模板工程。Studio starts when the Agent calls preview for an existing project, including the automatic handoff after production HTML is ready; the existing background service is reused. 健康检查区分服务 `ready` 与 `editorReady`,不靠自动替换 expectedRevision 消除冲突。- **服务边界:** 当前在本机回环地址运行。Model Gateway 使用本机 Codex 登录或用户自有 Atlas/fal Key 发起媒体生成,接口共用本地任务与素材入库;不托管聊天 Agent、团队协作或计费。当前使用用户自有账户接入,详见 [模型网关](../model-gateway.md)。- **模型与凭据:** 配置和任务独立于工程,Key 不通过 API 返回。安装、配置、允许请求、生成成功是不同状态;任务固定发起工程,失败不静默重试。完成后的素材参与工程 revision 与导出快照。- **并发边界:** macOS 同目录多个 MCP 连接共用后台,各自绑定工程;工作区仍只有一个活动原生 Studio、一个等待/运行的导出。导出固定工程与快照,重启将中断任务持久化为失败且不重放。文件锁和 revision 保护工具写入;人工与 Agent 同时编辑同一文件仍需协调,不能当作跨工具数据库事务。diff --git a/skills/motion-director/SKILL.md b/skills/motion-director/SKILL.mdindex 855f0d24..c551379b 100644--- a/skills/motion-director/SKILL.md+++ b/skills/motion-director/SKILL.md@@ -93,6 +93,8 @@ MCP-only 使用 resources/read `motion://workflow/director/start` 读取本页根据实际素材、配音与布局调整时间,更新脚本中受影响的决定。脚本是工作记录,不是禁止修改的预设。+Once this turn's requested HTML output is saved, complete the [editable preview handoff](../motion-production/references/native.md#editable-preview-handoff) automatically, before export or delivery.+### 5. 观看、修正、交付读取 [审片标准](references/motion-review.md),观看实际输出并用时间点记录问题。先修正表达和结构,再修正节奏与运动细节;技术缺陷按影响优先处理。diff --git a/skills/motion-production/SKILL.md b/skills/motion-production/SKILL.mdindex 1abffd15..23a6a684 100644--- a/skills/motion-production/SKILL.md+++ b/skills/motion-production/SKILL.md@@ -20,7 +20,7 @@ Agent 根据本轮意图选择入口,专业任务可直接进入对应 Skill## 2. 工程操作与交付1. 修改已有内容时读取 [共享修改流程](references/edit.md),确定变化、保持项及连带影响;仅查询、预览、审查或导出按本轮范围执行。-2. 操作工程前读取 [运行规范](references/production.md);编写原生内容前另读 [Native authoring](references/native.md) 及工具返回的固定版本引擎指南。确认 projectId、最新 revision 与 currentVersionId,复用已完成操作。+2. Existing-project content edits apply the [continuing-edit preview rules](references/native.md#continuing-edits) before writing and after saving, including scoped engineering work. 操作工程前读取 [运行规范](references/production.md);编写原生内容前另读 [Native authoring](references/native.md) 及工具返回的固定版本引擎指南。确认 projectId、最新 revision 与 currentVersionId,复用已完成操作。3. 按共享上下文的依赖清单补齐受影响的质量规范。换现成音乐、调音量也需核对声画锚点与原有 SFX;画面锁定时保持视觉内容。补读结果先返回模型,后续调用再执行依赖操作。4. 检查受影响区间、接点和保持项。需要新渲染的导出或成片交付读取 [验证](references/verification.md),针对已审查 revision/versionId 导出,已有适用任务先查询并复用;原样模板预览按专业入口核验,检查实际 MP4。技术通过与创作品质、正常播放及试听分别记录。5. 停在用户要求的方案、预览、工程或成片阶段。交付实际结果、检查与必要限制。diff --git a/skills/motion-production/references/context.md b/skills/motion-production/references/context.mdindex a350491f..673f221a 100644--- a/skills/motion-production/references/context.md+++ b/skills/motion-production/references/context.md@@ -29,7 +29,7 @@ Agent 结合当前目标、保持项与工程状态选择本轮入口;工程| --- | --- || 原创新片/大幅重编 | [动作脚本](../../motion-director/references/action-script.md)、[动态表现](../../motion-director/references/motion-craft.md)、[动作短句](../../motion-director/references/motion-phrases.md)、[审片](../../motion-director/references/motion-review.md) || 新设计声音叙事或工程音轨调整,含画面锁定 | [声音叙事](../../motion-director/references/sound-narrative.md)、[动作脚本的声画锚点](../../motion-director/references/action-script.md)、审片;只应用声音相关内容,不启动原创流程 |-| 仅原样交付与当前源文件对应的模板 preview.mp4 | 按 motion-template-to-video 核对文件身份、存在与可解码;不因交付已有文件加载工程创作/导出依赖;已修改工程不能复用原模板旧预览 |+| 仅原样交付与当前源文件对应的模板 preview.mp4 | Follow motion-template-to-video for file identity/existence/decode checks and the [editable preview handoff](native.md#editable-preview-handoff); load no authoring/export dependencies. An edited project cannot reuse the original template preview. || 使用/适配可编辑模板,需要创建、编辑或渲染工程 | [模板能力说明](templates.md)、审片;默认内容的草稿也需读模板能力说明 || 明确要求视频转可复用模板 | [motion-video-to-template](../../motion-video-to-template/SKILL.md) 的制作与打包参考按阶段读取;制作决策、审片及实际参考视频 || 复刻视频 | [制作决策](../../motion-director/references/production-decisions.md)、审片,另实际检查参考视频 |@@ -49,7 +49,7 @@ Agent 结合当前目标、保持项与工程状态选择本轮入口;工程## 会话与产物归属-操作工程时用 `motion_get_project({projectId})` 核对项目、sessionId 和当前版本;没有 projectId 时先查分页列表。独立新任务通过 `motion_create_project` 创建项目,可传已有 OpenMotion sessionId 归属;只有要打开 GUI 时才调用 `motion_open_preview({projectId})`。宿主聊天 ID 不自动等于 OpenMotion sessionId,未绑定时不能用全局最近项目猜测归属。+操作工程时用 `motion_get_project({projectId})` 核对项目、sessionId 和当前版本;没有 projectId 时先查分页列表。独立新任务通过 `motion_create_project` 创建项目,可传已有 OpenMotion sessionId 归属。Original creation, reference-video recreation and editable-template production complete the [editable preview handoff](native.md#editable-preview-handoff) when the requested HTML is ready. Existing-project content edits follow its [continuing-edit rules](native.md#continuing-edits) across all entries; other scopes open the GUI on request. 宿主聊天 ID 不自动等于 OpenMotion sessionId,未绑定时不能用全局最近项目猜测归属。## 一份上下文diff --git a/skills/motion-production/references/edit.md b/skills/motion-production/references/edit.mdindex bc853337..d2f31790 100644--- a/skills/motion-production/references/edit.md+++ b/skills/motion-production/references/edit.md@@ -12,6 +12,10 @@例子用于说明范围判断,不限定对象形式、镜头结构或实现手法。文字变长可能需要排版调整,时长变化可能影响相邻转场和声音;在已授权范围内处理必要依赖并说明实际影响,不能为形式上的“少改几行”留下坏结果。只有影响目标的重要歧义或需要扩大授权范围时才追问。+## Keep the preview visible during continued edits++Before the first content write and after the saved batch, apply the [continuing-edit preview rules](native.md#continuing-edits). This applies across specialist and motion-production entries: reuse the same project/tab, restore a closed preview before editing, and inspect the latest content after saving. Explicit background requests take precedence.+## 基于当前工程修改先按 [共享上下文](context.md) 补齐本轮所需正文并完成读后决策边界,再检查目标工程、最新 revision 与受影响源文件。STATE 用于恢复决定,不能代替当前源文件。首次修改某对象时,留存足够的修改前证据:可用源文件片段、相关文件副本/哈希、时间线事件或对应画面;按风险选择,不要求每轮复制全工程。diff --git a/skills/motion-production/references/native.md b/skills/motion-production/references/native.mdindex 7b9896a9..0bd1e609 100644--- a/skills/motion-production/references/native.md+++ b/skills/motion-production/references/native.md@@ -9,9 +9,21 @@ Read the pinned engine guide returned as `authoringGuide` by project details, or3. Read text through `motion_get_project({projectId,file:{path,offset,length},expectedRevision})`. Offsets are UTF-8 byte boundaries; follow nextOffset. Media bytes stay out of MCP text responses.4. `motion_import_assets({projectId,requestId,items:[{itemId,sourcePath}]})` imports real local image/video/audio attachments in a batch. Source paths must exist on the server machine. Check every result and use the returned asset path. Import does not place media on the timeline. Keep stable itemIds for retries; never overwrite historical resources. Successful imports can create a new content version: reread project details before saving with expectedRevision/expectedVersionId. This Tool does not accept fonts, SVG/PDF, arbitrary binary files or remote URLs. Keep such files in an independent portable project using host capabilities; do not bypass managed-project guards by writing binary files directly. Inline SVG markup can be authored in native HTML.5. `motion_edit_project({projectId,requestId,expectedRevision,expectedVersionId,files:[{path,content}]})` saves one batch of text files and optional requirements. Maximum 100 files / 8 MiB; metadata paths are reserved. All-or-none failure protection uses Studio's exclusive native history window and a recovery journal. Reread after a conflict; do not replay an old patch against unknown GUI changes.-6. Only when the scope includes viewing/using the editor, `motion_open_preview({projectId})` opens this existing project in Studio and runs lint. Open its exact previewUrl in the host browser before reporting it opened. A fresh unbound client must supply projectId or an OpenMotion sessionId. Preserve embed/query/hash. It does not silently create a project.+6. For original creation, reference-video recreation and editable-template production, complete the editable preview handoff below once this turn's HTML output is ready. Existing-project content edits follow its continuing-edit rules before writing and after saving, regardless of the selected Skill. Other scopes open Studio on request.7. Inspect actual motion, timing, sound and affected joins. Local/Studio changes become native content snapshots; querying flushes saved history metadata without editing source. Return to step 2 after GUI edits.+## Editable preview handoff++The first output of original creation, reference-video recreation and editable-template production automatically includes an editable preview. Once the requested HTML and its supporting files/assets have been saved, call `motion_open_preview({projectId})` for that same project, then visibly open its exact returned `previewUrl` in the host's built-in browser. No additional user request or confirmation is needed. This includes drafts and unchanged template HTML; it does not wait for MP4 export. An empty carrier's `index.html` is not the requested output. Explicit user instructions to stay in the background take precedence.++The Tool runs lint and selects an existing project in Studio; it does not create a project or open the host browser. Preserve the URL's embed/query/hash, verify that the intended project and current content loaded, and reuse its browser tab on continued work. If lint fails, fix the reported source problem before retrying. If preview or browser capability is unavailable, provide the project URL when available and state the concrete gap; report the page as opened only after observing it. For an independent folder/ZIP, use a supported managed-project handoff if available; the public MCP has no general folder/ZIP adoption Tool. Preserve the actual source and report that limitation rather than opening an unrelated carrier.++### Continuing edits++For follow-up turns that change an existing editable project's content, confirm the intended project is visible in the host browser before the first write, including scoped edits handled by motion-production. Reuse its existing tab. If the tab is closed, unavailable or showing a different project, call `motion_open_preview({projectId})` for the same project and open the returned exact `previewUrl` in the host browser, then check the project identity. Closing a tab alone does not request background work or cancel an edit. An explicit request to keep working in the background skips opening/focusing the editor and remains in force until the user changes it. Discussion, queries, review-only and export-only turns do not trigger this editing rule.++After the turn's content batch is saved, confirm that the same visible preview shows the requested latest change, using the affected time/frame and sound when relevant. Existing pages normally update from file-change events; reuse that page rather than reopening on every save. `previewSync=file_watcher_notified` and a successful save are not proof of visible freshness. If the page was closed during the edit, reopen the same project before this check unless background work was requested. If it stays stale, reload that existing tab once and check again; report any remaining refresh, loading or browser limitation instead of claiming the latest result is visible. With explicit background work, verify persisted source/version and report visual freshness as unverified.+## Native composition contract- Root: `data-composition-id`, `data-start="0"`, `data-duration`, `data-width`, `data-height`, and optional `data-fps`.diff --git a/skills/motion-recreate/SKILL.md b/skills/motion-recreate/SKILL.mdindex bcfc1a26..66dbfdf2 100644--- a/skills/motion-recreate/SKILL.md+++ b/skills/motion-recreate/SKILL.md@@ -50,11 +50,11 @@ Ask only when the workspace and the request together still lack something only tAsk all of it in one batch through the host's question interface, in the user's language. If nothing is missing, do not ask. Do not ask about technical choices, intermediate approval or storyboards. After the answers, work through to the finished film without stopping.-## 4. Create and open the project+## 4. Create the projectFollow the [runtime adapter](../motion-production/references/production.md) and [Native authoring](../motion-production/references/native.md). A continued recreation reuses its projectId. Otherwise create one project with `motion_create_project` and a stable requestId: `projectType: "reference_video"` with `referenceUrl` for a link, or `projectType: "natural_language"` for a local file, with the file path and the agreed brief in `requirements`. Creation makes an empty carrier, not a film, and never overwrites another project.-Read `motion_get_project({projectId})` for the directory, revision, current version, `hyperframesCli` and `authoringGuide`; read the pinned engine guide before writing source. Commands you run yourself (`node <hyperframesCli>`, the measurer, `ffmpeg`) use `node` and `ffmpeg` from `PATH`. The self-contained package does not put them on `PATH`: its directory is the one holding `node_modules/hyperframes` in the `hyperframesCli` path, with Node at `runtime/node/bin/node` (Windows `runtime\node\node.exe`) and FFmpeg/ffprobe in `runtime/media/bin`. For an npm installation there is no bundled `runtime/` directory: the application root is the directory containing `node_modules/hyperframes`, and `scripts/npm-runtime.mjs` exports `ensureNativeRuntime(appRoot)` and `nativeConfiguration(appRoot)`. Prepare through the former when needed; the latter returns `paths.HYPERFRAMES_FFMPEG_PATH` and `paths.HYPERFRAMES_FFPROBE_PATH` for the verified cache. Pass these as environment variables to the measurer or direct media commands. When neither is available, record the affected check as blocked with the reason; never as passed. Call `motion_open_preview({projectId})` and visibly open the returned `previewUrl` in the host's built-in browser; without browser control, continue in the background and say so at delivery.+Read `motion_get_project({projectId})` for the directory, revision, current version, `hyperframesCli` and `authoringGuide`; read the pinned engine guide before writing source. Commands you run yourself (`node <hyperframesCli>`, the measurer, `ffmpeg`) use `node` and `ffmpeg` from `PATH`. The self-contained package does not put them on `PATH`: its directory is the one holding `node_modules/hyperframes` in the `hyperframesCli` path, with Node at `runtime/node/bin/node` (Windows `runtime\node\node.exe`) and FFmpeg/ffprobe in `runtime/media/bin`. For an npm installation there is no bundled `runtime/` directory: the application root is the directory containing `node_modules/hyperframes`, and `scripts/npm-runtime.mjs` exports `ensureNativeRuntime(appRoot)` and `nativeConfiguration(appRoot)`. Prepare through the former when needed; the latter returns `paths.HYPERFRAMES_FFMPEG_PATH` and `paths.HYPERFRAMES_FFPROBE_PATH` for the verified cache. Pass these as environment variables to the measurer or direct media commands. When neither is available, record the affected check as blocked with the reason; never as passed.## 5. Rebuild, then change@@ -70,6 +70,8 @@ Apply the changes with care: fit longer text with related layout and reading-timSound: when the reference has sound, the remix has sound. Keep the reference soundtrack by default (extract it as AAC `.m4a` and import it) and re-time it to the new cut; remove a voiceover that names the reference's brand or product. Deliver a silent film only when the user asks or the reference is silent.+Once this turn's requested HTML output is saved, complete the [editable preview handoff](../motion-production/references/native.md#editable-preview-handoff) automatically, before export or delivery.+## 6. Export and checkApply the [production decisions](../motion-director/references/production-decisions.md) and [Motion review](../motion-director/references/motion-review.md) to time structure, key actions, joins and state; still frames that look similar do not replace a moving comparison. Do not restart original creative direction.diff --git a/skills/motion-template-to-video/SKILL.md b/skills/motion-template-to-video/SKILL.mdindex 6ee52f84..a7d4f20a 100644--- a/skills/motion-template-to-video/SKILL.md+++ b/skills/motion-template-to-video/SKILL.md@@ -15,7 +15,7 @@ The accepted installation experience follows [first-run defaults](../motion-prod## Open the supplied project-A template is a complete native HyperFrames project, not necessarily a catalog entry. For a supplied folder or ZIP, inspect/unpack it and make a working copy when editing or rendering is needed; resume that copy on later turns. Read `index.html`, native configuration and `TEMPLATE.md` (older templates may have `EDITING.md`/`REPLICA.md` instead) for changes or a fresh render. Unchanged preview delivery only needs the preview's identity and decode check. Preserve source, assets and hidden Studio manifests. Do not require `template.json`, a local template ID or catalog registration.+A template is a complete native HyperFrames project, not necessarily a catalog entry. For a supplied folder or ZIP, inspect/unpack it and make a working copy when editing or rendering is needed; resume that copy on later turns. Read `index.html`, native configuration and `TEMPLATE.md` (older templates may have `EDITING.md`/`REPLICA.md` instead) for changes or a fresh render. Unchanged video delivery needs the preview's identity and decode check, plus the editable preview handoff below. Preserve source, assets and hidden Studio manifests. Do not require `template.json`, a local template ID or catalog registration.If the user selected a gallery/catalog item instead, read its exact source/guide and ID, then follow [catalog capabilities](../motion-production/references/templates.md). Bundled projects use `motion_create_project` with projectType=template, templateId, requestId, title and requirements only when the selected project has not already been created. Editable registry sources are inspected and adapted from their real source and assets; builtin and Prism catalog templates can create a project with projectType=template. For discovery call motion_list_templates, read or grep/jq the returned local JSONL index, and call motion_get_template for the chosen ID. Known IDs can go directly to motion_get_template. Preserve the instructions and review limitations in TEMPLATE.md. An external reference video is not an editable template: ordinary video recreation uses [motion-recreate](../motion-recreate/SKILL.md); a request to produce a reusable template uses [motion-video-to-template](../motion-video-to-template/SKILL.md). Correct the route once, carrying the selected source and scope, rather than substituting an unrelated example.@@ -31,7 +31,7 @@ With no requested changes to the supplied template, deliver its `preview.mp4`, wnode /absolute/path/to/hyperframes/bin/hyperframes.mjs render /absolute/path/to/project-copy -o /absolute/path/to/output.mp4```-Do not open a browser unless the user asks to preview or use the editor. Native lint, snapshots and rendering work in the background. For plugin-managed projects, request MP4 through `motion_export_request` with projectId, requestId, versionId and expectedRevision; poll `motion_get_project` with projectId/exportJobId. Lint and technical verification are automatic; inspect the actual completed job report and review visuals/audio separately. There is no separate public inspection or verification Tool. For a draft-only lint/timeline/info check without opening Studio, use the pinned native CLI when the host supports it.+Native lint, snapshots and rendering can run in the background; complete the editable preview handoff below when the HTML is ready. For plugin-managed projects, request MP4 through `motion_export_request` with projectId, requestId, versionId and expectedRevision; poll `motion_get_project` with projectId/exportJobId. Lint and technical verification are automatic; inspect the actual completed job report and review visuals/audio separately. There is no separate public inspection or verification Tool. Use the pinned native CLI for lint/timeline/info checks before the HTML is ready.Before editing, ask the user when the request needs facts or assets only they can supply (brand, product, claims, prices, images), or when an ambiguous request would materially change the result. Ask all needed questions at once. Decide minor layout and timing details yourself and mention them briefly. Do not ask anything for an unchanged render.@@ -39,11 +39,15 @@ With requested changes, apply the shared edit workflow to the current working prWhen a reading hold shifts later pictures, inspect existing audio timing too. Preserving the audio file does not prove synchronization or continuous sound. Report any retained mismatch or silent tail; do not introduce audio generation services to resolve it.+## Open the editable result++Once this turn's requested HTML is ready, complete the [editable preview handoff](../motion-production/references/native.md#editable-preview-handoff) automatically, before export or delivery. This applies to unchanged templates, edited templates and drafts, including requests that only mention the video. Copying an existing `preview.mp4` still follows this step when the template HTML is available; it does not require a fresh render. Use the same working project and report any independent-folder adoption limitation described in the handoff.+## Verify and deliverFor an unchanged request delivered from `preview.mp4`, only probe that the copied file exists and decodes; do not compare it with anything. If you had to render because there was no preview, decode/probe the output and inspect representative frames. For an edited request, decode/probe the actual exported MP4 and inspect representative frames.-For an edited request, inspect the requested content, its related layout/timing and unchanged sections against the template's `preview.mp4`. Verify that supplied replacement assets are actually used and old brand content does not remain at another relevant appearance. Record passed, failed and unrun checks separately in the copy's `TEMPLATE.md`. Save outputs in the current workspace and link them by absolute local path, with only the plain path in each link target; never a relative path or a temporary localhost URL. Keep the reply short and in the user's words: the MP4, the edited project when applicable, one or two sentences on what changed, and only the limitations the user would notice. For an unchanged request, the MP4 and one sentence are enough. Humans decide visual acceptance; do not give a subjective pass/fail verdict. Do not claim independent-agent verification unless a separate session actually performed it.+For an edited request, inspect the requested content, its related layout/timing and unchanged sections against the template's `preview.mp4`. Verify that supplied replacement assets are actually used and old brand content does not remain at another relevant appearance. Record passed, failed and unrun checks separately in the copy's `TEMPLATE.md`. Save output files in the current workspace and link them by absolute local path, with only the plain path in each link target. For the editable Studio page, use the exact previewUrl from the handoff. Keep the reply short and in the user's words: the MP4, the edited project when applicable, one or two sentences on what changed, and only the limitations the user would notice. For an unchanged request, the MP4 and one sentence are enough. Humans decide visual acceptance; do not give a subjective pass/fail verdict. Do not claim independent-agent verification unless a separate session actually performed it.For edited or freshly rendered requests, apply the relevant [review standards](../motion-director/references/motion-review.md); changed multi-scene relationships use [production decisions](../motion-director/references/production-decisions.md), and sound changes load the shared context's sound references. These standards do not restart original creative intake or impose a new style on the template. For a fresh managed export, follow [verification](../motion-production/references/verification.md) using the completed job/revision; reuse a matching existing job. Copied unchanged previews use only the existence/decode branch above and create no export job. Stop at the user's requested delivery stage; a draft or review-only request does not automatically render.diff --git a/skills/motion-video-to-template/SKILL.md b/skills/motion-video-to-template/SKILL.mdindex 558829a2..9f636a38 100644--- a/skills/motion-video-to-template/SKILL.md+++ b/skills/motion-video-to-template/SKILL.md@@ -39,7 +39,7 @@ Do not pass off playback of the entire reference, a full-frame image sequence, tRead the pinned native authoring guide and [runtime adapter](../motion-production/references/production.md). For a portable folder, create a separate working directory and use the pinned native CLI; this requires host filesystem/shell capabilities. For a managed project, reuse its projectId or create a carrier with `motion_create_project`: use projectType=reference_video with an actual HTTP(S) referenceUrl or known referenceVideoId; for a local video use projectType=natural_language and record the local reference/checksum in requirements. Include requestId, title and requirements. Creation records the source but does not analyze or recreate the video. Read sources/current versions with `motion_get_project`, import supported image/audio/video files with `motion_import_assets`, and save native text through `motion_edit_project` with projectId, requestId, expectedRevision and expectedVersionId. Read the new version after imports or GUI changes. Do not assume a catalog ID exists, write reserved metadata, or bypass managed-project version protection with direct filesystem writes.-Read the guide via resources/read `motion://engine/SKILL.md`; managed project details return authoringGuide/hyperframesCli paths. Do not call `motion_open_preview` just to obtain paths: it runs lint and selects an existing project in Studio. Keep routine work in the background; only use it and the host browser when the user requests the editor/preview. The nine public Tools do not download/analyze video, compare videos or package ZIPs. Use available host capabilities for those steps, and report a concrete capability gap instead of inventing a Tool or claiming a portable package was delivered.+Read the guide via resources/read `motion://engine/SKILL.md`; managed project details return authoringGuide/hyperframesCli paths. Do not call `motion_open_preview` just to obtain paths: it runs lint and selects an existing project in Studio. Initial template packaging can run in the background; follow-up content edits apply the shared [continuing-edit preview rules](../motion-production/references/native.md#continuing-edits), with explicit background requests taking precedence. The nine public Tools do not download/analyze video, compare videos or package ZIPs. Use available host capabilities for those steps, and report a concrete capability gap instead of inventing a Tool or claiming a portable package was delivered.Use [reference measurement](references/measure.md) for questions that need exact timing, dimensions or layout. Use [rebuild guidance](references/rebuild.md) for grouping, media and edit dependencies. For an unfamiliar or difficult visual system, a short representative segment can establish a useful approach before expanding the film; this is advice, not a mandatory extra stage.diff --git a/template-catalog.ts b/template-catalog.tsindex fd2291fa..74192532 100644--- a/template-catalog.ts+++ b/template-catalog.ts@@ -43,7 +43,7 @@ export function templateRecipe(template: GalleryTemplate) {- 描述:${template.description || template.subtitle}${template.previewUrl ? '- 参考视频:' + template.previewUrl + '\n' : ''}${template.posterUrl ? '- 参考封面:' + template.posterUrl + '\n' : ''}${template.sourceUrl ? '- 原始来源 / 源码清单:' + template.sourceUrl + '\n' : ''}通过安装的专业 Skill 或 resources/read motion://workflow/${template.kind === 'reference' ? 'recreate' : 'template'}/start,读取对应入口及共享 context;template 接入 motion-template-to-video,recreate 接入参考视频复刻流程(先读用户资料、最多问一次、在编辑器工程中重建并按数字测量核对)。沿用已选 ID 与本次范围,不返回 production/start 重做选路。先核对项目与已完成操作;原生编写前读取固定引擎指南 motion://engine/SKILL.md 与共享 native / production 规范。-复刻完成后由宿主打开完整 previewUrl,保留默认 embed=1 及工程路由,仅展示编辑器;需要回到完整会话时使用 sessionUrl。+Once the requested HTML output is ready, follow the shared native guide’s editable preview handoff automatically: call motion_open_preview({projectId}), then open its exact previewUrl in the host built-in browser before export or delivery. Preserve embed=1 and the project route; use sessionUrl for the full workspace.${isEditableTemplate(template)? '若尚未创建该模板工程,调用 motion_create_project,projectType=template,templateId 使用上方 ID,传 requestId/title/requirements。它创建独立可编辑工程,保留旧工程与素材;随后通过 projectId 读取详情。'@@ -51,7 +51,7 @@ ${isEditableTemplate(template)由当前 Agent 重建原生 Hyperframes HTML compositions、可 seek 的 GSAP 动画及音视频轨道。先用 motion_create_project 创建 natural_language 或 reference_video 载体;用 motion_import_assets 批量导入真实媒体,通过 motion_edit_project(projectId、requestId、当前 expectedRevision/expectedVersionId)写入原生 index.html、compositions/、CSS、JS。原生 CLI 的 catalog/add 能力以当前 authoringGuide 为准。不要把所选参考替换成不相关的本地示例,也不能将原视频整段放进时间轴就宣称完成复刻。`}-完成后用 motion_open_preview 的原生 lint 与实际预览检查,必要时按固定指南使用原生 CLI 查看 timeline/info,修复问题,与参考比较画面和运动;保留可继续编辑的原生工程。无法完成的细节说明适配范围。starter 默认停在可编辑草稿;本次用户明确要求成片或导出时,按共享验证规范渲染并校验真实文件,不再要求重复授权。`;+Use the returned native lint and actual preview to check the completed HTML; repair failures and compare visuals/motion where applicable. Use the pinned native CLI for timeline/info when needed and preserve the editable project. 无法完成的细节说明适配范围。starter 默认停在可编辑草稿;本次用户明确要求成片或导出时,按共享验证规范渲染并校验真实文件,不再要求重复授权。`;}export function readTemplate(id: string) {const template = getTemplate(id);@@ -59,5 +59,5 @@ export function readTemplate(id: string) {return { ...template, engine: 'hyperframes', instructions: templateRecipe(template),workflow: template.kind === 'builtin' ? 'motion_apply_template' : 'motion_import_asset + motion_write_files',workflowGuide: { workflow, section: 'start', status: workflowRegistry[workflow].status },- authoringGuide: 'Call motion_open_preview and read its authoringGuide for the pinned Hyperframes runtime before writing native sources.' };+ authoringGuide: 'Read motion://engine/SKILL.md or the authoringGuide path returned by motion_get_project before writing native sources; complete the shared native editable preview handoff after the requested HTML is ready.' };}