video-style-cloner

ویدیوی جدیدی بسازید که ریتم و زبان بصری ویدیوی مرجع را بازآفرینی کند.

این Skill ویدیوی مرجع شما را از نظر ریتم تدوین، طول شات‌ها، BPM، transitionها، پالت بصری و حرکت دوربین تحلیل می‌کند و سپس یک storyboard شات‌به‌شات برای محتوای جدید می‌سازد.

پس از تأیید storyboard، تولید شات‌ها با چند agent موازی انجام می‌شود، هر شات به‌صورت مستقل بازبینی می‌شود و خروجی نهایی MP4 با FFmpeg و renderer مناسب assemble می‌شود. این فرایند برای ساخت ویدیوهای الهام‌گرفته از یک نمونه، بدون کپی‌کردن assetها یا موسیقی دارای حق نشر، کاربردی است.

چه چیزی می‌گیرید

  • تحلیل ساختاری و بصری ویدیوی مرجع و استخراج Style DNA
  • storyboard دقیق با زمان‌بندی، حرکت دوربین، transition و ارجاع به شات‌های مرجع
  • تولید موازی شات‌ها با رعایت سبک‌های پشتیبانی‌شده‌ی 2D
  • بازبینی مستقل هر شات و ثبت مقایسه‌ی before/after برای اصلاحات
  • خروجی نهایی MP4 و امکان re-render شات‌های مشخص بر اساس feedback زمان‌دار

برای چه کاری خوب است

  • ساخت brand video، launch video یا محتوای شبکه‌های اجتماعی بر اساس سبک یک ویدیوی نمونه
  • تبدیل یک reference video یا لینک YouTube به ویدیویی تازه درباره‌ی محصول، برند یا داستان شما
  • تیم‌هایی که به storyboard، کنترل کیفیت چندمرحله‌ای و تولید موشن‌گرافیک 2D نیاز دارند

برای چه کاری نیست

  • برش ساده، تدوین معمولی یا ساخت subtitle بدون reference video
  • بازسازی مستقیم footage، شخصیت، لوگو یا موسیقی دارای حق نشر
  • پروژه‌هایی که به رندر سه‌بعدی یا اجرای کامل live-action نیاز دارند

دربارهٔ این اسکیل

<!--
╔═══════════════════════════════════════════════════════════╗
║ VIDEO STYLE CLONER: AGENTIC SKILL ║
║ Adapted from edenfunf/reelmimic (MIT) ║
║ Skillified by Mamdouh Aboammar for universal agents ║
╚═══════════════════════════════════════════════════════════╝
-->

Video Style Cloner

Show an AI agent a video you love. Get a new video in the same style.
The host agent analyses, plans, produces and reviews using the available tools. Production requires an approved storyboard and an installed renderer.

$$\text{Reference Video} \xrightarrow{\text{Phase 1: Analyse}} \text{Style DNA} \xrightarrow{\text{Phase 2: Plan}} \text{Storyboard} \xrightarrow{\text{Phase 3: Produce}} \text{Multi-agent Shots} \xrightarrow{\text{Phase 4: Review}} \text{Final MP4}$$


When to activate

Activate on:

  • "make a video like this / in this style"
  • "clone this video's style"
  • "create something similar to [URL or file]"
  • "video inspired by / based on the style of"
  • user provides video + a creative brief for new content
  • "mimic / copy the aesthetic / editing rhythm of this video"

Do NOT activate on:

  • Simple video trim or subtitle requests → use general-video skill
  • No reference video provided → ask for one first
  • 3D rendering requests → skill handles only 2D, explain and proceed with nearest 2D style

Absolute Rules (inherited from source)

  1. Style only - no assets: Learn technique from reference, never copy footage, characters, logos, or licensed music.
  2. 2D only: Current track supports 2D animation styles only. If reference is 3D or live-action, reproduce rhythm/composition/mood in closest 2D style and inform the user.
  3. User-provided lyrics: Never transcribe, invent, or quote song lyrics. Only use text the user explicitly provides.
  4. Evidence-gated fixes: Every "fixed" shot must include before/after frame comparison. A reviewer validates the evidence before accepting the fix.
  5. Human approval gate: Storyboard/plan must be approved before production starts (unless user explicitly said "just do it" or "decide yourself").
  6. Asset attribution: Log every fetched asset (source, author, licence) in ASSETS.md. Unknown licence → flag "Licence unconfirmed".

