short-film-builder
AGENTS.md0 starsChanged 2 months agoMITView on GitHub
This repository turns a written story into a narrated, animated short film. An agent directs; deterministic scripts execute; Remotion renders. Read this file first, whichever agent you are. Claude Code users also get skills, hooks and path-scoped rules from .claude/; every other agent follows the same process from docs/animated-story-pipeline.md by hand. Follow SETUP.md. The gate is npx tsx scripts/doctor.ts printing no ✗. Keys live in .env and are never printed, committed, or entered anywhere by an agent: when doctor reports…
- Reads credentials
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 33,315 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository3 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- story-filmSkill
- video-shot-promptsSkill
The file
We split this AGENTS.md into the rules it gives an agent
4 rules. About 0 are common, 0 are distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Very specific: line 10
Follow SETUP.md. The gate is npx tsx scripts/doctor.ts printing no ✗.
- Very specific: line 16
Agent directs, scripts execute: Write schema-validated artifacts.
- Very specific: line 17
Audio is the timeline and the mp3 is the ruler: After recording: force-align → split-sentences → align-sentences.
- Very specific: line 29
Check the machine: npx tsx scripts/doctor.ts
≈ “Common” is an estimate: at least 1 in 5 of the 42,283 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Agent instructions
This repository turns a written story into a narrated, animated short film. An agent directs;
deterministic scripts execute; Remotion renders. Read this file first, whichever agent you are.
Claude Code users also get skills, hooks and path-scoped rules from .claude/; every other
agent follows the same process from docs/animated-story-pipeline.md by hand.
Setting up
Follow SETUP.md. The gate is npx tsx scripts/doctor.ts printing no ✗. Keys live in .env
and are never printed, committed, or entered anywhere by an agent: when doctor reports a missing
key, tell the user which page to open and what to paste, then run doctor again.
Invariants
- Agent directs, scripts execute. Write schema-validated artifacts;
scripts/do TTS, alignment, generation, rendering. No LLM calls in the render path. - Audio is the timeline and the mp3 is the ruler. After recording:
force-align→split-sentences→align-sentences. Cut shots to sentence spans, never to fractions of a beat. - A story film is data.
shows/<slug>/film.json(schemaschemas/film.ts) drives generic compositions inengine/src/film/. Add shots to the JSON; never write per-show engine code. - Every stage gates before the next. Review before spend. A render is not done until
verify-syncandverify-picturepass on the rendered file. - Never AI-generate maps (border hallucination is a publishing risk). No text or logos inside generated frames.
- Generated media is gitignored. Paid outputs cache under
cache/by content hash and archive an immutable copy; approved outputs are markedreuseClip. - Pre-normalize numbers and abbreviations; call TTS with
apply_text_normalization: "off". Pronunciation dictionaries are alias-only oneleven_v3. @remotion/captionsCaptionis the timestamp interchange format.- OpenMontage (AGPL) is patterns-only — never copy its code.
Commands (pnpm, from the repo root)
pnpm install·pnpm typecheck·pnpm studio(Remotion Studio, instant preview of any composition)- Check the machine:
npx tsx scripts/doctor.ts - Render:
cd engine && pnpm exec remotion render src/index.ts <Comp> ../out/<show>/{film|arcs}/<name>-vN.mp4 - Pipeline scripts:
npx tsx scripts/<name>.ts <show> …— order of use indocs/animated-story-pipeline.md
Layout
engine/— Remotion workspace;src/film/is the generic story engine,src/packs/<slug>/optional show-specific components.scripts/— deterministic jobs ·schemas/— Zod ·docs/— process and learningsshows/<slug>/— bibles and plans;film.json;audio/(scripts, measured timings);motion/(Veo specs);art/(plates;_superseded/ignored). Runscripts/link-show.ts <slug>once so the engine can reach its media.cache/<show>/,out/<show>/— gitignored media
Services
- ElevenLabs —
ELEVENLABS_API_KEY. Dialogue:text-to-dialogue/with-timestamps(eleven_v3, ≤2000 chars, ≤10 voices). Forced alignment and music need those permissions on the key; doctor checks. - Google Vertex AI — Veo 3.1 lite/fast/standard; clips are 4, 6 or 8 s only. Auth is Application Default Credentials (
gcloud auth application-default login); it expires within a working session, so check before a batch. - Gemini images —
GEMINI_API_KEY, used through thenanobananaMCP server declared in.mcp.json.
Conventions
- Conventional Commits, one line. Commit only when asked.
- Media paths in
film.jsonare show-relative (art/…,cache/…). - zsh does not word-split unquoted variables — quote or use
while read. Detach generations longer than ten minutes withnohup.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

