Skip to content

About

A studio for learning causal inference through Jupyter notebooks and videos.

Topics

Resources

Contributing

Stars

20 stars

Watchers

0 watching

Forks

Repository files navigation

Causal Studio

Turn challenging math and statistics concepts into 3Blue1Brown-style videos.

An open-source Manim skill built while producing Causal Studio’s causal inference series.
Simply describe the video you want to create in Claude Code or Codex.

Make a video · Watch on YouTube · Read the book · 한국어

Two city deposit trends align to a shared baseline, revealing the difference in post-campaign growth.
Difference-in-differences · Billboard campaign example

Make your first video

  1. Clone the skill-only branch.

    git clone -b skill-only https://github.com/CausalInferenceLab/causal-studio
  2. Open the folder in Claude Code or Codex and describe your video.

    Use manim-video-pipeline to explain why A/B tests need randomization in a 45-second video.
    Show two ticket checkouts that start with skewed groups of shoppers, leading to a biased result.
    Use three scenes to show the initial bias, a coin flip assigning each shopper,
    and the fair comparison afterward.
    

If you have a script or a Jupyter notebook with explanations and plots, pass its file path to the agent. Otherwise, a single-sentence topic is enough to get started. Example notebook

You can render the initial preview without a voice API key.

How the video comes together

  1. Plan the explanation. The agent studies a relevant 3Blue1Brown passage and its Manim code, drafts the script, and maps out camera movements and key visual reveals.
  2. Preview key transitions. Inspect frames before, during, and after major transitions. Ask the agent to fix any clipping, overlapping text, or jarring motion and re-render only that scene.
  3. Add narration and export. OpenAI or ElevenLabs turns your script into voiceover audio. The agent uses *.timings.json to sync the final animation and outputs an MP4, thumbnail, and SRT subtitles (when narrated). Voice setup

Ask the same skill for just a script, a scene revision, or an SRT. For a full video, it delegates research, scene production, and independent review when sub-agents are available.

Project structure and scene revisions

Each scene has its own Manim script and, when narrated, a corresponding text file.

videos/ab_test/en/
├── project.toml              # References and default scene configuration
├── lesson.md                 # Production brief generated when starting from a topic
├── scene_plan.md             # References, framing, and storyboard
├── narration/                # Scene-by-scene scripts
│   ├── 01_question.txt
│   ├── 02_assignment.txt
│   └── 03_comparison.txt
├── scenes/                   # Manim source files
│   ├── scene_01_question.py
│   ├── scene_02_assignment.py
│   └── scene_03_comparison.py
└── build/
    ├── audio/                # MP3 narration and timing files
    ├── logs/                 # Logs per render attempt
    ├── manim/                # Rendered individual scenes
    ├── review/               # Transition frames and contact sheets
    └── final/                # Final MP4, thumbnail PNG, and optional SRT

In scene 2, keep the first group visible on screen while the assignment changes, then re-render just that scene.

Explore Causal Studio

Check out the English and Korean RDD projects to see real examples of scene code and scripts from the course. To work on the book or existing course videos, clone the full repository, which includes the same skill:

git clone https://github.com/CausalInferenceLab/causal-studio

View the skill · Contribute


If this skill helps you make a video, consider giving Causal Studio a star.

MIT License. External assets such as 3Blue1Brown references and Tabler Icons remain subject to their respective licenses.

About

A studio for learning causal inference through Jupyter notebooks and videos.

Topics

Resources

Contributing

Stars

20 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages