Home / All Skills / Content & Media Creation / manim
Content & Media Creation · iart-ai/manim-skills

manim

This skill should be used when the user asks to "make a math animation", "animate an equation", "use Manim", "make a 3Blue1Brown-style video", "plot or animate a graph/function", "visualize a math/physics/CS concept", "morph one formula into another", "animate a geometric proof", or "render a math explainer". Covers Manim Community Edition — Scenes, Mobjects, animations, LaTeX/MathTex, graphs, updaters/ValueTracker, 3D, and rendering to MP4/GIF via the CLI.

L4 High-Privilege · Graded auth & full auditV1 Commit-PinnedExecute CommandNetwork AccessWrite FileDual-pass Audit
Author iart-aiGitHub iart-ai/manim-skills ↗Stars 9License MIT(仓库根 LICENSE:MIT License / Copyright (c) 2026 iart.ai;.claude-plugin/plugin.json 声明 "license": "MIT",GitHub API license.spdx_id = MIT)Commit a15833c44d
Control levels describe skill capabilities and suggested control measures; they do not represent quality or safety certifications, nor do they dictate usability. Usage decisions rest entirely with users and administrators. Different agent hosts apply varying constraints; do not assume hosts provide automatic protection. Third-party skill copyrights belong to their original authors. Use at your own risk.

1How It Works & Mechanism

It turns mathematical animation into declarative Python: sequential play/wait calls inside construct() of a Scene subclass, where Manim evaluates each Mobject's state and Animation onto a timeline, rendering deterministic MP4/GIF frame-by-frame via the CLI.

skills/manim/SKILL.md
Every scene is declarative: you build vector objects, play timed animations over them, and render a deterministic MP4/GIF from the CLI.
"Declarative + CLI rendering" is its fundamental distinction from web animation skills: no browser, no real-time render loop, and the artifact is a file.

All capabilities stem from a triad: Scenes (orchestration) act on Mobjects (vector objects), expressed through Animations (timed transitions); all animation code lives in the single construct() method.

skills/manim/SKILL.md
Everything is **Scenes** (orchestration) acting on **Mobjects** (objects) via **Animations** (timed change).
The documentation uses this statement to establish the mental model for reading the entire guide; all subsequent cheat sheets are elaborations of it.

Mathematical typesetting is handled by LaTeX (Tex/MathTex, which must use raw string r"..."), while plain text is handled by Pango (Text/MarkupText, no LaTeX required) — this division directly dictates runtime prerequisites (whether a TeX distribution must be installed).

skills/manim/SKILL.md
**LaTeX is required** for `Tex`/`MathTex` (not for `Text`).
Missing glyph boxes (tofu) or compilation errors are direct signals of "LaTeX not installed / malformed TeX strings", listed as the top gotcha in the documentation.

Function and geometry animations are expressed using Axes + ax.plot, with ax.c2p mapping mathematical coordinates to screen space (hardcoding screen coordinates is prohibited); dynamic values rely on ValueTracker paired with always_redraw/add_updater to recalculate dependent objects per frame (e.g., points along curves, counters, tangents).

skills/manim/SKILL.md
Drive live values with `ValueTracker` + `always_redraw`/`add_updater` so dependent mobjects recompute every frame
"A single tracker driving everything" and "positioning points via c2p" together ensure scenes remain coherent across repeated edits.

3D and cameras form a distinct layer: ThreeDScene + set_camera_orientation / Surface / begin_ambient_camera_rotation; 2D uses MovingCameraScene with self.camera.frame.animate for zoom-in, tracking, and reset.

skills/manim/SKILL.md
`ThreeDScene` + `set_camera_orientation(phi=, theta=)`, `ThreeDAxes`, `Surface`, `begin_ambient_camera_rotation()`
The reference also provides a framing snapshot approach using save_state()/Restore for "zooming in and returning to the full view".

Determinism is a key selling point: the same scene renders identical frames, allowing a verification strategy where frames are rendered first (PNG, no video encoding) to verify math and layout before committing to full video output.

skills/manim/SKILL.md
Manim is deterministic — the same scene renders the same frames — so verify by rendering **frames** (PNG, no video encode) before committing to the full video.
This decouples "rendering cost" from "inspection cost" — enabling a cheap, repeatable verification loop.

The CLI provides three quality control levers: -s saves the last frame as PNG (no encoding), -n a,b renders only an animation index range (stopping mid-scene to check a single frame), and -q l iterates at low quality; once verified, -qh outputs the final video under media/videos|images.

skills/manim/SKILL.md
- `-s` — **save the last frame as a PNG** (no video encode — the verification lever, see below).
Makes "verification" a first-class CLI parameter rather than requiring separate test code.

Capability boundaries are explicitly drawn: no UI animations, social media/marketing videos, or CSV business charts; its core strength lies in mathematical typesetting and intuitive visualization.

