SongFilm Engineering

How a song becomes a music video, in detail.

SongFilm is built on open-source engines, mvdirector and weaveshift. These pages explain how they actually work: how the audio is measured, why the cuts land where they do, how a character stays the same person, what the quality gates check, and which steps ever touch the network. Every claim links back to the source it came from.

2 files

State lives on disk, not in memory

Everything measured from audio is in analysis.json; everything decided and generated is in manifest.json. Each command reads, does one job and writes atomically, so any run can be stopped, resumed or repeated.

Code + model

Timing from code, taste from the model

Cut points, shot types and frame counts are computed from the beat grid and vocal stem. The language model chooses framing, sets and wardrobe, and code enforces the rules it must not break.

Lock first

Identity and places are approved before motion

Four-panel character sheets and empty set plates are locked before any shot is generated, so every shot anchors to the same approved face, costume and location.

Gated

Nothing counts until it passes a check

Stills gate videos. Failed attempts are regenerated with a new seed, a rewritten prompt or changed parameters, and every attempt is kept with its seed, prompt and QC report.

The articles

Start with the pipeline for the overall shape, or jump to the part you care about. Three of them include interactive demos that run the engine's real rules in your browser.

Architecture

The pipeline: from one track to a finished cut

How mvdirector turns a song into a lip-synced music video: a local orchestrator, three outside systems, two JSON state files, and a stage-by-stage pipeline that can be stopped and resumed at any point.

3 min readRead
Audio analysis

Timing comes from code: beats, vocals and cuts

How mvdirector measures a song and cuts it into shots on bar lines, who is singing when, and why the language model never decides when a cut happens. Includes an interactive cut planner.

4 min readRead
Visual consistency

Same person, same place: how continuity is enforced

Image and video models drift. mvdirector counters it by locking approved reference sheets, costume states, set plates and props before generation, then checking every result against them.

4 min readRead
Automated QC

Quality gates: every still and clip is checked before it counts

How mvdirector scores generated stills and clips, retries failures with a new seed or a rewritten prompt, and sends only the right shots to a person. Includes a live QC score calculator and an honest note on lip-sync measurement.

4 min readRead
Continuous mixes

WeaveShift: scoring every handoff in a continuous mix

How WeaveShift searches for and scores track-to-track transitions across six explainable categories, why profiles are plain TOML files that shape the search itself, and how a mix becomes chapters for a long-form video.

4 min readRead
Integration & data flow

Bring your own models: ComfyUI, LLMs and where your audio goes

How workflows and bindings keep mvdirector independent of any one model, how its ComfyUI client protects your GPU budget, which steps touch the network, and the hardening around paths, secrets and the MCP server.

5 min readRead

Don't take our word for it

The engines are public. Read the code, run the test suite, or self-host the whole pipeline.