Skip to main content
Video & animationModel: Claude Opus 5.5Effort: maxRuns in: Claude Code

Recursion explained in nine film styles

Watch a 60-second demonstration of recursion in nine film styles, from film noir to pixel art. The prompt and the text in the film are in English.

Silent excerpt
0views0copies

Prompt

What you need

  • Node.js and npm
  • Playwright with Chromium
  • ffmpeg
  • A local working folder for HTML, audio and video

About the prompt

Recommended local setup: Claude Code with Claude Opus 5.5 and effort set to Max. These are the settings we recommend for running the prompt with local tools.

A film that calls itself

The demonstration runs for one minute. The camera enters an object in each scene and finds the next, smaller explanation inside it. The film follows the idea of explain(n): reduce the problem, reach the base case at n = 0, then return through the calls in reverse order.

Nine visual explanations

  • Film noir: a function that calls itself.
  • Nature documentary: the same structure in progressively smaller parts.
  • Pixel game: a base case that returns an answer and stops further calls.
  • VHS horror: what happens without a stopping condition.
  • Infomercial: the call stack keeps track of functions waiting for an answer.
  • Comic book: answers return, and each call completes its part.
  • Ink painting: one call can branch into two.
  • Movie trailer: trust the smaller call to solve its part.
  • Code editor: the base case is reached before the film returns through the scenes.

From HTML to a video file

The approach uses one 1920 × 1080 HTML file with window.seek(t), so each frame can be calculated from its timestamp. Web Audio creates music and sound effects. Playwright renders the frames, while ffmpeg assembles the video and audio. The target is 60 frames per second, with three subframes per frame for motion blur.

Language and expectations

The prompt and the text in the film are in English. This is a demonstration of one possible visual result, not a guarantee of an identical output. The model, available fonts, tools and revisions can affect the outcome. Check the content, readability and audio before sharing your version.

How to use the prompt

How to get the same kind of result as the demo.

  1. 1

    Watch the demonstration

    Watch the full film and notice the transition into each scene, the stopping condition and the return journey. Pause when you need more time to read an explanation. The text in the film is in English.

  2. 2

    Prepare a separate working folder

    Make sure Node.js with npm, Playwright with Chromium and ffmpeg are installed. Use a separate folder with room for HTML, WAV, intermediate frames and the final video. Rendering may require substantial time and disk space.

  3. 3

    Copy the entire prompt

    Keep the structure, requirements and numbered instructions. Use the documented setup on this page when available. Pasting the text alone does not install tools or start a local render.

  4. 4

    Review the scenes and still frames

    Review the plan for all nine styles. Check one frame per musical beat before rendering the full film. Request corrections to text that overlaps, is hard to read or disappears too quickly.

  5. 5

    Render the video and soundtrack

    Check that window.seek(t) works in the HTML file. Export the soundtrack to WAV, render at 60 frames per second and combine video and audio with ffmpeg. Use the prompt’s three subframes per frame when supported by the rendering setup.

  6. 6

    Test and refine the result

    Play the entire export and check its duration, readability and audio synchronisation. Create a silent 10-second excerpt for previewing. Results can vary; request specific improvements instead of expecting an identical copy.