skills/manim/SKILL.md
Not the tool for UI motion, social/marketing video, or data-from-CSV business charts
Proactively providing "when not to use me" criteria is a rare but highly effective design for agent routing.

Wall-clock timing and unseeded randomness are prohibited: construct() executes only once to script the timeline without a real-time loop; random operations must be seeded.

skills/manim/SKILL.md
`construct()` runs once to *script* the timeline; there is no realtime loop — never use wall-clock time or randomness without a seed.
Shares the frame-driven discipline of other packs by the same author: reproducibility first.

2Core Capabilities

01Scene / Mobject / Animation triad + complete cheat sheet (creation, transformation, positioning, duration, and easing)
02Equation animation and term-by-term morphing: Write / TransformMatchingTex (animating only changing parts between matching sub-TeX) / {{ }} grouping / substring coloring / custom LaTeX packages
03.animate syntax (animating arbitrary method calls, chainable), concurrent animations in play, LaggedStart staggering, rate_func easing
04Axes and graphing: Axes/NumberPlane, plot, c2p/p2c coordinate mapping, area under curves, and Riemann rectangles
05Dynamic value driving: ValueTracker + always_redraw / add_updater (points along curves, animated counters, tangent/secant bundles)
06Camera and 3D: ThreeDScene + set_camera_orientation + Surface/parametric surfaces + ambient camera rotation; 2D MovingCameraScene for zoom/track/reset
07CLI rendering and QA levers: -q quality presets, -p preview, -s save last frame, -n a,b render range, --format=gif, with artifacts automatically saved under media/
08LaTeX prerequisite diagnostics: diagnosing missing glyph boxes or compilation errors as "LaTeX not installed / broken TeX string", enforcing raw strings
09Scene-level CLI quickstart path (installation → single Scene preview → high-quality export)

3External Dependencies

KindDependency / Endpoint
clipip install manim(安装 Manim Community Edition,含 Python 3.9+ / ffmpeg / LaTeX 三项前置说明)
climanim CLI(-q / -p / -s / -n / --format=gif 渲染与质检)
packageManim Community Edition(数学动画引擎本体,官方发包)
packageLaTeX 发行版(TeX Live / MiKTeX):仅 Tex / MathTex 需要;Text / MarkupText 走 Pango 不需要
packagenumpy(Manim 的数学依赖;reference 的 3D 曲面前置直接用 np.sin/np.cos)
cliffmpeg / ffprobe(Manim 编码 MP4 的底层依赖;仓库根 contact-sheet.sh 拼图与 probe-mp4.sh 断言)
network运行时无网络调用:skill 不访问任何 API/CDN;Manim 场景是纯本地 Python + 本地 ffmpeg + 本地 LaTeX 编译

4Recommended Governance & Evidence

Suggested Controls for Safe Operation
For Agent Runtime
Graded/per-use authorization, sandbox recommended
For Administrators
Approval workflow, rollback support, full audit
Evidence & Triggers (File Paths & Excerpts)
  • scripts/: Executes local script or command: manim CLI (-pql / -sql / -s / -n a,b / -qh / -qm --format=gif) for local rendering and QA, evaluating scenes frame-by-frame
  • 网络端点: Declares external network access: Zero runtime network calls: Manim scenes run as purely local Python + local ffmpeg + local LaTeX; the skill references no external APIs, CDNs, or remote servers
  • 本地工作目录: File read/write and artifact output: media/videos/<file>/<quality>/<Scene>.mp4 and media/images/.../<Scene>.png (-s)
Audit Notes: The audit subject is the skill directory itself (skills/manim/: SKILL.md + 3 references/ + 0-byte README.md; no scripts, no credential reads, no disk writes inside the directory). Behavioral footprint = local CLI + local I/O: executes the locally installed manim CLI (with local ffmpeg and local LaTeX compilation), writing output only to media/ and project directories; zero outbound network calls, zero credential/env reading, and no telemetry or evasion at runtime. Why not Orange: third-party dependencies are phrased as "prerequisite setup instructions" (`pip install manim` + optional TeX distribution), and execution invokes a locally installed CLI rather than fetching and executing remote packages at runtime like the author's Remotion-based skills via `npx ...`; this aligns with site precedent (gsap-react treats npm dependencies as setup instructions without elevation; hyperframes-animation / hyperframes-audio are rated Blue due to "official package installation + local CLI + local I/O"). Why not Green: involves external dependencies and local disk writes (media/ artifacts, LaTeX intermediate files), and TeX strings are passed into a compiler — while generating local content, it retains an execution footprint broader than pure text skills. Trigger conditions: rendering executes scene scripts and ffmpeg on the local machine; pip/TeX installation is determined by user action.