Set SKILL_DIR to the absolute path of this video-style-cloner directory before running commands. Engine entry points are named skills/<engine>/<engine>.md.

The optional Rust CLI coordinates project-provided render/review adapters. It does not generate creative assets or supply an AI reviewer by itself. Read engine/README.md before using it. Its technical smoke example proves encoding and approval flow, not visual style fidelity.

Required Tools / Runtime

Read references/runtime.md for version requirements and install commands.

ToolPurposeMin Version
Pythonanalyse.py, align_lyrics.py, fetch_assets.py3.10+
FFmpegAudio/video encoding, frame extraction6.0+
yt-dlpDownload YouTube reference (analysis only)latest
Node.jsHyperFrames animation renderer22.18+
faster-whisperLyrics timestamp alignment0.10+

Phase 0: Intake

Collect from the user:

InputRequiredDefault
Reference videoYESNone
Creative brief (what new video is about)YESNone
Target lengthNo30 s
Aspect ratioNo16:9
Music/audio fileNoSilent or user-provided
LRC/lyrics textNo (needed if lyrics appear in video)None
Character design sheetsNoAI-designed original characters

Create project workspace:

projects/<slug>/
├── analysis/          # Output from analyse.py
├── inputs/            # User-provided files (audio, lyrics, design sheets)
├── assets/            # Fetched CC0/CC-BY assets + ASSETS.md log
├── build/             # production.json, rendered frames
├── out/               # Final MP4 output
└── STORYBOARD.md      # Approved plan

Phase 1: Analyse Reference

python "$SKILL_DIR/skills/video-clone/scripts/analyze.py" "<file_or_url>" \
  --out projects/<slug>/analysis

This script produces:

  • report.json: video metadata under video, audio measurements under audio, editing rhythm under pacing, and each shot's nested camera and look measurements under shot_details. Read references/shot-analysis.md for the emitted schema.
  • sheet_1fps.jpg: one frame per second contact sheet
  • sheet_scenes.jpg: one frame per scene break

After running, visually inspect sheet_1fps.jpg and sheet_scenes.jpg using the Read tool. Then write analysis/STYLE.md:

# Style Analysis

## Medium (REQUIRED — first line, determines skill routing)
2d-painted | 2d-crayon | 2d-vector | 2d-pixel | 2d-paper | 2d-lineart | 2d-cel

## Shot List
| # | Seconds | Content | Camera Move | Speed | Brightness |
|---|---------|---------|------------|-------|-----------|
...

## Colour Arc
[Describe colour palette evolution across the video]

## Editing Rhythm
- Total shots: X
- Avg shot length: Y s (Z beats)
- Cuts on beat: Yes/No
- Transitions: [list types]

## Narrative Structure
[Hook / conflict / resolution / recurring motifs / how jokes land]

## Typography
[Caption style, size, placement, animation]

## Key Techniques (why this video works)
1. ...
2. ...
3. ...

Report the analysis to the user: shot table + 3-5 "why this video works" insights.


Phase 2: Select Style → Route to Production Engine

