sprite2video (Sprite-Driven Code Animation Video Skill)
This skill solves the problem of "pure code animations are too monotonous": breaks down an article or GitHub repository into high-density visual storyboards, then uses a 'QQ show'-style emotion router to assign transparent character sprites, micro-animations, and frame-level sound effects to each scene.
Two Base Layouts & Quick Preset Routing (Specify in One Sentence)
| Dimension | dafeiyu (Vertical Preset) | capdim (Horizontal Preset) |
|---|---|---|
| One-Keyword Trigger | vertical / 9:16 / dafeiyu / TikTok style | horizontal / 16:9 / capdim / talk show |
| Aspect Ratio | 1080×1920 (9:16 vertical, 30fps) | 1920×1080 (16:9 horizontal, 30fps) |
| Default Character & Voice | dafeiyu-chibi + voice-120 (dafeiyu) | evil-neuro-chibi + evil-neuro-cn (Evil_Neuro_CN) |
| Default Scene (auto-detected if not specified) | GitHub repo recommendations / tool introductions (60~100 seconds, fast-paced) | Long articles / Markdown explanations / hands-on commentary (2~3 minutes narrative) |
| Background | Scene-switching theme colors (cyan→red→indigo→green→orange→purple) + radial lines/3D grid/spectrum/code rain | Uniform warm retro beige double-layer grid paper texture (#e8e6d8) |
| Navigation | Top multi-segment progress bar + NO.xx capsule + slanted bold outlined large title | Bottom full-width multi-chapter tab bar (black background, white highlighted text + dynamic small badge) |
| Character Sprite | Bottom-center fixed Q-version mascot; when a large card appears, automatically switches to corner and shrinks to the bottom-right | Left/right side white-border die-cut sticker illustration, repeatedly switched according to dialogue emotion |
| Subtitles | Bottom-center karaoke gold-colored Chinese + English secondary subtitles | Bottom-center semi-transparent black-background white-text single-line clear Chinese subtitles |
Minimal Prompt Memory Aid (user only needs to provide a direction word, the default character/voice/effects/cover will be automatically applied; if override is needed, supplement
character=xxx,voice=xxx):
- Vertical default:
Use sprite2video vertical to introduce https://github.com/owner/repo- Horizontal default:
Use sprite2video horizontal to turn this article into a video: <file/article>- Free mix:
Use sprite2video vertical to introduce <link>, character with evil-neuro-chibi, voice with evil-neuro-cn
End-to-End 6-Step Production Pipeline
Step 1: Refine Source Material (Copy or GitHub Repo)
- If input is a GitHub repo: First fetch
README.mdand directory structure, strictly no fabricated data. Refine:- One-sentence pain point Hook (grab attention within the first 3 seconds)
- Core numerical evidence (Star count, sample size, key metric comparisons)
- 3~6 concrete features or before/after comparisons (can be paired with actual webpage screenshots or terminal commands)
- One installation/startup command (place in
TerminalBox) - Ending one-image summary / CTA
- If input is an article/copy: Split into 6
13 fast-paced storyboard scenes (1 core point per scene, 510 seconds). For each scene, extract a 4~6 character short title and a visual infographic type (number increment / progress bar comparison / stamp conclusion / terminal typing / screenshot highlight).
Step 2: Prepare Character Sprite Library
- Check if a usable sprite pack already exists in
public/characters/(comes withdemo-chibiout of the box). - If a new character is needed, first invoke the
video-sprite-packSkill to generate and verifycontact-sheet.pngandmanifest.json.
Step 3: QQ Show-style Script Auto-Route Character Reactions
Write each scene's spoken dialogue into a temporary text file (one line per sentence, breathing tags like [sigh] [chuckle] [gasp] can be added as needed), then run:
python .agents/skills/video-sprite-pack/scripts/match_script.py `
--manifest public/characters/<char>/manifest.json `
--script work/<topic>/script.txt `
-o work/<topic>/routed.json
Quickly review routed.json manually/with the Agent, and fine-tune pose, motion, or sfx for a particular scene if necessary.
Step 4: Prepare Voiceover & SFX (Optional Real TTS, or Estimate Duration by Word Count)
- If
LATENT_AUDIO_KEYis configured, call.agents/skills/latent-media/scripts/latent.py ttsto generate.mp3files scene by scene, and precisely back-calculate each scene'sdurationInFrames = Math.ceil(duration_ms / 1000 * 30) + 8usingduration_ms. - Ensure the 10 basic sound effects are ready in
public/sfx/(if missing, runpython .agents/skills/sprite2video/scripts/generate_sfx.py -o public/sfx).
Step 5: Assemble the Remotion Video with Built-in Components
Create a new composition in src/videos/<TopicName>.tsx and register <Composition> in src/Root.tsx. Prioritize reusing built-in components; strictly avoid hand-writing a simplistic plain-text PPT:
DynamicBackground(sunburst/grid3d/spectrum/coderain/paper)TopProgressBar(dafeiyutop progress bar + capsule) orBottomChapterBar(capdimbottom chapter bar)CharacterSprite(passsrc,motion,placement="bottom" | "corner" | "right" | "center")MotionWidgets(CountUpCard,CompareBar,StampBadge,TerminalBox)BilingualSubtitle(dafeiyubilingual outlined /capdimblack-background strip)SfxTrack(pass per-scene transitionwhoosh+ cardpop+ character emotionsfx, auto-collision avoidance and consecutive play volume reduction)
Step 6: Frame Extraction Visual Quality Check & Rendering
Before rendering, extract 3~4 key frames to check for text overflow or sprite occlusion:
npx.cmd remotion still src/index.ts <CompId> out/<CompId>-f1.png --frame=45
npx.cmd remotion still src/index.ts <CompId> out/<CompId>-f2.png --frame=180
Use read_file to visually confirm no occlusion, then render the final video:
npx.cmd remotion render src/index.ts <CompId> out/<CompId>.mp4
Step 7: Bilibili Publish Kit Delivery (Title + Dual-Spec Cover + Description, Not Skipable)
After the rendered video is complete, the publish kit for direct Bilibili submission must also be produced (and saved to out/<CompId>-bilibili-publish.md):
-
Eye-Catching Title (Bilibili title + Douyin backup short title)
- Bilibili Title (freely creative, no strict character limit; provide 3 style groups with 1 main recommended group):
- Reverse-Circle-Back Style (Main Recommended): First throw out a counter-intuitive/provocative/self-deprecating hook to create a strong click desire (e.g., "Stop practicing your speaking skills! The more you memorize golden phrases, the more you sound like a trending reposter? An introvert crushed a 400-person stage with just 5 counter-intuitive tricks"), then in the second half or video body smoothly circle back to the core insight, landing on verifiable bottom-line methods and benefits. Never use clickbait that mismatches the content.
- Data Contrast Style: Put the hardest real turnaround numbers or contrast upfront (e.g., "Cried from stage fright in 7th grade, now 5.2K followers from a 400-person speech: He only did 5 things right").
- Emotional Resonance/Pain Point Direct Hit Style: Poke at the viewer's daily awkward moments + provide specific solution numbers.
- Douyin Backup Short Title (Required, strictly < 30 characters including punctuation and spaces):
- Specifically for Douyin submission: Compress the strongest hook/core number from the main title into 30 characters or fewer (must actually count characters to confirm
< 30), provide 1~2 copy-paste ready options.
- Specifically for Douyin submission: Compress the strongest hook/core number from the main title into 30 characters or fewer (must actually count characters to confirm
- Bilibili Title (freely creative, no strict character limit; provide 3 style groups with 1 main recommended group):
-
Three-Spec Full-Platform Covers (Bilibili
16:91920×1080 + Bilibili Dynamic4:31440×1080 + Douyin/Xiaohongshu3:41080×1440)- Reuse the built-in
src/components/BilibiliCover.tsxto register three<Still>groups (the component automatically switches between horizontal left-text-right-image / vertical top-text-bottom-image based on aspect ratio), generate images withnpx.cmd remotion still, must visually verify withread_file:- Keep cover big text to 8~14 characters (2-line giant title + 1 high-contrast red/blue badge), visible within 1 second on mobile thumbnails;
- Place 1~2 of the most dramatically expressive transparent white-border character sprites (e.g.,
shocked_fistbreakdown /smug_winksmug /celebrate_starstar-holding) to interact emotionally with the main text; - Horizontal version: reserve bottom-right corner for Bilibili duration badge avoidance zone;
3:4vertical version: leave top and bottom safety margins to fit Douyin/Xiaohongshu recommendation feed cropping.
- Reuse the built-in
-
Bilibili Complete Description (Fixed Four-Paragraph Format, Direct Copy Paste)
- Paragraph 1 (Reverse-Circle-Back Hook → Circle Back to Core Point): 1~2 sentences that pick up the title's reverse/exaggerated suspense, naturally circling back to the video's core insight;
- Paragraph 2 (What You'll Take Away After Watching): List 3~5 concrete, immediately actionable takeaways (framework formulas, situational scripts, training actions, etc.) in clear bullet points, so viewers instantly see "worth the click";
- Paragraph 3 (Precise Chapter Timestamps for Air-Drop): Convert actual voiceover
timeline.jsonintoMM:SSchapter nodes matching Bilibili's auto-section progress bar; - Paragraph 4 (Interactive question + 5~8 precise
#topic tags): Space-separated, fitting real searchable topic words (don't create unsought long phrases).