name: toon-forge description: Story-first, code-only 2D and 3D animation (Remotion + React/SVG + Three.js + FFmpeg; no AI image or video generators, no Blender). Takes an idea to a finished animated film through premise and plot, story structure and beat sheet, a distinctive original cast with a character sheet and line-up test, a storyboard with shot design and a picture board, then frame-driven animation with Thai subtitles, synthesized sound effects and music. Covers realistic-proportion people in thin ink and watercolour, many finishes (watercolour, gouache, pencil, crayon, paper cut-out, manga, comic, vintage), a style measured from reference images, anime characters in six genre styles with whole bodies from every side, flat and slim 2D cartoon people, stickman and vector figures, hand-drawn ink and wash, 2.5D parallax, cel-shaded 3D toon characters and sets, characters from a reference image, atmosphere, diagrams and physics. Use for การ์ตูน, แอนิเมชัน 2D/3D, อนิเมะ, สีน้ำ, สไตล์จากเรฟ, ออกแบบตัวละคร, พลอต, วางโครงเรื่อง, สตอรี่บอร์ด, animated short, skit, explainer with characters. Self-contained: installs its own dependencies and needs no other skill.
Toon Forge
Use when the request is to make an animated story or any part of one: a plot, a story outline, a cast, a character design, a storyboard, or the finished 2D/3D animation. Everything is drawn and moved by code. Never use AI image or video generators or text/image-to-video services, and never require Blender. Never copy an existing character, mascot or a living artist's signature style.
TF below is this skill's folder (the one holding this file).
0. Set up (once per machine)
bash $TF/scripts/setup.sh # checks node>=20, ffmpeg, python3; installs Remotion + headless browser + Prompt font into ~/.toon-forge
Nothing else is needed. 3D packages install on the first init that asks for them.
1. The pipeline
Work through the stages in order. Each has a gate: do not start the next stage until the gate passes. Stop early when the user asked only for a plot, a cast or a storyboard, and deliver that stage's output.
| # | stage | read | output | gate |
|---|---|---|---|---|
| 1 | Premise and plot | references/story.md §1–3 | logline + story block | logline has want, obstacle, turn |
| 2 | Structure | references/story.md §4–9 | beat sheet → script.json scenes with beat | forge.py check script.json has no WARN |
| 3 | Cast | references/character-identity.md | character sheet per character | line-up still passes all six checks |
| 4 | Storyboard | references/storyboard.md | storyboard.json (+ timeline.json) | forge.py check clean; you looked at forge.py board |
| 5 | Animate | §3–5 below + the kit's reference | scenes in code | draft render watched; every scene moves |
| 6 | Sound, render, QA | §6–7 | MP4 + subtitles + cover | forge.py qa clean |
Ask the user only what changes the film and cannot be guessed: the idea (if none was given), length and format (default 30–45 s, 1080×1920, 30 fps), tone, and whether they want to approve the plot, cast sheet or board before animation. If they do not say, show the beat sheet and the cast sheet briefly and keep going.
Defaults: bright, light palettes; Thai text in subtitles and signs; no voice-over; original characters with a short visible neck and natural clothes.
2. Start a project
python3 $TF/scripts/forge.py route "<the brief>" # which kits the brief needs
python3 $TF/scripts/forge.py init ~/videos/<slug> --caps flat # or: --example life-time to start from a finished film
init copies the starter (src/lib/*, Root.tsx, CastSheet, Cover), the kits for the caps, the Prompt font
and a synthesized SFX set into the project. Register each film as a <Composition> in src/Root.tsx.
| cap | for | code | reference |
|---|---|---|---|
flat | big-head 2D cartoon people, outfits, 10 expressions, 5 turns, street sets and props | lib/flat, lib/slim, lib/city | flat-story.md, character-design.md |
character-2d | stickman and vector figures, gaits, pose presets, blink, talk | lib/characters, lib/pose | character-design.md §7, §11–12 |
handmade | hand-drawn ink, dry brush, paper, washes, turning head, motif, cuts on bars | lib/ink, lib/head, lib/motif, lib/meter | handmade.md |
parallax | 2.5D layered worlds and camera | lib/parallax | storyboard.md §3 |
toon | cel-shaded 3D characters with ink outlines, sets, Thai signs, orbit camera | lib/toon, lib/three | toon-story.md, toon-characters.md |
3d | Three.js stage, camera rig, lights, environments | lib/three | header of lib/three.tsx |
refchar | an original character drawn from a reference image | lib/refchar, scripts/charref.py | character-from-reference.md |
look | watercolour, thin ink + wash, gouache, pencil, crayon, cut-out, manga, comic, vintage; a style measured from a reference image | lib/look, scripts/styleref.py | looks.md |
anime | anime characters (six genre presets, whole body, every side), speed lines, impact frames, skies, petals | lib/anime | anime.md |
cutout | puppets cut from generated or drawn parts sheets (front, side, back, faces, hands) on a generated background: style check against the reference, cut, rig, every FlatPose, turns, talk | lib/cutout, scripts/cutout.py | cutout.md |
atmosphere | fog, particles, god rays, glow, vignette, grade | lib/atmosphere | header of the file |
diagram | animated diagrams inside a story | lib/diagram | header of the file |
thai-type | Thai kinetic text and titles | lib/typography | header of the file |
Always there: lib/story (subtitles, mouth flaps, SFX and music from the timeline), lib/physics, lib/noise,
lib/layout, lib/SafeGuides, transitions.tsx. Choose 2D first; use 3D when the story needs camera moves through
space, real light or turning bodies. Do not mix 2D and 3D characters in one film.
Examples (forge.py init <project> --example <name>): life-time (flat 2D story, 16:9), zombie-id (3D toon
episode, 9:16), paper-plane (hand-drawn, cut to music), zombie-biology (stickman explainer), ref-character
(reference-image character), apocalypse-observer (3D atmosphere), cutout-lab (a character cut from generated parts sheets, three views, in a generated park), style-lab (every look on one scene, the ink +
watercolour cast sheet, anime turnarounds, poses and shots). Read the closest one before writing a new film. Examples
with music get a synthesized stand-in track at init; replace it with find-music.py (section 6).
3. Story and timeline files
script.json is the single source for a story with lines. Schema: references/toon-story.md §2; add the story
block and a beat per scene (references/story.md).
cd ~/videos/<slug> # paths below are relative to the project
python3 $TF/scripts/forge.py check src/<slug>/script.json # story shape before anything is built
python3 $TF/scripts/story.py build ~/videos/<slug> src/<slug>/script.json # → timeline.json, storyboard.json, <Comp>.vtt
python3 $TF/scripts/forge.py check src/<slug>/storyboard.json # scene table, lengths, motion, motif, beats
python3 $TF/scripts/forge.py board ~/videos/<slug> src/<slug>/storyboard.json # out/<Comp>.board.jpg: one still per scene
A film without dialogue (music-driven, handmade) can skip script.json and write storyboard.json directly
(references/storyboard.md §1).
4. Characters
- Fill the character sheet (
references/character-identity.md§4) from the story, not from a look. - Build each one from the closest base:
FLAT_LOOKS/SLIM_LOOKS(2D),LOOKSinlib/toon(3D), arefcharspec, or new drawing code when no base fits (character-design.md,toon-characters.md§4). - Render the line-up and look at it:
npx remotion still src/index.ts CastSheet out/cast.png --props='{"cast":{...}}'(2D),story.py castand the turnaround (3D). Fix until silhouette, grayscale, thumbnail, turns, pose and scale checks pass. - Keep one look object per character in one file; every scene imports it.
From a picture the user sent: references/character-from-reference.md first (rights, then the trace-compare loop).
Choose the look with the cast, not after: realistic-proportion people in thin ink and watercolour, anime of a given
genre, pencil, cut-out and the rest are in references/looks.md and references/anime.md. When the user sends
pictures for the style, measure them with scripts/styleref.py (looks.md §3). Show LookSheet or a cast sheet
in two or three candidate looks when the user has not chosen one.
5. Animation rules
- Every value comes from
useCurrentFrame()withinterpolate/spring. No CSS animations or transitions, noMath.random()orDate.now(); userandom(seed)from Remotion orlib/noise. - Every scene has real movement in every second: a body action, a camera move, or a living hold (blink, breathe). Still pictures with fades are a slideshow, not animation.
- Pose-to-pose with anticipation, overshoot and settle; arcs, not straight lines; hold after a punchline.
Details:
storyboard.md§7–8,character-design.md§7 and §11. - Feet plant on the ground (
flatPlant,strideLength); falling and bouncing uselib/physics. - Thai text: split with
Intl.Segmenter(lib/typography), line height ≥ 1.3, never letter-spaced, kept inside the safe zones (lib/SafeGuides). - 3D on a machine without a GPU renders with
--gl=swangle(forge.pyadds it for3d/toonscenes).
6. Sound
init writes these to public/audio/sfx/ (all synthesized with FFmpeg, nothing to license): pop whoosh swoosh slide hit thud stomp step stamp click tick spin ding bell sparkle boing uhoh heartbeat gravel paper fold flutter knock pencil brush pluck riser. Need another? Add a line to scripts/synth-sfx.sh or synthesize it in the project.
- Put SFX on actions in
script.json(sfxper scene or per line);lib/storyplays them. - Music:
python3 $TF/scripts/find-music.py <mood words>lists royalty-free tracks not used before;--get <id> --title "..." --out public/audio/bgm.mp3downloads one and writes the credit topublic/audio/CREDITS.md. Offline:synth-sfx.sh <dir> <bpm> <bars>writes a simplebed.wav. - Cutting to the music:
scripts/beat-grid.py song.mp3 --fps 30, thenbpm+barsin the storyboard. - Music sits under the action (volume 0.15–0.25). No voice-over unless the user supplies a recording.
7. Render and check
python3 $TF/scripts/forge.py render ~/videos/<slug> src/<slug>/storyboard.json --draft # half size, to watch rhythm
python3 $TF/scripts/forge.py render ~/videos/<slug> src/<slug>/storyboard.json # scenes cached; only changed ones re-render
python3 $TF/scripts/forge.py qa out/<Comp>.mp4 --storyboard src/<slug>/storyboard.json # frame count, loudness, motion per scene
python3 $TF/scripts/forge.py cover out/<Comp>.mp4 --project ~/videos/<slug> --title "ชื่อเรื่อง"
Before sending: watch the contact sheet from qa, read every subtitle for Thai typos and broken glyphs, check the
cast is on model in every scene, and that no scene is frozen. Deliver the MP4, the .vtt, the cover, the board and
the music credit. --formats 9:16,1:1,16:9 renders other shapes from the same storyboard (lib/layout).
Hand-off to an editor: references/openfilm.md.
8. What the user taught you
python3 $TF/scripts/learn.py show prints rules and saved techniques from earlier films on this machine (kept in
~/.toon-forge/notebook); forge.py route and init print them too. Follow them. When the user corrects a look or
a habit, learn.py note "<rule>"; when they like a character or technique, learn.py save <name> <files>, and
story.py cast save for 3D characters.