Explainer videos written entirely in code, plus Claude Code skills that turn a topic into a finished episode.
Remotion + React + SVG visuals, procedurally synthesized sound, animations locked to subtitles or music beats. Distill a style from reference videos, then make an episode in one shot.
English · 简体中文
- Overview
- Style Gallery
- Features
- Quick Start
- Workflow Skills
- Using the Skills
- What Is Not Included
- Making a New Episode
- Project Map
- Agent Quickstart
- License
weilanx-claude-videos is a Remotion project for making short explainer videos (mostly in Chinese) about AI, tech history, science, game theory, FPS games and ancient China. Nothing is drawn in an editor: characters, props, backgrounds, charts, subtitles and sound effects are all generated by code. Voice-over episodes need a voice recording and its subtitles; music-only episodes need just a music track.
The repository contains a reusable component library with eight style kits, a style library, an audio synthesis pipeline, eight Claude Code workflow skills, and the full source of 50+ episodes as worked examples.
Every frame below is rendered by code from this repository. Each style has a recipe card under styles/我的风格/ and reusable components under src/library/.
Recipe cards and scene code for 35 art styles, from cave painting to vaporwave, each with a preview — see styles/艺术风格/. They run on the Canvas engine of huashu-art-motion (MIT) and can be ported into Remotion components.
Explainer-video grammars (3Blue1Brown-like math, Kurzgesagt-like illustration, whiteboard, keynote, finance charts, Vox, storytime, kinetic type, presenter) with grammar cards and demo code — see styles/解说语法/.
- Frame-pure animation — every component computes its look from the frame number; randomness uses a seeded
rand(seed), so renders are deterministic. - Subtitle-driven timing —
makeCuesturns an SRT into helpers likecf(n)(frame where sentence n starts) andcw(n, 'word')(frame where a word is spoken). Re-record the voice-over, re-import the SRT, and every animation re-aligns. - Character library — vector or pixel-art buddy (
Char), with skins, accessories, expressions and walking/arm animations, switched via aCharStylecontext. - Multiple looks — black-gold glow, tactical HUD, lamplight history, warm-paper desk, gilded archive, halftone, editor room, pixel sticker, pixel hand-drawn, vector hand-drawn, and a Vox-style collage/timeline kit. See the Style Gallery.
- Beat-locked music-only shorts — one
timeline.tsper episode holds the bar grid, hit frames, bilingual captions, shots and SFX; climaxes land on the track's measured downbeats. - One-shot workflow skills — from a topic to an exported video, cover, post copy and subtitle documents, with automated frame and loudness QA.
- Procedural audio — 14 synthesized sound effects plus per-episode background music that automatically ducks under the voice.
- Music library —
audio/music.mjscuts a section of any track inpublic/music/, fades it and normalizes loudness; music-only shorts align their climax to the track's measured downbeat. - Clean export — renders voice / music / SFX stems separately and remixes them with a limiter to avoid Remotion's internal clipping.
- Style library — 35 art styles and 9 explainer grammars (recipes and scene code) for picking a look before building an episode.
Requires Node.js (developed on v24) and, for exporting, ffmpeg.
git clone https://github.com/Azure12355/weilanx-claude-videos.git
cd weilanx-claude-videos
npm install
npm run audio # generates shared SFX and the ep00 demo music into public/audio/
npm run studio # opens Remotion Studio at http://localhost:3000Open the ep00-demo composition first: it is a self-contained 30-second demo that needs no external assets.
Other useful commands:
npm test # vitest
npm run typecheck # tsc --noUnusedLocals
npx remotion still src/index.ts ep06-context out.jpg --frame=200 --scale=0.4 # render one frame
npm run export -- ep00-demo # render into the folder printed by: bash scripts/ep-dir.sh ep00-demo out
npm run audioprints errors for episodes whose voice track or music file is missing (see What Is Not Included); the shared SFX and the ep00 music are still generated. To build one episode's audio, runnode audio/episodes/<episode-id>.mjs.
.claude/skills/ contains eight Claude Code skills. Open the project in Claude Code and describe what you want; the matching skill is picked up automatically.
| Skill | What it does | Delivery | Sample |
|---|---|---|---|
weilanx-creator-distill-video |
Breaks reference videos down shot by shot (cuts, keyframes, palette, motion strips, beats) and distills their visual grammar into a new reusable style kit under src/library/, with a preview composition and a recipe card |
Kit + preview + recipe card | gilded/, tactical/, lamplight/, blackgold/ |
weilanx-creator-blackgold-video |
Black-gold glow short on a game-theory or counter-intuitive model, no voice-over, bilingual captions | One-shot: video, 3:4 cover, post copy, bilingual subtitles | ep36 |
weilanx-creator-fps-video |
Tactical-HUD explainer on why something feels bad in FPS games, no voice-over | One-shot: video, 3:4 cover, post copy, subtitle doc | ep25, ep29… |
weilanx-creator-lamplight-video |
Lamplight history short on an ancient Chinese rule or custom, no voice-over | Script and beat sheet first, then one run to the video | ep28, ep30… |
weilanx-creator-gilded-video |
Music-only knowledge short in the gilded style: anchor word, climax on the track's measured downbeat | Studio preview, export after approval | ep23, ep24 |
weilanx-creator-desk-video |
Warm-paper desk explainer for a talking-head "how I did X in N steps" video | Studio preview, export after approval | ep26, ep27 |
weilanx-creator-vox-video |
Vox-style collage explainer: research, licensed real footage, expressive voice-over, hard cuts | Studio preview, export after approval | ep21 |
weilanx-creator-pixel-video |
One keyword → a pixel-art talking-head explainer (3:4 portrait) | Studio preview, export after approval | ep05–ep17 |
Bundled scripts include analyze.py and strip.py (video breakdown), beats.py (tempo, bar grid and downbeat detection), qa.mjs (frame and loudness self-check for the one-shot skills), subtitle-document generators and commons.py (Wikimedia Commons search with license info).
Some steps originally used the author's private tools (voice clone, speech recognition, text-to-image cover, title formula library). Every skill has a 依赖(开源版说明) section saying exactly what to swap in; the one-shot black-gold workflow needs nothing private except a music track.
- Node.js (developed on v24),
npm installdone ffmpegfor export and loudness checksuvfor the Python helper scripts (they run asuv run --with numpy --with pillow python …)- Claude Code opened at the repository root, so it loads
CLAUDE.md→AGENTS.mdand the skills in.claude/skills/ - Fonts: the newer styles use system CJK fonts (
Songti SC,PingFang SCon macOS, falling back toNoto Serif SC/Noto Sans SC). They render best on macOS.
The rule is match the style one-to-one, never copy the content: components are rewritten from scratch, example content is made up, and no frame, caption, title or watermark of the original goes into the repository.
- Put one or more reference videos in
template/(git-ignored; they are someone else's work). - In Claude Code, say something like: "Distill the style of
template/ref.mp4into a new kit." - The skill runs a machine breakdown per video (shots, keyframes, contact sheets, palette and accent colors, motion intensity, beats), writing a report to
materials/00-公共/风格蒸馏/<style-id>/. - It then cuts motion strips around key moments, writes a recipe card under
styles/我的风格/<name>/, buildssrc/library/<style-id>/, alibrary-<style-id>preview composition, and registers everything insrc/library/README.mdandstyles/README.md. - It compares the preview with the reference for at least two rounds before handing over. Open
http://localhost:3000/library-<style-id>in Studio to review.
You can also run the breakdown by hand:
uv run --with numpy --with pillow python .claude/skills/weilanx-creator-distill-video/scripts/analyze.py \
template/ref.mp4 --out materials/00-公共/风格蒸馏/<style-id>/<video-name>The one-shot skills (blackgold, fps) take a topic and deliver a finished episode without stopping for confirmation: research → anchor word and storyboard → timeline.ts locked to the music's beats → sound effects → scenes → tests → automatic frame and loudness self-check (fixing issues for up to three rounds) → export → 3:4 cover, post copy and subtitle documents.
-
Provide a music track. The samples are cut to
we-never, a track the author is licensed to use; the mp3 is not distributed. Put your own licensed track inpublic/music/, register it inTRACKSinaudio/music.mjs, and measure it:uv run --with numpy python .claude/skills/weilanx-creator-gilded-video/scripts/beats.py public/music/<track>.mp3 --to 40
Then point the episode's
timeline.tsgrid and hit frames at the measured beats (the skill does this if you tell it which track to use). -
Give a topic in Claude Code, e.g. "Make a black-gold episode on the boxed pigs game" or "Make an FPS episode: why do I always lose the first duel". Give the topic explicitly: the author's topic pools live in
materials/and are not in the repository. -
The skill picks the next episode ID, creates the material and output folders with
scripts/ep-dir.sh, and starts from the sample episode's code (ep36-boxed-pigsfor black-gold, the latest tactical episode for FPS) instead of a blank file. -
Find the deliverables in the output folder (
bash scripts/ep-dir.sh <episode-id> out):<episode-id>.mp4,封面-3x4.png,发布文案.md,字幕稿.mdand, for black-gold,字幕.srt.
The cover for black-gold is rendered by code (CoverTall.tsx); the FPS skill generates its cover with a text-to-image model, which you can replace with any image tool or a rendered frame.
To protect the author's privacy and third-party rights, the following are intentionally not in this repository:
| Path | What it was | Effect |
|---|---|---|
public/audio/<episode>/voice.wav |
Original voice-over recordings | Voice-over episodes play silently in Studio; their music cannot be generated |
public/footage/<episode>/ |
Real-world photos and video clips, host camera recordings | Those panels are empty in ep03, ep07, ep21, ep22, ep26, ep27 |
public/images/ep04-opus55/ |
Screenshots used in ep04 | ep04 image panels are empty |
public/music/*.mp3 |
Music library tracks (only the catalog public/music/README.md is included). we-never, used by every music-only episode from ep23 on, is licensed to the author for their own use and is not redistributed |
Music-only episodes play silently and their audio scripts fail until you add your own licensed track |
template/ |
Reference videos used for style distillation (other people's work) | — |
materials/, out/ |
Raw recordings, scripts, topic pools, breakdown reports, rendered videos | Created on demand by scripts/ep-dir.sh |
The visuals, captions, timelines and scene code of every episode are included, so you can study or adapt them and plug in your own voice and music.
Prefer the workflow skills. To do it by hand for a voice-over episode:
- Create the folders:
bash scripts/ep-dir.sh epXX-topic materials --new <style-folder> <short-title>, transcribe your voice-over into an SRT file and put it there. - Normalize the voice to about −16 LUFS and save it as
public/audio/epXX-topic/voice.wav(48 kHz, stereo, 16-bit). - Import subtitles:
npm run cues -- <materials-folder>/字幕.srt src/episodes/epXX-topic/cues.json. - Add
audio/episodes/epXX-topic.mjs(music sections) and runnode audio/episodes/epXX-topic.mjs. - Create
src/episodes/epXX-topic/— useep02-llm(portrait) orep03-cc(landscape) as a template — register it insrc/Root.tsx, and addtests/episodes/epXX-topic.test.ts. - Check frames with
npx remotion still, preview in Studio, thennpm run export -- epXX-topic.
Music-only episodes use a single timeline.ts per episode instead of subtitles; see the black-gold, FPS, lamplight and gilded skills.
| Path | Purpose |
|---|---|
src/library/ |
Reusable components: Show skeleton, cues, subtitles, characters, props, sets, and one kit per style — blackgold/, tactical/, lamplight/, warm-desk/, gilded/, halftone/, editor-room/, vox/ (index) |
src/episodes/ |
One directory per episode; voice-over episodes use Show, music-only ones use their own timeline.ts |
src/Root.tsx |
Registers every composition |
audio/ |
SFX synthesis, music engine, music library (music.mjs), per-episode score sheets |
scripts/ |
SRT import, export, stem remix, and ep-dir.sh for the per-style materials/ and out/ folders |
styles/ |
Style library (index) |
.claude/skills/ |
Claude Code workflow skills (see above) |
tests/ |
Library and per-episode tests |
public/fonts/ |
Bundled OFL fonts (licenses) |
Produce deterministic explainer videos where every visual is a pure function of the frame number and is anchored to subtitle timing. Non-goals: a general video editor, or hosting the author's voice recordings and footage.
- Engineering conventions and pipeline:
AGENTS.md - Component catalogue:
src/library/README.md - Compositions:
src/Root.tsx - Tests:
tests/
- Read
AGENTS.mdand the library README. - Change scenes or library components; never import
src/episodes/fromsrc/library/. - Run
npm testandnpm run typecheck. - Verify visuals with
npx remotion still ... --scale=0.4instead of rendering the full video.
npm install
npm test
npm run typecheck
npm run studio- Never commit voice recordings, rendered videos, real footage, music files, reference videos,
.envfiles or secrets. - No
Math.random(), CSS animations or wall-clock time in components. - Only add third-party media whose license allows redistribution, and record its source.
Code is released under the MIT License.
Third-party material:
- Fonts in
public/fonts/are under the SIL Open Font License 1.1 — seepublic/fonts/LICENSES.md. Other styles reference system fonts that are not bundled. - No music is bundled.
we-never, referenced by the music-only samples, is licensed to the author for their own use and is not redistributed here; bring your own licensed track. - Styles distilled from reference videos reuse only visual grammar (palette, layout, motion, rhythm). All components and example content are original; no frames, captions or watermarks from the references are included.
- Art styles and explainer grammars in
styles/are adapted from alchaincyf/huashu-art-motion (MIT) — seestyles/LICENSE-huashu-art-motion. - Product names and logos that appear in episodes belong to their respective owners and are used for commentary.












