Communitygithub.com

edit-video:口播原片直出 YouTube 成片

把口播原始素材剪成 YouTube 16:9 和 Instagram 9:16 成片的 Agent 技能:转写、精剪、动态图形、B-roll、音效、可选配乐、逐词字幕、-14 LUFS 母带和成片校验。支持英语、印地语、泰卢固语及混说。

edit-video:口播原片直出 YouTube 成片 是什么?

YouTube 单集配方第 1 步(剪辑),来自 SrigadaAkshayKumar/ai-video-editor(2026-10-09 发布;README 附有成片 16:9 联系表,并介绍了每天在 GitHub Actions 上自动跑的无脸频道流水线)。把原片丢进 inbox/talking/,说一句「剪 video-1,节奏快一点」即可。Agent 会把你的风格描述翻译成参数,转写(英语用 Whisper,泰卢固语/印地语用 ElevenLabs),精剪掉重说、口误和空白,写视觉方案(6 种画面布局、28 种动态图形和 B-roll),用 Remotion 渲染画面,HyperFrames 做逐词字幕,ffmpeg 混音效和可选 CC0 配乐,母带 -14 LUFS,最后校验时长、响度、冻帧和每个剪辑点。所有决定都存在 JSON 文件里,任何一步都能单独重做。它会汇报剪掉了什么、为什么,并坦白自己听不到混音。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/SrigadaAkshayKumar/ai-video-editor/tree/HEAD/.claude/skills/edit-video

在你喜欢的 AI 中提问

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

文档

edit-video — 人物讲述 → final-16x9.mp4 + final-9x16.mp4

你是剪辑师。tools/中的工具负责机械性的工作;你做出所有编辑决策 并将它们保存在文件(work/edl.json、work/visual-plan.json、work/audio-plan.json)中,以便任何阶段 都可以重做。每轮会话阅读一次 docs/lessons.md —— 那里的每一条规则都是用一次渲染失败换来的。

架构(为什么这样设计)

raw ─ transcribe ─ cut ─┬─ work/cleancut.mp4 ──────────────┐
                        │                                    │ (对白)
       visual-plan.json ┴─ Remotion `Doc`(静音) ×2 种格式  │
                             └─ HyperFrames 字幕通道 ×2      │
       audio-plan.json ─────────────── tools/mix.mjs ◄───────┘ → work/mix.wav(一次性)
                                                     finalize: 画面 + -14 LUFS 母带 + 开场/片尾
  • Remotion 渲染整个画面:a-roll 使用六种舞台布局之一(全屏 / 左 Dock / 右 Dock / 带状 / 角落 / 全面展开),28 种动态图形类型,b-roll 插入镜头,镜头运动,章节导轨。
  • HyperFrames 仅绘制单词级字幕(浏览器排版可正确渲染泰卢固语/印地语)。
  • ffmpeg 处理所有音频:任何渲染中都没有 <audio> —— 在此仓库继承的模板中,嵌入音频反复破坏了对白。
  • 两种格式共用一条干净剪辑的时间线、一个视觉方案和一个混音。

阶段

