citefilm
Explainer videos where every number on screen is quoted from a source.
citefilm turns one YAML file (scenes, narration, sources, and the exact quote behind each fact) into a narrated MP4, rendered on your own computer: a local voice, captions synced word by word, maps, fact cards and 3D scenes. If a number on screen is not in a quote that the scene cites, it will not render. Use it from the command line, or let Claude Code research, write and render a film with the bundled plugin.
23 seconds of Point Nemo, muted here (the film is narrated). Rendered from one YAML file with 9 facts quoted from NOAA and NASA.
Three example films
Each one is a single spec in examples/, rendered by citefilm with nothing edited by hand.
|
The Mars Climate Orbiter · 89 s · watch · spec One file in pound-seconds, not newton-seconds, and a spacecraft lost at Mars (NASA's investigation board). |
The Gimli Glider · 86 s · watch · spec A 767 fuelled in pounds instead of kilograms loses both engines at 35,000 feet (Canada's Board of Inquiry). |
Point Nemo · 69 s · watch · spec The spot in the ocean farthest from land, and why spacecraft are brought down near it (NOAA, NASA). |
Install in 3 commands
Needs uv, Node.js 22+, FFmpeg and make, on an Apple Silicon Mac or Linux
(requirements).
git clone https://github.com/Weekendwright/citefilm && cd citefilm
make setup # Python env with a local voice, render runtime, headless Chrome
uv run citefilm build examples/point-nemo/spec.yaml # → out/point-nemo/point-nemo.mp4
make setup installs the Python environment with a voice backend, runs citefilm runtime install (the pinned
HyperFrames and three.js, plus a headless Chrome) and ends with citefilm doctor, which names anything still missing
and the command that installs it. The first build downloads the voice model (a few hundred MB). On an Apple Silicon
laptop the 69-second Point Nemo film then renders in about 40 seconds. The package is not on PyPI yet;
until it is, install from a clone as above.
Make your first film
With Claude Code. Put the clone's citefilm on your PATH (it keeps using the locked environment), then add the
plugin:
ln -s "$PWD/.venv/bin/citefilm" ~/.local/bin/citefilm # any folder on your PATH
/plugin marketplace add Weekendwright/citefilm
/plugin install citefilm@citefilm
Then ask, in plain words:
Make a 60-second explainer about the first transatlantic telegraph cable (1858), from primary sources.
The make-explainer skill gathers primary sources, builds a fact table with exact quotes, writes the narration,
plans the scenes, runs the fact check and renders the film. The other skills are fact-check, add-scene and
render. The CLI itself needs no account or API key; the plugin uses your Claude Code session.
By hand. Copy an example, edit the YAML (the JSON Schema gives your editor autocomplete), then check and render it:
uv run citefilm validate my-film/spec.yaml # schema + fact check; prints the estimated length
uv run citefilm build my-film/spec.yaml # → out/<slug>/ with the mp4, captions.srt, chapters.txt, sources.md
What it can't do (yet)
- English only. Narration uses Kokoro's American and British English voices.
- Apple Silicon or Linux for narration. Windows through WSL may work but is untested; an Intel Mac can validate specs but has no supported voice backend.
- A fixed scene vocabulary: fact cards, a world map and simple 3D shapes. No photos, footage or illustrations, and the 3D scenes are schematic, not realistic.
- A coarse map. Natural Earth 1:110m: no small islands (they appear as markers), no lakes, rivers or streets.
- A mechanical fact check. It checks numbers written with digits against the quotes your spec cites. It never
opens the sources: whether a quote really appears in its source, spelled-out numbers and wording are for the
fact-checkskill and for you. - Layouts tuned for 16:9. Other frame sizes render, but the layouts are not tuned for them yet.
- No music or sound effects bundled. You can add your own music file (see docs/spec.md).
How it works
flowchart LR
spec["spec.yaml<br/>scenes · narration<br/>sources · facts"] --> check{"validate<br/>schema + fact check"}
check --> voice["narrator<br/>Kokoro, local"]
voice --> clocks["word clocks<br/>voice model + optional recogniser"]
clocks --> plan["timeline + captions<br/>(pure functions)"]
plan --> scenes["scene renderer<br/>HyperFrames, parallel, cached"]
scenes --> film["FFmpeg<br/>join · loudness · chapters"]
film --> out["out/<slug>/<br/>mp4 · srt · chapters · sources · contact sheet"]
A film is one YAML file. Each scene has a narration line and a visual. The voice speaks every line locally, the word times decide when each caption word and each on-screen reveal appears, and every scene is rendered as its own short video by a headless browser, then joined into one MP4.
What you get
- A film from one file. Scenes, narration, sources and facts live in
spec.yaml. The same spec renders the same film every time. - Local narration. Kokoro (Apache-2.0) runs on your machine: through MLX on Apple Silicon, through PyTorch on the CPU everywhere else. No API key, no upload.
- Captions that never run ahead of the voice. Word times come from the voice model and, when installed, a speech recogniser listening to the finished audio. A word appears when the later of the two says it was spoken.
- Scene types: fact cards (title, number, quote, list, compare, fact), an animated world map (camera moves, countries, markers, routes) and schematic 3D scenes (planets, spacecraft, aircraft, paths, rings, labels, readouts).
- Sourced by design. Every number on screen must appear in the exact quote of a fact the scene cites:
citefilm validatereports it andcitefilm buildrefuses to render it. Every film ships withsources.md,chapters.txtandcaptions.srt. - Fast re-renders. Scenes render in parallel and are cached: change one scene and only that scene renders again.
- Editor support. A JSON Schema (
schema/spec.schema.json) gives autocomplete and inline errors in any editor with a YAML language server. - A Claude Code plugin with skills for the whole job (topic → research → script → scenes → fact check → render) and four helper agents whose speed you choose.
Speed modes
One setting trades speed and cost against quality, for the helper agents and for the render:
- fast: quicker, cheaper helper models; a half-size draft render; voice-model word times only.
- balanced (default): your session's model for research and writing, a quicker one for mechanical steps; full size; both word clocks when a recogniser is installed.
- best: the strongest models for research and writing; full size; both word clocks required.
citefilm speed fast # set it for this folder; `citefilm speed` shows the current mode
The spec at a glance
# yaml-language-server: $schema=../../schema/spec.schema.json
title: "The Unit Mix-Up That Lost a Mars Orbiter"
voice: {name: am_michael, speed: 1.05}
sources:
- {id: mib, title: "Mars Climate Orbiter Mishap Investigation Board: Phase I Report", url: "https://llis.nasa.gov/..."}
facts:
- id: factor
claim: The navigation software underestimated the thrusters' effect by a factor of 4.45.
source: mib
quote: "underestimated the effect on the spacecraft trajectory by a factor of 4.45"
scenes:
- id: factor
cite: [factor]
say: So the software underestimated the thrusters' push by a factor of {4.45.|four point four five.}
visual: {type: card, style: number, value: 4.45, prefix: "×", label: underestimated, count_at: "@4.45"}
{written|spoken} shows one thing in the captions and lets the voice say another. "@4.45" starts the count when
that word is spoken. Full reference: docs/spec.md and docs/scenes.md.
Command line
| Command | What it does |
|---|---|
citefilm build SPEC |
render a film into out/<slug>/ (--only ids for single scenes, --speed, --workers N) |
citefilm validate SPEC |
check the spec against the schema, then run the fact check |
citefilm doctor |
check every dependency and print how to install what is missing |
citefilm speed [MODE] |
show or set the speed mode for this folder |
citefilm agents |
the helper-agent model per role under the speed mode |
citefilm runtime install |
install the pinned render runtime (HyperFrames, three.js, headless Chrome) |
citefilm schema |
print the spec's JSON Schema |
Every command takes --json for machine-readable output, -v and -q. Exit codes: 0 success, 1 problems found,
2 invalid input, 3 a tool is missing or failed. Details: docs/cli.md.
Requirements and speed
| OS | macOS 14 or later on Apple Silicon, or Linux (x86-64 or ARM64). Windows through WSL may work but is not tested. Intel Macs can validate specs, but no supported voice backend runs there. |
| Python | 3.11-3.13 for the tool (uv installs it). The voice needs 3.11-3.13 on Apple Silicon (MLX) or 3.11-3.12 on Linux (Kokoro on PyTorch); make setup uses 3.12. With another Python, point the voice_python setting at an environment that has a voice backend. |
| Other | Node.js 22+, FFmpeg; HyperFrames downloads its own headless Chrome |
| Memory | about 0.5-1.5 GB per parallel render worker (default: a quarter of your CPU cores, at most 4) |
| Disk | a few hundred MB for the voice model; 0.5-1.6 GB more for the optional recogniser |
Cold renders (empty cache, voice and word clocks included) of the three examples at 1920x1080, 30 fps, with 4 render workers on an Apple Silicon laptop:
| Film | Length | Scenes | Render time |
|---|---|---|---|
| Mars Climate Orbiter | 89 s | 10 (2 in 3D) | 56 s |
| Gimli Glider | 86 s | 10 (1 in 3D) | 48 s |
| Point Nemo | 69 s | 7 (2 in 3D) | 37 s |
On a CPU-only Linux machine expect several minutes. 3D scenes are the slowest. A re-render after a change only renders the scenes that changed.
FAQ
Does it need an API key or an internet connection? The CLI does not. After the first downloads (voice model, headless Chrome) it renders offline. The Claude Code plugin uses your Claude Code session for research and writing.
Can I use the films commercially? The code is Apache-2.0 and Kokoro's weights are Apache-2.0. The facts and quotes come from your sources: check their terms. See THIRD_PARTY.md for every dependency's licence.
Can I add a scene type? Yes: AGENTS.md walks through it (a model, a template, a test).
Why does a scene render again after I only changed its narration? The scene's timing changed, so its picture changed. Scenes whose narration and visual did not change come from the cache.
Docs
- Spec format · Scene types · Finding and quoting sources · Command line · Speed modes and settings
- Contributing · Security · Changelog · Code of conduct
Licence
Apache-2.0 (LICENSE, NOTICE). Fonts: SIL Open Font License. Map data: Natural Earth (public domain). Third-party licences: THIRD_PARTY.md. If you use citefilm in research, see CITATION.cff. Built with Claude Code.
Metadata
Release files for citefilm 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| citefilm-0.1.0.tar.gz | 830.6 kB | With provenance | Details for citefilm-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| citefilm-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for citefilm-0.1.0-py3-none-any.whl |
Total release size: 1.4 MB
Release files / citefilm-0.1.0.tar.gz
| Download URL | citefilm-0.1.0.tar.gz |
|---|---|
| Size | 830.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fbd5cea1a3a4ca1034b158e81e7c4ba6654028d2e82593eeaca64b954f1751a4
|
|
BLAKE2b-256 checksum How to use checksums |
ba03c74fdc079befc50acb20126dea51165d4a71d6ad5556ebaca93d6d8d5764
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 3, 2026.
Transparency logRelease files / citefilm-0.1.0-py3-none-any.whl
| Download URL | citefilm-0.1.0-py3-none-any.whl |
|---|---|
| Size | 554.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
596aed5e744c443c0761323eb3acc99b0a6ca1e03de37a1109b127f6bfe9c89a
|
|
BLAKE2b-256 checksum How to use checksums |
acdc05f83901cc20a4553a541d973d25f8f051dcf72678eeb4eb98c1fd0f5650
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.16
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 3, 2026.
Transparency logSecurity for citefilm 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for citefilm-0.1.0.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Dec 3, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.