安装与下载
1 ClawHub CLI
从源直接安装技能的最快方式。
npx clawhub@latest install cut-as-code
2 手动安装
将技能文件夹复制到以下位置之一
~/.openclaw/skills/
{'/skills/'}
优先级:工作区 › 全局 › 内置
3 提示词安装
将此提示词复制到 Openclaw 即可自动安装。
请帮我使用 Clawhub 安装 skill-cut-as-code。如果尚未安装 Clawhub,请先安装(npm i -g clawhub)。
更倾向于下载?
获取包含原生技能文件的ZIP压缩包。
基本信息
cut-as-code
安装指南
- ClawHub CLI
从源直接安装技能的最快方式。
npx clawhub@latest install cut-as-code - 手动安装
将技能文件夹复制到以下位置之一
全局模式
~/.openclaw/skills/
工作区
/skills/
优先级:工作区 > 本地 > 内置 - 提示词安装
将此提示词复制到 OpenClaw 即可自动安装。
请帮我使用 Clawhub 安装 cut-as-code。如果尚未安装 Clawhub,请先安装(npm i -g clawhub)。
更倾向于下载?
获取包含原生技能文件的ZIP压缩包。
下载技能 (.zip)
什么是
Cut as Code 是 Project Protocol V1 视频工作的强制入口。它会确定所需的交付成果,必要时检查明确的项目状态,并将任务交给负责所需操作的技能,例如剪辑、调色、字幕、B-roll 或 Shorts。此 Openclaw Skills 工作流确保路由过程只读,并依据已记录的项目状态,而非根据恰好存在的文件作出假设。
对于多操作请求,它会协调前置条件和明确的执行顺序,然后在所选操作通过检查后,将项目引导至一次共享的主渲染。该入口仅负责路由和恢复;所选叶级技能负责编辑决策、审核关卡、渲染细节和自检。
应用场景
在现有视频项目中继续指定的操作,无需重复无关的需求收集。
用户已明确指定交付成果时,从源文件或 URL 开始处理。
将请求路由到剪辑、调色、添加 B-roll、字幕、内容卡片、动态图形或制作 Shorts。
按文档规定的顺序协调多个请求的操作,并仅渲染一次共享的主交付成果。
将已验证的最终交付成果与原始内容进行比较,或完成已批准的短视频衍生内容。
在继续之前,识别缺失输入、含糊的交付成果、过期依赖项或无效项目状态。
工作原理
判断请求是指定现有项目中的某项操作、提供项目根目录、提供源文件和明确的交付成果,还是缺少足够信息而无法继续。
对于明确的项目根目录,检查 work/project.json、work/timeline.json,以及仅所选操作相关的计划或证据。将 work/project.json 视为共享清单,并根据记录的状态、修订版本、依赖项、检查结果和渲染状态确定进度。
根据请求的结果(而非偶然出现的关键词)匹配负责该任务的技能。如果交付成果含糊不清或缺少必要输入,请提出一个简洁的路由问题。
阅读所选技能的完整说明及所需子技能,然后移交任务。对于请求多个操作的情况,只冻结这些操作,只执行一次共享理解流程,并按规定顺序执行所选工作。
在各次移交之间重新读取项目状态。不要并行运行可能修改共享项目或渲染产物的技能,也不要重复已验证的工作。
活跃操作通过各自的关卡后,编译并渲染一次共享主交付成果。只有在用户提出要求时,才针对已验证的交付成果执行比较或 Shorts 最终处理。
配置指南
该技能未指定独立安装命令或包管理器。请在可使用此技能及其所路由的视频技能的环境中,将 Cut as Code 用作入口。
对于现有项目,请提供明确的项目根目录。仓库根目录不会自动被视为视频项目。
对于新工作,请提供源文件或 URL,以及预期的交付成果。该工作流会通过 /video-understand 路由初始化流程。
确保所选叶级技能及其所需子技能均可用;如果缺少某项,请停止并报告,而不要重新编写其说明。
对于渲染,文档指定的工具是来自 /video-understand 的 build_render_plan.py 和 render_project.py。只有在所选的活跃操作通过各自关卡后才运行它们。
从明确的项目根目录检查共享清单和时间线
cat work/project.json
cat work/timeline.json
数据架构
该工作流将明确指定的项目根目录视为视频项目的边界,并将 work/project.json 视为唯一的共享清单。它会读取 work/timeline.json 获取时间线状态,并在路由时仅查阅所选操作的计划或证据。
数据或状态 用途
work/project.json 共享项目清单;记录操作状态,并在各次移交之间重新读取。
work/timeline.json 时间线状态;更改可能使 Shorts 候选内容的批准失效。
操作计划和证据 特定操作的规划和验证输入;仅检查所选操作需要的内容。
操作元数据 使用 status、revision、based_on 和 check 确定进度,以及工作是否为最新且已验证。
渲染状态 用于确定交付成果是否存在,以及是否已准备好进行比较或衍生内容最终处理。
final.mp4 和 final/shorts/ Shorts 规划不得创建这些内容;只有在已验证的主交付成果存在后,才最终处理并提取已批准的衍生内容。
仅凭目录存在不能判定工作已完成。保留现有的用户更改和产物,不要重新运行已验证的工作,并在恢复请求的操作前解决缺失或过期的依赖项。
高级特性
根据交付成果,在理解、剪辑、调色、B-roll、动态图形、内容卡片、字幕、比较和 Shorts 工作流之间进行路由。
支持根据清单元数据、修订版本、依赖项、检查结果和渲染状态恢复项目状态。
按标准顺序协调多操作请求:剪辑、调色、B-roll、字幕、内容卡片,然后是动态图形。
采用分阶段 Shorts 工作流:先规划并审核候选内容,再添加字幕和叠加元素,最后在主交付成果通过验证后完成已批准衍生内容。
放置内容卡片和动态图形叠加元素时,保护主要人物或前景人物清晰可见的脸部和头部轮廓;如果无法合规放置,必须重新定位、重新设计提示,或跳过。
在负责该任务的技能允许时,接受全部跳过或零提示的有效结果;不会凭空编造填充工作。
保持路由只读,并将编辑决策、审核关卡、渲染细节和自检交由负责该任务的技能处理。
name: cut-as-code
description: >
Use when any cut-as-code request involves understanding, cutting, color grading,
adding B-roll, motion graphics, content cards, captions, creating shorts,
comparing, rendering, or resuming a Project Protocol V1 video project.
Cut as Code Entry Point
Use this as the mandatory entry point for cut-as-code video work. Own routing and project-state recovery only. The selected leaf skill owns editorial decisions, review gates, scripts, rendering details, and self-checks.
- Start From Project State
Apply the first matching row. Do not evaluate lower rows.
State Action
The user names a specific operation on an existing project Inspect only the state needed for that operation, then load its owning skill. Skip general intake.
An explicit project root contains work/project.json Read work/project.json, work/timeline.json, and only the selected operation's plan/evidence. Resume from recorded state. If the owner is not unique, ask one routing-only question.
The user supplies a source file or URL, no project, and a clear deliverable Load /video-understand to initialize the project and shared evidence, then continue to the requested operation.
No project/source or no intended deliverable is identifiable Ask one concise question requesting the missing project/source and desired result. Do not start a skill yet.
The project root must be explicit; never treat the repository root as a video project. Treat work/project.json as the only shared manifest. Determine progress from operation status, revision, based_on, check, and render state, not from directory presence. Do not re-run verified work. If a dependency is missing or stale, complete that dependency first and then resume the requested operation.
Routing is read-only. Never repair, reset, approve, remove, or activate an operation while deciding where to send the task.
- Route by Deliverable
Match the requested output, not a keyword mentioned in passing.
Requested result Owning skill or workflow
Probe, transcript, objective analysis, semantic understanding, or new project initialization /video-understand
Tighten, shorten, remove weak sections, or create a first/rough cut /video-cut after /video-understand
Correct color, create/select a look, or deliver/apply a LUT /video-color-grade; use its standalone path only when the user explicitly wants no Project Protocol delivery
Add transcript-timed visual cutaways /video-add-b-roll after /video-understand
Add sourced motion graphics or animated semantic overlays /video-add-motion-graphics after /video-understand
Add titles, lower-thirds, statistics, quotes, chapters, or calls to action /video-add-content-cards after /video-understand
Add subtitles, captions, or karaoke captions /video-add-captions after /video-understand
Compare the original with actual final pixels in source time /video-edit-compare after the verified main delivery exists
Select, review, and plan short-form ranges /video-to-shorts after /video-understand; do this before requested content cards and captions
Finalize and extract approved horizontal or vertical short-form derivatives Resume /video-to-shorts after the verified main delivery exists
Compile or render an existing Project Protocol delivery Use build_render_plan.py and render_project.py from /video-understand after every selected active operation passes its own gate
A generic request such as "edit this video" does not uniquely select /video-cut. Ask one routing question unless the desired output is clear from existing project state or the surrounding request.
- Orchestrate Multi-Operation Requests
Freeze only the operations the user requested; never turn the route table into a default package. Run the shared understanding prerequisite once. Execute selected main-sequence operations in canonical order:
cut -> color-grade -> b-roll -> captions -> content-cards -> motion-graphics
For a request that includes Shorts, content cards, or captions, use this staged flow:
/video-understand -> /video-to-shorts plan and candidate review only -> /video-add-captions -> /video-add-content-cards -> /video-add-motion-graphics -> compile and render the shared main delivery once -> /video-to-shorts finalize and extract approved derivatives
Complete any requested timeline-changing operation, such as /video-cut, before Shorts planning; a changed work/timeline.json invalidates candidate approval. Shorts planning writes shared plan/review state and must not create final.mp4 or anything under final/shorts/. Captions, content cards, and motion graphics then add their own shared plans and overlay contributions in that relative order. The same order applies when only any pair is selected: captions first, content cards second, motion graphics last. Re-read work/project.json before each handoff. Do not run leaf skills concurrently when they can write work/project.json, work/timeline.json, an operation plan, or shared render artifacts. Build and render the main delivery once, after all selected active operations validate. Run /video-edit-compare and only the finalization/extraction phase of /video-to-shorts against that verified delivery; shorts remain outside sequences.main.operations.
For /video-add-content-cards and /video-add-motion-graphics, reserve the visible face and head silhouette of every primary or foreground person, speaker, presenter, interviewee, or semantically important person for the complete cue. Incidental background-only people who are not a narrative or visual focus are exempt; protect uncertain cases. If an overlay touches a protected face or head, reposition it first, then scale or redesign it; skip the cue when no compliant placement exists.
An all-skipped or zero-cue result is valid when the owning skill permits it. Do not invent filler work to keep an operation active.
- Hand Off, Then Leave
Read the selected skill's complete SKILL.md and every required sub-skill before acting. For one operation, hand off once and leave this entry point. For a requested multi-operation run, enter one owner at a time; after its self-check, recover project state and continue to the next frozen operation without reopening intake.
Do not ask the user to approve a route that is already unambiguous. User interaction belongs only to missing inputs, genuine routing ambiguity, credentials, or the editorial/review decisions required by the owning skill. Never substitute an Agent decision for a required human decision unless the user explicitly delegates it.
Example
For "continue this understood and cut project by adding captions," read the current project and timeline revisions, then enter /video-add-captions. Do not re-transcribe, re-cut, or ask whether captions are the intended route. An unrelated pending operation does not change the route, though an active unverified operation may block the final shared render and must be reported by the compiler.
Failure Rules
Invalid project state: report the exact validation problem; never reinitialize over it.
Missing leaf skill or prerequisite: stop and name it; do not reconstruct it from memory.
Missing source/project path: ask for it in the single routing question.
Conflicting requested outputs: ask which deliverable owns the current run.
Existing user changes or artifacts: preserve them and work with the recorded state.
电子邮件设计
Chelaile 实时公交