SkillsGrove
SkillsGrove/Video production/keng1304/video-breakdown/video-breakdown

video-breakdown

Installation

$npx skills add https://github.com/keng1304/video-breakdown --skill video-breakdown
$git clone --depth 1 https://github.com/keng1304/video-breakdown.git /tmp/video-breakdown && mkdir -p ~/.claude/skills && cp -r /tmp/video-breakdown/skill ~/.claude/skills/video-breakdown
Please install this Agent Skill for me: https://github.com/keng1304/video-breakdown/tree/a8188e148ed07381ee91915d78da3462474c016a/skill — read its SKILL.md and scripts first, and only install it into my skills folder once you have confirmed it is safe.

Summary

Original description · MIT🔍 影片拆解 — 貼連結或本地檔即可全自動分析影片:鏡頭切分、關鍵幀截取、運鏡軌跡、景別偵測、色彩指紋、音樂結構,最後用 Claude Vision 產出每鏡描述 + Seedance/Kling prompt。當使用者丟一支影片問「這怎麼拍的」「幫我分析」「我想複製這個感覺」時觸發。觸發關鍵字:「影片拆解」「拆解影片」「分析影片」「拆這支」「這支片怎麼拍的」「參考片分析」「鏡頭分析」「運鏡分析」「reverse engineer」「breakdown this video」「怎麼拍的」「競品怎麼拍」。
The SKILL.md below is reproduced from keng1304/video-breakdown (commit a8188e1) under the MIT license. The text is unchanged; only the file header metadata is omitted, images are shown as links, and very long files are truncated. Copyright 2026 tzukaoltd.com. License: LICENSE. Only the instructions file is shown; see the original repository for any scripts.

Video Breakdown — 參考影片分析引擎

把任何一支影片(YouTube / Vimeo / IG Reels / 本地檔)變成結構化資料:

  • 鏡頭切分 + 每鏡秒數
  • 每鏡關鍵幀截圖
  • 運鏡軌跡(推/拉/搖/軌道/手持/空拍)
  • 景別(大特寫 / 特寫 / 中景 / 全景 / 大全景)
  • 色彩指紋(主色調 top-5)
  • 音樂結構(intro / verse / drop / outro, BPM)
  • 每鏡 Seedance / Kling prompt(可直接拿去生類似影片)

前提

此 skill 綁本地 Python 專案(透過 install.sh 安裝的 video-breakdown repo)。 執行前請確認:

  • 已跑過 ./install.sh(安裝 brew 依賴 + uv + Python 套件)
  • .env 已填入 ANTHROPIC_API_KEY
  • preflight 通過:./preflight.sh

repo 路徑由環境變數 VIDEO_BREAKDOWN_ROOT 指定,預設為 $HOME/video-breakdown。


標準流程(5 階段)

🎞️ Phase 1 — 取得影片

  • 貼 YouTube / Vimeo / IG / 雲端連結 → yt-dlp 下載
  • 或本地檔直接指向路徑

✂️ Phase 2 — 鏡頭切分 + 關鍵幀

  • TransNetV2(PyTorch MPS)做 shot boundary detection
  • Fallback: PySceneDetect ContentDetector

🎥 Phase 3 — 多維分析(per-shot)

  • 運鏡:RAFT-Small ONNX → Homography 分解
  • 姿態:RTMPose (rtmlib ONNX)
  • 景別:人臉 / 全身比例推論
  • 色彩:K-means 5 色提取
  • 音訊:librosa BPM + beat + 結構

🎨 Phase 4 — 風格指紋

跨 shot 統計 cuts per minute、dominant shot sizes、signature camera moves、color fingerprint、music emotion。

📝 Phase 5 — Claude Vision 產 Prompt

每鏡關鍵幀送 Claude Vision,產 Seedance / Kling prompt + 中文描述。


快速呼叫

CLI

cd "$VIDEO_BREAKDOWN_ROOT"   # 預設 ~/video-breakdown
.venv/bin/video-breakdown analyze "<影片 URL 或本地路徑>"

常用 flag:

  • --skip-pose 跳過人體骨架(加速)
  • --skip-audio 跳過音頻分析
  • --no-prompts 只拆鏡不燒 Claude token
  • -o output/ 指定輸出目錄

檢視結果

.venv/bin/video-breakdown report output/<video_name>_analysis.json
.venv/bin/video-breakdown report output/<video_name>_analysis.json --prompts

重要提醒

  1. 參考影片不要超過 3 分鐘:3 分鐘約 5-8 分鐘可跑完
  2. Claude Vision 是可選:Phase 5 會燒 token,只要拆鏡頭可加 --no-prompts
  3. 垂直影片(IG Reels)支援:自動偵測 9:16
  4. 不支援直播串流:要完整 mp4 檔
  5. 首次執行會下載模型:TransNetV2 / RAFT / RTMPose 自動下載到 ~/.cache/(約 500MB-1GB)

子檔案索引

檔案 何時讀
workflow/phase1_download.md 各種影片來源處理
workflow/phase2_decompose.md 鏡頭切分細節
workflow/phase3_analyze.md 運鏡/景別/色彩/音訊分析
workflow/phase4_fingerprint.md 風格指紋邏輯
workflow/phase5_prompt.md Claude Vision + Seedance/Kling 格式
tools/cli_usage.md CLI 指令大全
View full license text (MIT)
MIT License

Copyright (c) 2026 tzukaoltd.com

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.