Skip to content
Back to search

manim_skill

SkillWorks with Claude CodeGitHub

Agent skills for Manim to create 3Blue1Brown style animations.

Safety scan

A static text scan, not a guarantee. Select the badge to see what was scanned and every finding.

Checked today
Badge for your README
findsafeskills safety rating

Markdown

[![findsafeskills safety rating](/api/listings/adithya-s-k-manim-skill/badge.svg)](/listings/adithya-s-k-manim-skill)

HTML

<a href="/listings/adithya-s-k-manim-skill"><img src="/api/listings/adithya-s-k-manim-skill/badge.svg" alt="findsafeskills safety rating" /></a>

Install

i

Install instructions from the README

As written by the repo's author. findsafeskills has not verified these steps.

Prerequisites (Both Versions)

1. **Python 3.7+** - Required 2. **FFmpeg** - For video encoding 3. **LaTeX** - For mathematical typesetting (TeX Live, MiKTeX, or MacTeX)

Install FFmpeg

**macOS:**

brew install ffmpeg

**Ubuntu/Debian:**

sudo apt update
sudo apt install ffmpeg

**Windows:** Download from https://ffmpeg.org/download.html and add to PATH

Install LaTeX

**macOS:**

brew install mactex

**Ubuntu/Debian:**

sudo apt install texlive-full

**Windows:** Install MiKTeX from https://miktex.org/download

---

Installing Manim Community Edition

# Using pip
pip install manim

# Using uv (recommended for this project)
uv pip install manim

# Verify installation
manim --version

**Documentation**: https://docs.manim.community/

---

Installing ManimGL

# Using pip
pip install manimgl

# Using uv (recommended for this project)
uv pip install manimgl

# Verify installation
manimgl --version

**Additional macOS (ARM) requirement:**

arch -arm64 brew install pkg-config cairo

---

What was scanned

The files the safety scan read, as written by the repository's author and shown as plain text. Lines with a finding are marked.

README.md · README · 414 lines

