Motion broll

From wolfenazz/YzPzCode · View interactive version

Motion broll is an AI agent skill from the GitHub repository wolfenazz/YzPzCode. Turn a talking-head video and its transcript into motion-graphic B-roll timed to the speaker's words, in a continuous one-shape style (one element that morphs and never cuts, driven by a cursor, spring motion). Use when someone gives a video (and ideally a transcript) and asks for motion graphics, B

How to use this skill

Skill file

Motion B-roll

You make motion-graphic clips for a creator's video. Every clip is one shape that never cuts: it morphs its size, corners and colour from state to state while its content swaps with a short blur. A cursor drives the changes with real clicks and drags, and every change lands on a spoken word.

The output is a set of clips the creator drops into their editor. You also give them a preview render of their video with the clips cut in, and two HTML pages: one to step through the clips, one to compare before and after.

Everything you need is in this skill folder:

Below, $SKILL means this skill's folder. Work in a motion/ folder in the user's project.

1. Set up (first run only)

bash $SKILL/scripts/setup.sh ./motion

This checks for Node, Python 3 and ffmpeg, and installs Playwright + Chromium into motion/node_modules. Run every engine script with NODE_PATH=./motion/node_modules.

2. Interview

Use the AskUserQuestion tool; keep it to one round. You need:

Skip any question the user already answered.

3. Inspect the footage

python3 $SKILL/scripts/inspect_video.py motion/work/source.mp4 motion/work
python3 $SKILL/scripts/words.py transcript.srt > motion/work/words.txt

Look at motion/work/contact.png yourself. video.json gives resolution, fps and layout sections:

Clips must match the video's resolution and fps. Word times from an SRT are estimates (±0.2s); treat them as such.

4. Plan, and get approval before any code

Show a table with one row per clip:

| # | In–Out | The line it covers | What the shape does, on which words | Treatment | Why |

Creative direction: decide how much of the frame each clip takes. This is the most important call; make it per clip and give the reason.

Content rules:

Wait for the user to approve or edit the plan.

5. Build

Write one fragment per clip in motion/clips/NN-name.html, following reference/engine-api.md and the examples. Then build:

python3 $SKILL/engine/build.py motion/dist motion/clips/*.html

Put each state change on its word: clip-local time = word time − clip in-point.

6. Check stills on the key words

NODE_PATH=./motion/node_modules node $SKILL/engine/beats.js motion/dist/NN-name.html motion/work/NN.png 0.4 1.2 2.1 …

Pick the times where each state has settled and a couple of mid-morph moments. Look at every sheet yourself. Fix anything cramped, clipped, unreadable or off-word, or where the cursor leaves the frame. Then check once more. Panel clips render on black in the sheet so you can judge them.

7. Render

NODE_PATH=./motion/node_modules node $SKILL/engine/render.js motion/dist/NN-name.html motion/out/NN-name_0m32s40.mp4 30000/1001

8. Deliver

Write motion/plan.json (schema in reference/engine-api.md), then:

python3 $SKILL/scripts/composite.py motion/plan.json motion/out/preview.mp4
python3 $SKILL/scripts/make_pages.py motion/plan.json motion/out/preview.mp4

The user gets, all in motion/out/:

Say plainly that the preview is for review: for the final cut they place the clips in their own editor, where they can nudge timing, add transitions and mix audio.

Style defaults

The user's brand overrides these.

Gotchas

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.