5Second-Pass Verification

  • [ok] 外部依赖调用点复核(pip install manim / manim CLI / ffmpeg / LaTeX / numpy) — SKILL.md Setup 节确有 `pip install manim # needs Python 3.9+, ffmpeg, and a LaTeX distribution (for Tex/MathTex)` 与 `manim -pql scene.py SquareToCircle`;verify 段确有 `manim -sql scene.py MyScene -n 0,3`;math-and-text 确有 TeX Live/MiKTeX 说明;3d-and-camera 确有 np.sin/np.cos 用法;仓库根 scripts/README.md 确有 manim 与 probe-mp4 的用法示例。全部落地,非推测。
  • [ok] 「运行期零网络」反查 — 四份文档与仓库脚本中无 API endpoint、无 curl/wget、无 fetch/requests、无 CDN import;Manim 场景全部是本地 Python 对象构造。唯一网络相关表述集中在 Setup 的包安装指令。结论成立。
  • [ok] 无凭证 / 无 env 读取 — 全文无 API_KEY/token/secret/.env/.netrc 读取,无浏览器 cookie 取用,无环境变量透传;与同 pack 的 Remotion 系(走 npm 远端包)和 generative-illustration(走 OPENROUTER_API_KEY)形成鲜明对比。
  • [ok] 确定性主张的成立条件 — SKILL.md 明确「Manim is deterministic — the same scene renders the same frames」,并在 gotchas 收尾补上边界:「never use wall-clock time or randomness without a seed」——即确定性依赖于不引入墙钟、随机须播种。主张有边界,非无条件承诺。
  • [ok] 目录资产面清点 — skills/manim/ 下仅 SKILL.md(136 行)、references/ 三份(math-and-text 70 行 / graphs-and-updaters 61 行 / 3d-and-camera 68 行)、0 字节 README.md;无 scripts/、无 .py 样例文件、无模板资产——「纯指令 + reference」结论成立(场景脚本由使用者/agent 现写)。
  • [discrepancy] 跨引用可解析性 — SKILL.md 提到「the `motion-design-skills` pack (`animation-principles` ...)」——该 pack 与 animation-principles 均不在本 repo(本 repo 仅 skills/manim 一个 skill),属同作者的另一个 pack,单装本 repo 时该引用悬空。另正文引用的 `scripts/contact-sheet.sh`、`scripts/probe-mp4.sh` 位于本 repo 根,单装 skill 目录会悬空。
  • [ok] 能力边界声明与正文覆盖的一致性 — SKILL.md 自述「Not the tool for UI motion, social/marketing video, or data-from-CSV business charts」,而正文与三份 reference 确实只覆盖数学排版、函数/图形、3D 与相机;未出现与自述边界冲突的内容(无 UI/营销/CSV 章节)。
  • [ok] 档位判据与站内先例的一致性 — 判蓝的两条支撑:① 依赖以「安装指令」形式出现、执行的是本地 CLI(先例 gsap-react 明确不因 npm 依赖抬档;hyperframes-animation/hyperframes-audio 因官方包安装 + 本地 CLI + 本地读写判蓝);② 运行期无网络外发、无凭证、无采集(不满足黄/橙)。同时保留「有外部依赖 + 有本地写盘 + TeX 编译面」的现实,故不判绿。判据留痕如上,便于复核与跨批次口径统一。

6Verdict & Scenarios

  • Treats "frame rendering" as a first-class QA lever (-s / -n a,b outputting PNG without encoding), keeping inspection costs far lower than full video rendering
  • Declarative + CLI rendering provides inherent determinism, ensuring "same input yields same output" without extra engineering
  • Cleanly delineated capability boundaries (no UI/marketing/CSV charts), preventing misrouting by agents
  • Dynamic value driving adheres to a single source of truth and cleanup discipline (ValueTracker + always_redraw, cleaned up with clear_updaters)
  • Prerequisites are clearly documented and tiered; users can still render text outputs using Text even without LaTeX installed
  • Best for: Ideal for educational and intuitive visualizations in mathematics, physics, and computer science: displaying and morphing equations, step-by-step substitution highlighting, plotting functions with points moving along curves, areas and Riemann sums, geometric proof walk-throughs, 3D surfaces, and camera orbits — especially 3Blue1Brown-style short videos requiring "proper mathematical typesetting brought to life".
    Not for: Not suitable for UI animations, social media/marketing clips, or CSV business charts (the skill explicitly disclaims these and redirects to other packs); not suitable for full productions requiring complex layer compositing, voiceover editing, or video VFX (Manim handles only mathematical animation); not suitable for browser/web-native delivery — its artifacts are local MP4/GIF files.
    Install Agent-Ready
    ① Verified Mirror 2026-09-28
    Option A · Direct DownloadDownload manim.tar.gz
    sha256: 5ebe4ae4e425d911…
    Option B · Copy Guide for Agent
    install.json
    Agents automatically download and verify mirrors from this JSON guide.
    ② Upstream GitHub
    GitHub Repo ↗
    Pinned to commit a15833c44d.