Communitygithub.com

Video Production

Create short-form presentation, retrospective, and summary videos (under 1 min, 1–3 min, 3–10 min) using HTML layout rendered to images, composited with ffmpeg. Supports automated background music, voiceover, and subtitles.

What is Video Production?

This skill transforms text, screenshots, and audio into finished video clips without any video editing software—everything is done via HTML templating rendered to PNG by headless Chrome, then composited with ffmpeg. It's designed for short-form content under 10 minutes, split into three tiers: under 1 minute (image-only with music), 1–3 minutes (with optional auto-generated voiceover), and 3–10 minutes (with mandatory subtitles). The core philosophy is that video failure is almost never a technical problem, but a failure to clarify the audience and goal upfront. Therefore, the skill enforces a 13-question decision tree covering video type, narrative structure, visual style, animations, music, voiceover, and custom requests—users must answer these sequentially, and the final question is always open-ended to capture what the questionnaire missed. It supports platforms like Claude Code and can run on macOS or Windows with ffmpeg, Chrome, and Python dependencies; for advanced dynamic graphics (L4), Node.js 22+ is required. The skill includes a full suite of reference docs and pre-built templates for rendering slides, compositing audio, handling subtitles, and running quality checks before delivery.

Works with✓Claude Code~Codex CLI~Cursor
npx skills add TSAITZUNG-HUNG/video-production

Ask in your favorite AI

Open a new chat with this agent skill pre-loaded.

Documentation

What does Video Production do?

A pipeline that turns "text material + screenshots + audio" into a finished video. No editing software needed—everything uses HTML layout → headless Chrome renders to images → ffmpeg compositing.

The core of this skill isn't effects—it's asking the right questions. Video failures are almost never technical problems; they happen because you didn't clarify who it's for and what it should do at the start. So the following stages one through five must not be skipped, and don't dump all questions on the user at once.


Stage 0: Environment Check (mandatory, 30 seconds)

Run this before asking anything because the results determine which options you can offer the user:

python3 ~/.claude/skills/video-production/templates/qa_check.py --env

It reports: whether ffmpeg/Chrome are available, whether ffmpeg can render text (most versions cannot), whether Chinese TTS voices exist, whether screen recording is possible, and which Chinese fonts are installed on the system.

Interpretation rules

Check ResultImpact on User
No ffmpeg or ChromeStop, give installation instructions first, don't start asking questions
ffmpeg cannot render text (no drawtext/libass)Normal—this is the default path: all text goes through HTML → PNG. Do not use drawtext or subtitles=
No Chinese TTSVoice options can only offer "user records their own audio," not "auto-generate voiceover"
Screen recording unavailableThe 3–10 minute tier must be changed to "ask the user to provide their own screen recording"
Missing Chinese fontsUse the fallback font strings from references/visuals.md, don't just write PingFang TC
No Node.js 22+Q7 should not offer L4 (HyperFrames dynamic graphics). All other three levels are fine—doesn't affect starting work

Stage 1: Ask Type & Length First (only these two questions)

Use a choice card, two questions at once. Do not ask about colors, music, or animations at this stage—the user doesn't yet know what the video will look like, and those questions will only get arbitrary answers.

Q1. What type is this video?

TypePurposeNarrative Focus
PresentationNew tool / new website / new system launch"Pain before → easy now → where to go"
RetrospectiveReview after a quarter/event"What happened → numbers → who made it happen → next steps"
SummaryCompile scattered info into a shareable video"A few items → one per page → one summary table"
OtherNone of the above fitAsk the user what they want—don't force a template

Q2. Length? (This determines the pipeline—see references/pipeline.md)

TierSuitable ForVoiceover?What the User Provides
Under 1 minLINE group broadcast, meeting openerNo (music only)Just key text points
1–3 minMain presentation segment, tutorialYesKey text (voiceover can be auto-generated)
3–10 minFull tutorial, quarterly reviewYes, subtitles mandatoryKey text; screen recording auto-captured if possible, otherwise ask user to provide it

Stage 2: Ask About Narrative Structure (give a suggestion first, let them edit)