#阶段工具技能 / 说明
0导入`npm run new -- --brief "…" [--lang tehi
1转录npm run transcribe -- <p>英语 → whisper(免费)· 泰卢固语/印地语 → ElevenLabs
2纯净剪辑npm run cut -- <p> [--dry-run]clean-cut 技能。最重要的阶段。
3视觉方案编写 work/visual-plan.json;npm run visuals -- <p> --check;--stills t1,t2motion-graphics 技能
4B-roll`npm run broll -- searchget`
5渲染画面npm run visuals -- <p>每格式每分钟视频约需 1-2 分钟
6字幕npm run scaffold -- <p>(+ npm run captions -- <p> --style …)captions 技能
7音频方案编写 work/audio-plan.json;npm run sfx -- list;`npm run bgm -- searchget;npm run mix -- `
8最终处理npm run finalize -- <p>校验、渲染、母带、开场/片尾、output/credits.md
9验证npm run verify -- <p> → 阅读两个 work/verify-*/sheet.jpg切勿跳过
10打包youtube-metadata、youtube-thumbnail 技能在最后提供

npm run status 显示进度。重新剪辑后:node tools/retime.mjs <p> 将两个方案迁移到新的时间线(旧 clean → raw → 新 clean)并列出所有被剪掉的时刻。

运行步骤

  1. 导入。 用户将剪辑放入 inbox/talking/,并在提示中命名(“edit video-1 …”,可能写作“/video-1” —— 去掉斜杠)。npm run inbox 列出等待中的文件。 npm run new -- video-1 --brief "<用户的风格描述,原样>"(如果用户提到了 --lang 就加上,--keyterms 用于人名/品牌)。提示中的风格指令就是 brief —— 在规划之前将其映射到设置中(参见“风格 brief → 设置”)。不要问提示中已经回答的任何问题。 品牌/频道:默认无 —— 此仓库为多位客户编辑。只有当用户说明视频所属时,才加载 config/brands/<slug>.json(或者根据用户提供的信息创建它),并传递 --brand;如果用户要求开场/片尾,则从 inbox/brand/ 传入 --intro/--outro 剪辑。
  2. 转录,然后通读 work/transcript.md。检查头部信息中的 engine 和 language。
  3. 纯净剪辑 —— 严格遵循 clean-cut,包括边界审计和脆弱词输出。
  4. 规划视觉 基于 work/cleancut.transcript.md(纯净剪辑的时间码)。编写方案,--check 它(验证每个组件的必填字段 —— 这是模板中排名第一的静默缺陷),修复,然后在 6-10 个有趣的时间点渲染 --stills,并在完整渲染之前在两种格式下阅读它们。取景:如果说话人在 9:16 中偏离中心,设置 "framing": {"9:16": "40% 45%"}。
  5. 渲染画面、搭建字幕框架、规划音频并混音、最终处理、验证。
  6. 报告:两个输出路径;原始 → 纯净剪辑的时长以及被剪掉的内容(按原因);叠加/B-roll/SFX 数量;使用的音乐;任何脆弱或不确定之处;必须在视频描述中显示的致谢;并明确说明你无法听到混音 —— 请用户聆听衔接处、背景音乐电平和闪避效果。提供 /youtube-metadata 和 /youtube-thumbnail。

风格 brief → 设置

将用户的话转化为具体选择,并在规划前用一行说明:

用户说设置
快速 / 充满活力 / 短视频 / 有力keepPauseMax 0.25,字幕 pop 2-3 词,每 2-4 秒一个节拍,镜头冲击,结构处的子带 SFX
平静 / 专业 / 纪录片 / 长视频keepPauseMax 0.4-0.5,字幕 clean 4-6 词,每 6-10 秒一个节拍,较少的 SFX,柔和的背景音
极简 / 干净 / 不繁琐少量叠加(只在有用处使用文字标记),无 marquee/glitch,clean 字幕或无需字幕
大胆 / 高档 / 新闻 / 社论--style broadcast,高对比度强调色
讲故事 / 感性karaoke 字幕,piano/cinematic 背景音,关键台词处留音乐空白
“不要音乐” / “不要 SFX” / “不要字幕” / “不要 B-roll”完全遵守;跳过该阶段
(未提及音乐)无 BGM —— 用户在提示开始时说明是否添加音乐;默认为无。添加时:仅 CC0(--cc0),且 SFX 必须在其上明显可闻
一种颜色(“使用黄色”、十六进制代码)字幕 --accent,叠加的 section 强调色/品牌色

任何 brief 中的异常内容都覆盖这些默认值。将 brief 保存在 project.json.brief 中,以便后续重新编辑遵循相同的风格。

审核关卡

默认:直接运行并报告。如果用户要求检查点(或 project.json.review 为 "stages"),则在纯净剪辑后、视觉方案后(展示静态帧)和音频方案后停止。请求的更改是该阶段的最高标准 —— 修改后在同一阶段再次展示。

规则

  • 所有方案的时间均基于纯净剪辑时间线;EDL 时间基于原始素材。
  • 默认情况下,叠加文字为简短短语(母语文字位于字幕中),除非 brief 另有说明。
  • 切勿手动编辑生成的文件(compositions/captions.html、work/props-*.json)—— 请重新生成。
  • .env 中的密钥:ELEVENLABS_API_KEY(泰卢固语/印地语)、PEXELS_API_KEY 或 PIXABAY_API_KEY(B-roll)。缺少某密钥时 → 停止并明确指出缺失的密钥,并说明应将其放在 C:\AI-edits\.env 中。
  • Windows:使用 Write 工具编写 JSON(PowerShell 会破坏内联 JSON;Out-File/Set-Content 会添加 BOM —— 工具在 JSON 中可以容忍,但切勿以这种方式编写代码文件)。
  • 一旦用户确认最终版本,进行清理:render/、work/visuals-*.mp4、work/captioned-*、work/stills-*、work/verify-* 都是可重新生成的。保留 output/、work/*.json、assets/。

Individual skills in this repo

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

SrigadaAkshayKumar/ai-video-editor

Turn a finished AI-edits video (projects/<p>, or several parts of one long video) into YouTube Shorts. Reuses the edit's word timestamps, reads the whole transcript, picks self-contained dialog moments, adds text hooks + comment prompts, renders 9:16 clips with Remotion. Use when the user asks to clip/make shorts from an edited project or a long video.

SrigadaAkshayKumar/ai-video-editor

Choose, fetch and place background music for an edit — Openverse search (commercial-use CC, or CC0-only), music_cues in work/audio-plan.json with fades, offsets and a deliberate silence gap; tools/mix.mjs conditions every bed, sets it to one measured house level under the voice and sidechain-ducks it. Use when adding, swapping or re-levelling music.

SrigadaAkshayKumar/ai-video-editor

Generate and style word-synced captions (Telugu, Hindi, English, code-mixed) as the HyperFrames captions pass over each format's Remotion picture, fix caption text, black captions out under on-screen text, and check caption content at every cut join. Use when creating, restyling, correcting or repositioning captions in any edit.

SrigadaAkshayKumar/ai-video-editor

Editorial rules for turning a raw talking video or voiceover into a clean cut — removing retakes, repetitions, false starts, stutters, fillers, mispronounced words, contradictions/inconsistencies, off-script chatter and dead air — by writing work/edl.json for tools/cut.mjs. Telugu, Hindi, English and code-mixed speech. Use for stage 2 of edit-video or whenever the user asks to tighten/re-cut a video.

SrigadaAkshayKumar/ai-video-editor

Turns a bare voiceover (no presenter on camera) into a finished faceless documentary/explainer for YouTube 16:9 and Instagram 9:16 — clean-cuts the narration, DIRECTS it (story spine, tension curve, hooks, involvement beats), researches the claims and screenshots the real sources, plans a scene track (stock b-roll, stills, news screenshots, pure-graphic beats) with motion graphics, designs music + SFX, renders, captions and credits it. Use when the user gives a voiceover/narration file (or says "faceless video", "make a video from this VO", "documentary").

SrigadaAkshayKumar/ai-video-editor

Plan the picture of an edit in work/visual-plan.json — motion graphics (28 component types across six stage layouts that dock/shrink/dim the video), b-roll cutaways from Pexels/Pixabay, camera moves, a-roll framing for 9:16 — validate it, QA it with stills in both formats, and render it with Remotion. Use for any titles, charts, stats, lower thirds, diagrams, b-roll or zooms in a talking-head or faceless edit.

SrigadaAkshayKumar/ai-video-editor

Design the sound effects of an edit in work/audio-plan.json sfx_events — which effect, where, how often — using the measured SFX library (repo assets/sfx, HyperFrames' bundled set, CC0 fetches from Openverse) and the spectral rule that sub-band cues carry structure while vocal-band cues are rationed. Mixed and levelled by tools/mix.mjs. Use when adding or adjusting SFX in any edit.

SrigadaAkshayKumar/ai-video-editor

Write the upload package for a video this repo edited — YouTube title options, description with chapters, tags, pinned comment, thumbnail text, and the Instagram Reels caption + hashtags for the 9:16 cut — optimised for whichever channel/client the user says it is for (config/brands/ profiles, only when named). Use when the user asks what to title a video, for a description, tags, chapters, "the YouTube metadata", an Instagram caption, or SEO/CTR advice on a finished render.

SrigadaAkshayKumar/ai-video-editor

Design and build a high-CTR thumbnail for a video this repo edited — hook selection, the real face frame pulled from the footage, background cut-out, type set with real fonts (Telugu/Devanagari included), the YouTube 1280x720 thumbnail and the Instagram 1080x1920 cover, an optional image-generation prompt for the background layer, and a feed-size legibility check. Use when the user asks for a thumbnail, thumbnail ideas, a cover image, or how to make the thumbnail more clickable.

相关技能