Read all styles/*.md files in this skill directory. Each has frontmatter:

engine: <engine-skill-name>
medium: 2d-painted | 2d-cel | 2d-pixel | ...
priority: 1-10

Routing logic (strict order):

  1. Filter to styles whose medium matches the reference medium.
  2. Score each matching style against analysis/STYLE.md identification features.
  3. Pick highest score, break ties with priority.
  4. If no same-medium style exists, pick closest medium, inform user.
  5. If user explicitly names a style or tool → use that.
  6. If no style fits → use closest engine, create a new styles/<name>.md entry afterwards.

Tell the user: "Detected style: X → using engine: Y because [reason]."

Load the engine skill and follow its instructions for production details.


Phase 3: Music (skip if silent)

If the video has music:

  1. User must provide the audio file (do not download copyrighted music).
  2. Analyse the audio: ``bash python "$SKILL_DIR/skills/video-clone/scripts/analyze.py" "<audio_file>" \ --out projects/<slug>/analysis/song ``
  3. Check report.json: - audio.silent: true → ask user to re-record with system audio - audio.phase_inverted: true or audio.noise_floor_db > -45 → warn user about audio quality
  4. Trim to target length starting on a beat: ``bash ffmpeg -ss <start> -t <len> -i audio.wav \ -af "loudnorm=I=-14:TP=-1.5,afade=t=in:d=0.08,afade=t=out:st=<len-2>:d=2" \ -c:a aac -b:a 192k assets/clip.m4a ``
  5. All shot timings in storyboard use beats, not seconds. BPM change = re-render timing only.

If user provides lyrics:

python "$SKILL_DIR/skills/video-clone/scripts/align_lyrics.py" <audio> inputs/lyrics.txt \
  --out analysis/lyrics/subs.lrc

Use ONLY user-provided lyric text. Never invent or transcribe lyrics.


Phase 4: Storyboard

Write projects/<slug>/STORYBOARD.md:

# Storyboard — <project slug>

## Logline
[One sentence: what is this video about]

## World & Colour Arc
[Setting, colour palette evolution: opening → climax → end]

## Motif
[Recurring visual symbol or joke structure]

## Character Arc
[Protagonist emotional journey, if applicable]

## Shot Table
| # | Beats | Transition-In | Event | Reaction | Camera |
|---|-------|--------------|-------|----------|--------|
| 1 | 4     | cut          | ...   | ...      | slow-push, fill=0.6, region=face |
...

Shot-for-shot style cloning (critical):

Each shot in the storyboard must reference the original:

{
  "shot": 3,
  "ref_shot": 7,
  "ref_what": "slow zoom in on subject with warm backlight",
  "camera": {
    "move": "slow-push",
    "focal": "85mm",
    "fill": 0.6,
    "region": "face",
    "depth_of_field": "shallow",
    "angle_start": 0,
    "angle_end": 3
  }
}

Self-check after writing: compare each planned shot against shot_details in report.json.

  • Camera speed must match (ref = slow-push → planned = slow-push, not static)
  • Shot ratio of text-only cards must be ±30% of reference
  • Average shot length must be ±30% of reference

Present storyboard to user with brief summary. Wait for approval unless user said "decide yourself."


Phase 5: Production Pipeline

Order is mandatory. Never skip a gate.

Gate 0: Required Inputs Checklist

Before production agent starts, list everything only the user can provide:

  • Lyrics text (if needed)
  • Character design sheets (if using user's IP)
  • Product photos (if applicable)

Missing items block production. Write them to plan.json → required_inputs. Do not generate placeholders silently.

Gate 1: Director Setup

Create build/production.json:

{
  "segments": [
    {"id": "A", "shots": [1,2,3], "engine": "painted-animation"},
    {"id": "B", "shots": [4,5,6], "engine": "painted-animation"}
  ],
  "shared_assets": {...},
  "character_definitions": {...}
}

Gate 2: Character Approval

  1. Production agent renders character sheets: front view, 8+ expressions, 6+ poses.
  2. A fresh independent reviewer agent (not the production agent) inspects full-resolution crops using this checklist:

Visual QA Checklist (use on every gate):

  • ☐ All limbs attached, no floating parts
  • ☐ Neck present and natural
  • ☐ No seams or double-stroke outlines
  • ☐ Consistent with character design sheet
  • ☐ Uniform line weight
  • ☐ No clipping/mesh intersection
  • ☐ Subject fills frame appropriately
  • ☐ Text is legible
  • ☐ No colour banding or flicker
  • ☐ Motion has anticipation and follow-through

Fail → return to production agent for fix (max 3 rounds). Pass → proceed.

Gate 3: Parallel Segment Production + Inline Review

  • Up to 6 production agents work simultaneously on different segments.
  • Each finished segment immediately goes to a fresh reviewer agent (not the same one that made it).
  • Reviewer checks every shot's frame sheet, strip, and character crops against Visual QA Checklist.
  • Fail → returned to producer for fix, with specific failure reason.
  • Fix must include: fixes.json entry with before/after full-resolution crops.
  • Reviewer validates the before/after before accepting.

Gate 4: Assembly + Final Review

  • Assemble all segments in sequence.
  • Final reviewer (fresh agent, not any prior producer or reviewer) checks:
  • ☐ Segment seams are clean
  • ☐ Visual continuity across segments
  • ☐ Rhythm matches reference BPM feel
  • ☐ Subtitle consistency throughout
  • ☐ Every previously-logged "fixed" issue is actually fixed

Phase 6: Output & Feedback Loop

Report to user:

✅ Output: projects/<slug>/out/final.mp4
⏱ Duration: XX.Xs | 📐 Resolution: 1920×1080 | 🎬 X shots
Shot summary:
  1. [one sentence]
  ...
⚠️ Known limitations / placeholder sections: [honest list]

Feedback handling:

  • User gives time-coded feedback: "at 0:12 the character looks wrong"
  • Extract affected shots only (from report.json shot boundaries)
  • Re-render only those shots
  • Re-run Gate 3 reviewer for changed shots only
  • Re-run Gate 4 seam check

Asset Safety

Fetch free assets when user has none:

python "$SKILL_DIR/skills/video-clone/scripts/fetch_assets.py" search --kind image --q "keyword" --cc0
python "$SKILL_DIR/skills/video-clone/scripts/fetch_assets.py" get --project projects/<slug> --url "<asset_url>" \
  --name background.jpg --source openverse --license "CC0"

Log every asset to assets/ASSETS.md:

| Filename | Source | Author | Licence | URL |

Unknown licence → tag "Licence unconfirmed" and tell user.


Style Registry

Supported 2D styles (read individual styles/<name>.md for engine, features, known gotchas):

StyleMediumEngine
painted-animation2d-paintedpainted-animation
anime-cel2d-celanime-cel
pixel-art2d-pixelpixel-art
crayon-storybook2d-crayoncrayon-storybook
paper-cutout2d-paperpaper-cutout
whiteboard2d-lineartwhiteboard
faceless-explainer2d-lineartfaceless-explainer
motion-graphics2d-vectormotion-graphics
slideshow2d-vectorslideshow
music-to-video2d-*music-to-video

To add a new style: copy styles/_TEMPLATE.md → fill engine, medium, identification features, production defaults, known gotchas. The engine entry point must exist at skills/<engine>/<engine>.md within this suite.


Mode Router

ModeTriggerBehaviour
FULLDefaultAll phases 0-6
ANALYSE-ONLY"just analyse the video"Phase 0-1 only, output STYLE.md
REPLAN"change the storyboard" / feedback before productionPhase 4 only
RECUT"fix shot X" + time code after productionPhase 6 targeted
ADD-STYLE"add a new style called X"Extend styles/ registry only
SILENT"no music" flagSkip Phase 3

Reference Map

Load on demand:

FileUse
references/runtime.mdTool versions, install commands, doctor check
references/engines.mdPer-engine production details (HyperFrames, FFmpeg, etc.)
references/shot-analysis.mdHow to read analyze.py JSON fields
references/audio.mdBPM alignment, loudnorm, audio pitfalls
references/licensing.mdAsset sources, licence grades, attribution format
references/qa-checklist.mdFull expanded Visual QA checklist
styles/*.mdPer-style identification features + engine defaults
skills/video-clone/scripts/analyze.pyVideo/audio analysis: see inline docstring
skills/video-clone/scripts/align_lyrics.pyLyrics timestamp alignment
skills/video-clone/scripts/fetch_assets.pyAsset search and download
skills/video-clone/scripts/compare.pySide-by-side shot comparison evidence
evals/evals.jsonBenchmark trigger and behaviour assertions

Stop Conditions

Stop and report to user when:

  • Reference video cannot be downloaded or read (ask for local file)
  • Required inputs (lyrics, design sheets) not provided after 1 reminder
  • QA gate fails 3 rounds without progress (report specific failure, propose alternative approach)
  • User explicitly cancels or changes direction mid-production

Adapted from edenfunf/reelmimic · MIT License · Skillified by Mamdouh Aboammar

دانلود ZIP