Don't decide the structure yourself, and don't ask an open-ended "how do you want to tell it?" Instead: based on Q1's type, present a suggested outline and ask the user to edit it directly. Users edit ten times faster than writing from scratch.

Say this one line before giving the outline:

"I'll give you a draft outline—just edit the words or delete sections directly on it."

Presentation Type (Suggested Outline)

  1. Opening: a one-sentence claim, almost no text
  2. How painful it was before (specific, ideally with numbers)
  3. How to do it now (real screenshots)
  4. One action: which URL to go to, which button to press

Retrospective Type (Suggested Outline)

  1. Opening: one sentence about the quarter
  2. Three key numbers
  3. One or two specific people or stories
  4. What's next for the next quarter

Summary Type (Suggested Outline)

  1. Opening: total number of items
  2. One item per page
  3. One summary table to wrap up

After the outline, ask these two questions in the same stage (choice cards):

Q3. Should the pain point include specific numbers?

  • Yes, I'll look them up (recommended)—specific numbers are ten times more powerful than adjectives. If I can't find them, I skip that page—don't make them up.
  • Yes, I'll provide the numbers
  • No, this video doesn't need to mention a pain point

Q4. How many key points per page?

  • One per page (recommended)—viewers are on their phones; stuffing five things on one page is the same as doing nothing
  • Multiple per page, I want higher information density

Stage 3: Ask About Visuals (choice cards, four questions)

Q5. Layout tone?

  • Sandwich (recommended): dark opening → light info pages → dark closing. The transition at light/dark boundary is the most powerful cut of the whole video
  • All light: like a document or presentation, information-first
  • All dark: more for launch events, emphasis on quality feel