View this file on GitHub (read at the repository's current version: the scan did not record which commit it read)

  1. # Manim Skills Repository
  2. ![Visitors](https://visitor-badge.laobi.icu/badge?page_id=adithya-s-k.manim_skill)
  3. ![GitHub stars](https://img.shields.io/github/stars/adithya-s-k/manim_skill?style=flat-square)
  4. ![GitHub forks](https://img.shields.io/github/forks/adithya-s-k/manim_skill?style=flat-square)
  5. ![GitHub issues](https://img.shields.io/github/issues/adithya-s-k/manim_skill?style=flat-square)
  6. ![License](https://img.shields.io/github/license/adithya-s-k/manim_skill?style=flat-square)
  7. > **⚡ Quick Start:** Add both Manim skills to your AI agent instantly:
  8. > ```bash
  9. > npx skills add adithya-s-k/manim_skill
  10. > ```
  11. A comprehensive collection of best practices, patterns, and examples for both **Manim Community Edition** and **ManimGL** (3Blue1Brown's version). This repository provides battle-tested code examples and guidelines for creating mathematical animations.
  12. https://github.com/user-attachments/assets/3cd398b7-7cc6-43c1-a6e9-20077be6b009
  13. ## 📚 About the Two Versions
  14. ### Manim Community Edition (`manim`)
  15. - **Repository**: https://github.com/ManimCommunity/manim
  16. - **Focus**: Community-maintained, stable, well-documented
  17. - **Best For**: Production use, educational content, collaborative projects
  18. - **Command**: `manim` CLI
  19. - **Import**: `from manim import *`
  20. ### ManimGL (`manimgl`)
  21. - **Repository**: https://github.com/3b1b/manim
  22. - **Focus**: Grant Sanderson's (3Blue1Brown) original version with OpenGL rendering
  23. - **Best For**: Interactive development, 3D scenes, rapid prototyping
  24. - **Command**: `manimgl` CLI
  25. - **Import**: `from manimlib import *`
  26. > **Important**: These are **separate, incompatible** frameworks. Code written for one will not work with the other without modifications.
  27. ---
  28. ## 🚀 Installation
  29. ### Prerequisites (Both Versions)
  30. 1. **Python 3.7+** - Required
  31. 2. **FFmpeg** - For video encoding
  32. 3. **LaTeX** - For mathematical typesetting (TeX Live, MiKTeX, or MacTeX)
  33. #### Install FFmpeg
  34. **macOS:**
  35. ```bash
  36. brew install ffmpeg
  37. ```
  38. **Ubuntu/Debian:**
  39. ```bash
  40. sudo apt update
  41. sudo apt install ffmpeg
  42. ```
  43. **Windows:**
  44. Download from https://ffmpeg.org/download.html and add to PATH
  45. #### Install LaTeX
  46. **macOS:**
  47. ```bash
  48. brew install mactex
  49. ```
  50. **Ubuntu/Debian:**
  51. ```bash
  52. sudo apt install texlive-full
  53. ```
  54. **Windows:**
  55. Install MiKTeX from https://miktex.org/download
  56. ---
  57. ### Installing Manim Community Edition
  58. ```bash
  59. # Using pip
  60. pip install manim
  61. # Using uv (recommended for this project)
  62. uv pip install manim
  63. # Verify installation
  64. manim --version
  65. ```
  66. **Documentation**: https://docs.manim.community/
  67. ---
  68. ### Installing ManimGL
  69. ```bash
  70. # Using pip
  71. pip install manimgl
  72. # Using uv (recommended for this project)
  73. uv pip install manimgl
  74. # Verify installation
  75. manimgl --version
  76. ```
  77. **Additional macOS (ARM) requirement:**
  78. ```bash
  79. arch -arm64 brew install pkg-config cairo
  80. ```
  81. ---
  82. ## 🔌 Skills.sh Integration
  83. This repository provides two **AI Agent Skills** that can be installed with a single command using [skills.sh](https://skills.sh/):
  84. ### Install with npx (Recommended)
  85. ```bash
  86. # Install Manim Community Edition best practices
  87. npx skills add adithya-s-k/manim_skill/skills/manimce-best-practices
  88. # Install ManimGL best practices
  89. npx skills add adithya-s-k/manim_skill/skills/manimgl-best-practices
  90. # Or install both
  91. npx skills add adithya-s-k/manim_skill/skills/manimce-best-practices adithya-s-k/manim_skill/skills/manimgl-best-practices
  92. ```
  93. ### What are Skills?
  94. Skills are **reusable capabilities for AI coding agents**. Once installed, your AI assistant (like Claude, GitHub Copilot, or Cursor) automatically gains access to:
  95. - ✅ Domain-specific best practices
  96. - ✅ Working code examples
  97. - ✅ Common patterns and anti-patterns
  98. - ✅ Framework-specific knowledge
  99. The skills follow the [Agent Skills open standard](https://github.com/anthropics/skills) and work across multiple AI tools.
  100. ### When Skills Activate
  101. **manimce-best-practices** - Automatically loads when:
  102. - You import `from manim import *`
  103. - You use the `manim` CLI command
  104. - You work with Scene classes, mathematical animations, or LaTeX rendering
  105. - You create educational videos or visual explanations with Manim Community
  106. **manimgl-best-practices** - Automatically loads when:
  107. - You import `from manimlib import *`
  108. - You use the `manimgl` CLI command
  109. - You work with InteractiveScene, 3D rendering, or camera frame control
  110. - You use interactive mode with `.embed()` or `checkpoint_paste()`
  111. ---
  112. ## 📖 Using This Repository
  113. ### Repository Structure
  114. ```
  115. manim_skill/
  116. ├── skills/
  117. │ ├── manimce-best-practices/ # Manim Community Edition skills
  118. │ │ ├── SKILL.md # Skill metadata
  119. │ │ └── rules/ # Individual best practice guides
  120. │ │ ├── animations.md
  121. │ │ ├── scenes.md
  122. │ │ ├── mobjects.md
  123. │ │ └── ...
  124. │ │
  125. │ └── manimgl-best-practices/ # ManimGL skills
  126. │ ├── SKILL.md
  127. │ └── rules/
  128. │ ├── animations.md
  129. │ ├── 3d.md
  130. │ ├── camera.md
  131. │ └── ...
  132. │
  133. └── tests/
  134. ├── manimce/ # Tests for Community Edition
  135. └── manimgl/ # Tests for ManimGL
  136. ```
  137. ### What's Inside Each Skill File?
  138. Each `.md` file contains:
  139. - **Best practices** for specific Manim features
  140. - **Working code examples** (all tested!)
  141. - **Common patterns** and use cases
  142. - **Pitfalls to avoid**
  143. - **API differences** between versions
  144. ---
  145. ## 🎯 Quick Start Examples
  146. ### Manim Community Edition
  147. ```python
  148. from manim import *
  149. class BasicExample(Scene):
  150. def construct(self):
  151. circle = Circle()
  152. circle.set_fill(BLUE, opacity=0.5)
  153. circle.set_stroke(BLUE_E, width=4)
  154. self.play(Create(circle))
  155. self.wait()
  156. ```
  157. **Run it:**
  158. ```bash
  159. manim -pql scene.py BasicExample
  160. # -p: preview after rendering
  161. # -q: quality (l=low, m=medium, h=high)
  162. ```
  163. ### ManimGL
  164. ```python
  165. from manimlib import *
  166. class BasicExample(InteractiveScene):
  167. def construct(self):
  168. circle = Circle()
  169. circle.set_fill(BLUE, opacity=0.5)
  170. circle.set_stroke(BLUE_E, width=4)
  171. self.play(ShowCreation(circle))
  172. self.wait()
  173. ```
  174. **Run it:**
  175. ```bash
  176. manimgl scene.py BasicExample --write_file
  177. # --write_file: save video output
  178. # -s: skip to last frame
  179. # -w: write file without opening
  180. ```
  181. ---
  182. ## 🧪 Running Tests
  183. This repository includes comprehensive tests to ensure all code examples work correctly.
  184. ### Test Manim Community Edition Skills
  185. ```bash
  186. # Test all files
  187. uv run python tests/manimce/test_all_skills.py
  188. # Test specific file
  189. uv run python tests/manimce/test_all_skills.py animations.md
  190. # Run with multiple workers (faster)
  191. uv run python tests/manimce/test_all_skills.py -j 4
  192. ```
  193. ### Test ManimGL Skills
  194. ```bash
  195. # Test all files
  196. uv run python tests/manimgl/test_all_skills.py
  197. # Test specific file
  198. uv run python tests/manimgl/test_all_skills.py 3d.md
  199. # Run with multiple workers (use caution - can cause OOM)
  200. uv run python tests/manimgl/test_all_skills.py -j 4
  201. ```
  202. > **Note**: Parallel testing with many workers can cause out-of-memory errors. Use 4-6 workers max, or test files individually.
  203. ---
  204. ## 🔍 Key Differences Between Versions
  205. | Feature | Manim Community | ManimGL |
  206. |---------|----------------|---------|
  207. | **Import** | `from manim import *` | `from manimlib import *` |
  208. | **CLI Command** | `manim` | `manimgl` |
  209. | **Scene Base Class** | `Scene`, `MovingCameraScene` | `Scene`, `InteractiveScene` |
  210. | **Creation Animation** | `Create()` | `ShowCreation()` |
  211. | **Text Class** | `Text()`, `MathTex()` | `Text()`, `Tex()` |
  212. | **3D Rendering** | Limited | Full OpenGL support |
  213. | **Interactive Mode** | No | Yes (`-se` flag, `.embed()`) |
  214. | **Camera Control** | `MovingCameraScene` | `self.camera.frame` |
  215. | **Configuration** | Python config | YAML files |
  216. | **Color Constants** | Same | Same + variations (e.g., `BLUE_A`, `BLUE_E`) |
  217. ---
  218. ## 📚 Exploring Skills
  219. ### For Manim Community Edition:
  220. Start with these guides in `skills/manimce-best-practices/rules/`:
  221. 1. **scenes.md** - Scene structure and lifecycle
  222. 2. **animations.md** - Basic animation patterns
  223. 3. **mobjects.md** - Creating and manipulating objects
  224. 4. **colors.md** - Color systems and styling
  225. 5. **text.md** - Text and LaTeX rendering
  226. ### For ManimGL:
  227. Start with these guides in `skills/manimgl-best-practices/rules/`:
  228. 1. **scenes.md** - Scene types and InteractiveScene
  229. 2. **animations.md** - Animation fundamentals
  230. 3. **camera.md** - Camera movement and 3D orientation
  231. 4. **3d.md** - 3D object creation and rendering
  232. 5. **interactive.md** - Interactive development workflow
  233. ---
  234. ## 🤝 Contributing
  235. Found an issue with an example? Want to add a new best practice?
  236. 1. Ensure your code example works with the target Manim version
  237. 2. Add it to the appropriate skill file
  238. 3. Run the tests to verify: `uv run python tests/<version>/test_all_skills.py <filename>`
  239. 4. Submit a pull request
  240. ---
  241. ## 📄 License
  242. This repository is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
  243. **Note**: This license applies to the educational materials and code examples in this repository. The underlying Manim frameworks (Manim Community Edition and ManimGL) have their own respective licenses.
  244. ---
  245. ## 🔗 Resources
  246. ### Manim Community Edition
  247. - **Documentation**: https://docs.manim.community/
  248. - **Discord**: https://www.manim.community/discord/
  249. - **GitHub**: https://github.com/ManimCommunity/manim
  250. ### ManimGL
  251. - **Documentation**: https://3b1b.github.io/manim/
  252. - **GitHub**: https://github.com/3b1b/manim
  253. - **Tutorial Videos**: Grant's YouTube channel
  254. ### General
  255. - **3Blue1Brown**: https://www.youtube.com/@3blue1brown
  256. - **Manim Community**: https://www.manim.community/
  257. ---
  258. ## ⚠️ Troubleshooting
  259. ### Common Issues
  260. **"Command not found: manim/manimgl"**
  261. - Verify installation: `pip list | grep manim`
  262. - Check PATH configuration
  263. - Try: `python -m manim` or `python -m manimlib`
  264. **LaTeX errors**
  265. - Install full LaTeX distribution (not basic)
  266. - ManimCE: Try `manim --tex_template <template>` with different templates
  267. - ManimGL: Check `custom_defaults.yml` for LaTeX configuration
  268. **Video won't play**
  269. - Install media codecs for your OS
  270. - Try different quality settings (`-ql`, `-qm`, `-qh`)
  271. - Check FFmpeg installation: `ffmpeg -version`
  272. **Out of Memory (parallel tests)**
  273. - Reduce worker count: `-j 2` or `-j 4`
  274. - Test files individually
  275. - Close other applications
  276. **Import errors / wrong version**
  277. - Check you're importing the right version:
  278. - `from manim import *` → Manim Community
  279. - `from manimlib import *` → ManimGL
  280. - Uninstall conflicting versions: `pip uninstall manim manimgl manimlib`
  281. - Reinstall the version you need
  282. ---
  283. ## 🙏 Acknowledgments
  284. This repository exists thanks to the incredible work of:
  285. ### Grant Sanderson (3Blue1Brown)
  286. Creator of the original **Manim** animation engine and the **3Blue1Brown** YouTube channel. Grant's pioneering work in mathematical visualization has inspired millions of learners worldwide and created an entirely new paradigm for explaining complex concepts through programmatic animation. His commitment to open-source education and visual storytelling has fundamentally changed how mathematics is taught and understood.
  287. **Website**: https://www.3blue1brown.com/
  288. **YouTube**: https://www.youtube.com/@3blue1brown
  289. **Manim (ManimGL)**: https://github.com/3b1b/manim
  290. ### The Manim Community
  291. The dedicated team and contributors who maintain **Manim Community Edition**, ensuring the framework remains accessible, well-documented, and actively developed. Their tireless efforts in creating comprehensive documentation, managing community support, and continuously improving the codebase have made mathematical animation accessible to educators, students, and creators everywhere.
  292. **Website**: https://www.manim.community/
  293. **GitHub**: https://github.com/ManimCommunity/manim
  294. **Discord**: https://www.manim.community/discord/
  295. ---
  296. ### Standing on the Shoulders of Giants
  297. Both frameworks represent countless hours of development, documentation, community support, and creative problem-solving. This repository simply aims to organize and share knowledge about these powerful tools. All credit for the underlying technology goes to Grant Sanderson and the Manim Community contributors.
  298. Thank you for making mathematical beauty programmable and accessible to all. 🎓✨

Ratings and comments

Sign in to rate this skill.

Sign in

Free to use. If it’s helped, pass it on.