Before History, Chapter 0

A 67-second narrated documentary about India's deep past. Every frame is drawn in code with Canvas, and every sound is synthesised with Web Audio. There are no video tools, stock footage or audio files in it.

Sound on. Subtitles are part of the picture, and the full narration is below.
Made
Length
67 seconds, 1080p
Built with
Canvas 2D, Web Audio, Node, ffmpeg
Status
Paused after version 2

The question

Can Claude Opus 5.5 make a short film with nothing but code? I didn't want it to generate a video. I wanted it to write the program that draws and scores one: the scenes, the camera, the light, the music and the sound effects, all in JavaScript.

I set the brief, directed and reviewed. Claude wrote the code, with most scenes built by parallel agents working one scene file each.

How it works

Each frame is a pure function of time. render(t) draws the film at any second using seeded noise, so it's deterministic and can be scrubbed like a video.

There are six scenes: India drifting north as an island plate, toolmakers at Attirampakkam 1.5 million years ago, the Toba supervolcano, the Bhimbetka rock shelters, the first farms at Mehrgarh, and the first cities. The coastlines and rivers are real geography from Natural Earth.

The soundtrack is synthesised too: wind, fire and crickets, a tanpura drone, frame drums and a bansuri phrase in raga Bhupali, mixed under a neural text-to-speech voice. To export, a script drives headless Chrome frame by frame through the DevTools protocol, renders the audio offline, and joins the two with ffmpeg.

What didn't work

The first version's scene briefs used adjectives like "premium" and "layered depth", and the results were flat vector scenes. Only Bhimbetka, which started life as a 10-second sample and had the most iteration, looked right.

For version 2 I turned the Bhimbetka scene into an art bible. It listed concrete techniques: every surface is a material, one motivated light source, a strict two-hue palette, and figures as silhouettes with a rim light. It also made a rule that every scene is reviewed side by side against Bhimbetka reference frames. The scenes improved, but only Bhimbetka reaches the standard, so I've paused the series there.

The lesson I'd keep is to brief visual work with references and named techniques, because adjectives got me flat vector scenes.

A few smaller things bit. A bulk rename turned one line into HIT = HIT, which silently killed the whole soundtrack. AAC encoding pushed the audio peak above 0 dBFS until a limiter went into the final mix. And synthesising 67 seconds of audio in the browser takes about a minute before playback can start, which is why this page shows a rendered video.

Narration

  1. Long before kingdoms, before cities, before writing, India was an island, drifting north across an ancient sea.
  2. Fifty million years ago, it struck Asia, and the Himalayas began to rise.
  3. One and a half million years ago, near today's Chennai, early humans shaped stone into tools.
  4. Seventy-four thousand years ago, a supervolcano in Sumatra buried India in ash. Yet people endured.
  5. In the hills of central India, they painted their world onto stone.
  6. Nine thousand years ago, at Mehrgarh, they sowed wheat and barley, tamed cattle, and built homes of mud brick.
  7. From villages like these, the first great cities would rise.

Source

The zip has everything needed to run, change and re-render the film. Serve the folder locally and open it in Chrome or Edge. The README covers the rest.

before-history-source.zip 127 KB: the player, six scenes, export and narration tools, and the art bible

Code is MIT licensed. The film is CC BY 4.0, so you can share and adapt it with credit. The narration voice isn't included in the download; the README shows how to generate one.