Q6. Color scheme? (All three sets in references/visuals.md, including CSS variables you can paste directly)

  • Use project's main color (recommended, if the project has an existing website/slide color) — video and product match colors, viewer sees continuity after opening a website
  • Indigo (#5b5bd6): tech, tools, systems
  • Warm orange (#d97706): events, people, results review
  • Forest green (#15803d): health, growth, stability

Q7. How much animation? (Level definitions in references/visuals.md)

  • L2 Standard (recommended): slow push + fade in/out + light sweep + white flash
  • L1 Quiet: only fade in/out. Suitable for document/info-focused videos
  • L3 Enhanced: L2 plus layered element entrances. Use only for presentation-type openings—using it throughout the whole video creates a cheap template feel
  • L4 Dynamic Graphics (only offered if environment check shows Node.js 22+): Use HyperFrames to render three specific scene types (opening, key number pages, closing) into truly animated segments (main title layered entrance, numbers counting from 0 to target value, transition points with sound effects); all other info pages stay at L2. Maximum three L4 scenes per video—doing the entire video creates a template feel and rendering time goes from seconds to minutes. Specifications in references/hyperframes.md. Recommended for presentation and retrospective types; summary type usually doesn't need it. Choose one animation personality for the whole video: Corporate for presentations/summaries/retrospectives, Premium for presentation-type openings, don't use Playful.

Q8. What kind of images?

  • Real screenshots primarily (recommended): much more credible
  • Illustrations primarily: for when the visuals don't exist yet or you're explaining abstract concepts (e.g., "how exhausting it used to be vs. how easy now")
  • Mixed: screenshots for functionality, illustrations for feeling

Always use "hand-drawn annotation style" for all images—this is not asked to the user. Thick colored borders (one color per step) + thick black arrows + thick circle to highlight buttons + black background with white text banner + 👆 + saturated colors + large fonts. Full specs in references/visuals.md.

Reason: Clean info-style looks like "system-generated"—recipients scroll past it immediately; hand-drawn annotation style looks like "someone sat down and marked it up for you"—only then will people follow through. For dense content (schedules, lists), don't force arrows—use zone-based thick borders + black background white text headers + large font contrast instead, another combination of the same visual vocabulary.

The only exception: if the viewer must scan multiple side-by-side items within 10 seconds and they're already familiar with the domain, then consider info-style.


Stage 4: Material Checklist to Confirm First (don't skip)

Go through the project and grab everything you can, then present a two-column table to the user:

What I can produce myself:
・Website screenshots (I'll open the browser and grab them)
・Numbers (I'll search spreadsheets/original files, and mark the source)
・All layouts and text typesetting

Only you have (please provide to me):
・○○○'s original wording or recording (any .m4a is fine)
・Old system screenshots (already shut down—I can't capture them)
・The music you want to use (if not, I'll synthesize something)

Rules

  • "What I can produce myself" must be actually produced—don't throw it back as a question
  • Numbers must always have a source; if the source can't be found, don't include it in the video
  • If missing material doesn't block starting work, do what you can first and fill in later; if missing material is core (e.g., screen recording for 3–10 minutes), get it before starting

Stage 5: Ask About Music & Voiceover

Q9. Music? (If Q7 chose L4, transition sound effects are handled by HyperFrames' built-in audio library—not asked here; background music follows this question)

  • I'll synthesize something (recommended)—can precisely align with shot timings and has no copyright issues. This video will be publicly shown at a meeting and shared in LINE groups—using music of unknown origin is a real risk
  • I'll provide an audio file (the skill will automatically normalize volume, trim, and align)
  • No music

Q10. (Only ask if Q9 chose synthesis) Music structure?

  • Big reveal (recommended for presentation type): three heavy hits + two climbs + bright harmony ending
  • Light: plucked strings-based, suitable for tutorials/summaries
  • Steady: low-frequency harmony bed, suitable for retrospectives

Q11. Voiceover? (First check Stage 0 results—don't offer options that aren't feasible)

  • Record yourself (recommended): real human voice's persuasiveness can't be replaced by machine-generated audio. Plus, users usually already record themselves
  • Auto-generate (only offer if environment check shows Chinese TTS available)
  • No voiceover (recommended for under 1 minute)

Q12. Subtitles?

  • 3–10 minutes: mandatory subtitles, no question asked. This length is usually projected at a meeting or shared in LINE groups—many people watch on mute
  • 1–3 minutes: ask if they want them (recommended)
  • Under 1 minute: no voiceover, so no subtitles needed

Stage 5.5: Final Open-Ended Question (ask every time, don't skip)

The previous twelve questions were all multiple-choice, and multiple-choice can only capture "what I thought of." This question is for what I didn't think of—and that's often what the user actually cares about.

Use an open-ended format—don't give options, let them write freely:

Q13. Any additional requirements?

You can write anything: a sentence that must appear, words that must not appear, how to write someone's name, what occasion it's for, who will watch it, reference a specific video or image's vibe, deadline, where to put the file…

If nothing, just reply "nothing" and I'll start working.

How to handle what they write

What They WriteHow to Handle
Specific request (certain phrase, number, filename)Do it directly—don't ask why
Reference a specific video/image's vibeWatch it first (open if possible, view attached image), break down what you saw into 3–5 concrete rules, read them back for confirmation, then start creating
Conflicts with earlier answersClearly explain the conflict and ask which takes priority. Don't choose one and not mention it
Out of this skill's scope (20-minute video, real person on camera, professional voice actor)Honestly say it's not possible and offer the closest alternative
Vague adjectives ("warm," "heavy-hitting," "premium")Don't start working immediately. First translate it into executable rules (e.g., "warm" = real screenshots as hero + thick borders + thick arrows + black background white text + large fonts), read back to confirm, then start creating

The last type is the most critical. Adjectives mean different things to different people; starting work directly results in being sent back after completion. Translate first, confirm, then create.

Only after this question is answered do you proceed to Stage 6.


Stage 6: Production

Handle Q13 requirements first, then follow the specifications below. Q13's requirements take priority over the default values from the previous twelve questions—those were added by the user and represent what they truly care about.

Follow references/—don't improvise production methods on the spot:

TaskReference
Pipeline overview, three length tiers, screen recording, voiceoverreferences/pipeline.md
HTML layout, color schemes, font fallbacks, animation levelsreferences/visuals.md
ffmpeg compositing, timeline calculation, subtitles, known pitfallsreferences/ffmpeg.md
Music synthesis, external audio files, volume seamsreferences/audio.md
Pre-delivery quality checksreferences/qa.md
L4 Dynamic Graphics: HyperFrames contracts, sound effects, storyboard → rendering flow, known pitfallsreferences/hyperframes.md

Five ready-made tools—don't rewrite them:

T=~/.claude/skills/video-production/templates

# Layout / overlays / subtitles → PNG (ffmpeg can't render text—all text goes through here)
python3 $T/render_text.py sc1.html -o sc1.png              # 960×540 @2x
python3 $T/render_text.py warm.html -o warm.png --native   # 1920×1080 @1x (hand-drawn annotation style)
python3 $T/render_text.py layer.html -o l.png --transparent # transparent overlay
python3 $T/render_text.py --subs voiceover.srt --out-dir subs/    # one subtitle PNG per line

# Background music (numpy synthesis, three structures)
python3 $T/make_music.py --style launch --dur 7.6 --fade-out 0 \
        --target-rms -19.8 --out music_intro.wav   # --target-rms ensures smooth transition to next segment
python3 $T/make_music.py --style light --dur 29.5 --out music_main.wav

# Compositing (reads spec.json, calculates xfade offsets automatically—manual calculation always fails)
python3 $T/build_video.py spec.json --print-timeline   # first verify timeline is correct
python3 $T/build_video.py spec.json

# Pre-delivery quality check
python3 $T/qa_check.py video.mp4

# L4 Dynamic Graphics scenes (only use if Q7 chose L4): first output a storyboard for the user to review, then add --render after approval
cp $T/hf_scene.html intro.html                              # modify text, colors, timing
python3 $T/hf_scene.py intro.html --at 1.5,4.8 --sfx whoosh-short,impact-bass-1,pop
python3 $T/hf_scene.py intro.html --at 1.5,4.8 --sfx whoosh-short,impact-bass-1,pop --render -o intro.mp4
#   → in spec.json write {"src": "intro.mp4", "dur": 6.0, "kind": "video", "keep_audio": true}

L4 storyboard is a gate, not a suggestion. hf_scene.py without --render only produces lint + keyframe collage—result in under 5 seconds; rendering a single segment takes 15+ seconds, and the first time takes a full minute. Wrong directions (colors, font sizes, pacing) are visible in the storyboard. Review the collage yourself first, then let the user confirm—only render after confirmation.

templates/slide.html is the slide template (includes CSS variables for four color schemes, opening, hand-drawn annotation style, info-style framework). Copy it and modify—don't start from blank.

Work files always go in a scratchpad directory—only the final output goes into the user's project folder.


Stage 7: Two Mandatory Self-Checks (don't deliver until both pass)

python3 ~/.claude/skills/video-production/templates/qa_check.py video.mp4

① Extract 9 frames into a collage and review it yourself. Staring at code too long makes you see "what you think is there" rather than what's actually rendered. This once caught three errors: slow push cropping top labels, half of a button being cut off, and a number overlapping background text.

② Measure volume per second and print as a bar chart. Music seams are the most common failure point. A segment once dropped to −29 dB RMS (others were at −20 dB), sounding like the music cut out. Rule: Adjacent segments' RMS difference must not exceed 2 dB.

Only when both checks pass do you proceed to Stage 8. If you see problems, go back to Stage 6 to fix, then re-run the checks—don't just fix without verifying.


Stage 8: Deliver Three Items

  1. Video file — 1920×1080 / 30fps / H.264 crf 20 / AAC 160k / +faststart
  2. Static cover image — 1920×1080, capture the opening main title frame. Can be used as LINE preview image, PPT cover page
  3. Static scene images — one per scene, for the host to insert into their own PPT

Always rename old versions—never overwrite. For example, opening.mp4 → opening-old.mp4, then the new one is called opening.mp4. Users often want to compare versions.

When delivering, clearly state: video length, what was changed, which segment is new.


How to Share This Skill with Others

This skill is designed to be passed on to other people (they can run it with Claude Code on their own Mac or PC).

How to share: Compress the entire video-production folder. The recipient extracts it to ~/.claude/skills/ (Windows: C:\Users\YourName\.claude\skills\), then restart Claude Code—the skill will appear.

What the recipient needs to install first (qa_check.py --env will tell them one by one what's missing):

macOSWindows
ffmpegbrew install ffmpegwinget install Gyan.FFmpeg
ChromeDownload from google.com/chromeSame
Python packagespip3 install numpy Pillowpip install numpy Pillow
Node.js 22+ (optional, only needed for L4)brew install nodewinget install OpenJS.NodeJS.LTS

Four things Windows users will encounter (mention upfront—don't let them discover by hitting problems):

  1. No PingFang font → layout will use Microsoft JhengHei; font widths differ, so all layouts must be re-inspected
  2. No system Chinese TTS → voiceover must be recorded by the user
  3. Screen recording uses gdigrab instead of avfoundation
  4. L4 Chinese text will fall back to Microsoft JhengHei; font widths differ → you'll see it at the storyboard stage—reduce font size by 10% or add line breaks before rendering

Skill file structure

video-production/
  SKILL.md                     ← decision flow & 13 questions (readable by anyone)
  references/
    pipeline.md                Pipeline overview, three length tiers, screen recording, voiceover
    visuals.md                 Layout, color schemes, font fallbacks, animation levels, two image styles
    ffmpeg.md                  Compositing, timeline formulas, subtitles, known pitfalls
    audio.md                   Background music, external audio files, volume seams
    qa.md                      Two mandatory pre-delivery quality checks
    hyperframes.md             L4 Dynamic Graphics: HyperFrames contracts, sound effects, storyboard → rendering, known pitfalls
  templates/
    slide.html                 Slide template (color variables + three frameworks)
    render_text.py             HTML → PNG (layout / overlays / subtitles)
    make_music.py              Music synthesis (launch / light / calm)
    build_video.py             spec.json → mp4 (auto calculates timeline)
    qa_check.py                Environment check + pre-delivery quality check
    hf_scene.html              L4 scene template (opening + key numbers, includes sound effects)
    hf_scene.py                L4: lint → storyboard collage → (after confirmation) render mp4

Hard Rules

  1. The first frame is the thumbnail. LINE and YouTube use the beginning as preview. Don't make the first frame all black, and don't use the "how bad it was" page—that makes people think the video is bad news.
  2. All numbers must have a source. If you can't find the source, don't include it. The video will be publicly shown—incorrect numbers will be caught.
  3. Don't use adjectives on the pain point page. "Very troublesome" has no power; "5 files, 97 tabs, 16.8 MB" does.
  4. ffmpeg usually cannot render text. All text goes through HTML → PNG. If you find yourself wanting to write drawtext, stop and check Stage 0's results first.
  5. Always write a fallback font. Writing only PingFang TC on Windows will silently substitute a different font, breaking the layout—and you won't notice on your own machine.
  6. Slow push zoom cap is 1.025. Anything more will crop content at the edges of the frame, and you'll only see it when extracting frames.
  7. Music seam RMS difference must not exceed 2 dB.
  8. Illustrations can be used, but don't pretend an illustration is real. Real screenshots should be labeled as real; illustrations should look like illustrations.
  9. Don't take videos longer than 10 minutes. That's not a video—it's a course. Split it.
  10. All images must use hand-drawn annotation style. 1px thin borders, gray small fonts, shrunk screenshots, equal-width four-column tables = cold = scrolled past.
  11. Ask Q13 every single time. What the user cares about most often isn't in the options you prepared.
  12. Translate adjectives into rules before creating. "Warm," "heavy-hitting," "premium" mean different things to different people—direct execution leads to being sent back.
  13. L4 only for opening, key number pages, and closing—maximum three scenes per video. All other pages stay at PNG. When everything moves, static pages actually look lifeless, and full-animated video is that "clearly AI-generated" template feel from video tutorials.
  14. Never render an L4 storyboard without the user reviewing it first. hf_scene.py without --render is this gate.
  15. Use HyperFrames via CLI only—don't install its skill. Its routing skill will intercept all "make a video" requests and bypass this skill's 13 questions. All necessary rules are copied into references/hyperframes.md.

Related Skills