hermes-agent/website/docs/user-guide/skills/bundled/creative/creative-manim-video.md
Teknium 289cc47631
docs: resync reference, user-guide, developer-guide, and messaging pages against code (#17738)
Broad drift audit against origin/main (b52b63396).

Reference pages (most user-visible drift):
- slash-commands: add /busy, /curator, /footer, /indicator, /redraw, /steer
  that were missing; drop non-existent /terminal-setup; fix /q footnote
  (resolves to /queue, not /quit); extend CLI-only list with all 24
  CLI-only commands in the registry
- cli-commands: add dedicated sections for hermes curator / fallback /
  hooks (new subcommands not previously documented); remove stale
  hermes honcho standalone section (the plugin registers dynamically
  via hermes memory); list curator/fallback/hooks in top-level table;
  fix completion to include fish
- toolsets-reference: document the real 52-toolset count; split browser
  vs browser-cdp; add discord / discord_admin / spotify / yuanbao;
  correct hermes-cli tool count from 36 to 38; fix misleading claim
  that hermes-homeassistant adds tools (it's identical to hermes-cli)
- tools-reference: bump tool count 55 -> 68; add 7 Spotify, 5 Yuanbao,
  2 Discord toolsets; move browser_cdp/browser_dialog to their own
  browser-cdp toolset section
- environment-variables: add 40+ user-facing HERMES_* vars that were
  undocumented (--yolo, --accept-hooks, --ignore-*, inference model
  override, agent/stream/checkpoint timeouts, OAuth trace, per-platform
  batch tuning for Telegram/Discord/Matrix/Feishu/WeCom, cron knobs,
  gateway restart/connect timeouts); dedupe the Cron Scheduler section;
  replace stale QQ_SANDBOX with QQ_PORTAL_HOST

User-guide (top level):
- cli.md: compression preserves last 20 turns, not 4 (protect_last_n: 20)
- configuration.md: display.platforms is the canonical per-platform
  override key; tool_progress_overrides is deprecated and auto-migrated
- profiles.md: model.default is the config key, not model.model
- sessions.md: CLI/TUI session IDs use 6-char hex, gateway uses 8
- checkpoints-and-rollback.md: destructive-command list now matches
  _DESTRUCTIVE_PATTERNS (adds rmdir, cp, install, dd)
- docker.md: the container runs as non-root hermes (UID 10000) via
  gosu; fix install command (uv pip); add missing --insecure on the
  dashboard compose example (required for non-loopback bind)
- security.md: systemctl danger pattern also matches 'restart'
- index.md: built-in tool count 47 -> 68
- integrations/index.md: 6 STT providers, 8 memory providers
- integrations/providers.md: drop fictional dashscope/qwen aliases

Features:
- overview.md: 9 image models (not 8), 9 TTS providers (not 5),
  8 memory providers (Supermemory was missing)
- tool-gateway.md: 9 image models
- tools.md: extend common-toolsets list with search / messaging /
  spotify / discord / debugging / safe
- fallback-providers.md: add 6 real providers from PROVIDER_REGISTRY
  (lmstudio, kimi-coding-cn, stepfun, alibaba-coding-plan,
  tencent-tokenhub, azure-foundry)
- plugins.md: Available Hooks table now includes on_session_finalize,
  on_session_reset, subagent_stop
- built-in-plugins.md: add the 7 bundled plugins the page didn't
  mention (spotify, google_meet, three image_gen providers, two
  dashboard examples)
- web-dashboard.md: add --insecure and --tui flags
- cron.md: hermes cron create takes positional schedule/prompt, not
  flags

Messaging:
- telegram.md: TELEGRAM_WEBHOOK_SECRET is now REQUIRED when
  TELEGRAM_WEBHOOK_URL is set (gateway refuses to start without it
  per GHSA-3vpc-7q5r-276h). Biggest user-visible drift in the batch.
- discord.md: HERMES_DISCORD_TEXT_BATCH_SPLIT_DELAY_SECONDS default
  is 2.0, not 0.1
- dingtalk.md: document DINGTALK_REQUIRE_MENTION /
  FREE_RESPONSE_CHATS / MENTION_PATTERNS / HOME_CHANNEL /
  ALLOW_ALL_USERS that the adapter supports
- bluebubbles.md: drop fictional BLUEBUBBLES_SEND_READ_RECEIPTS env
  var; the setting lives in platforms.bluebubbles.extra only
- qqbot.md: drop dead QQ_SANDBOX; add real QQ_PORTAL_HOST and
  QQ_GROUP_ALLOWED_USERS
- wecom-callback.md: replace 'hermes gateway start' (service-only)
  with 'hermes gateway' for first-time setup

Developer-guide:
- architecture.md: refresh tool/toolset counts (61/52), terminal
  backend count (7), line counts for run_agent.py (~13.7k), cli.py
  (~11.5k), main.py (~10.4k), setup.py (~3.5k), gateway/run.py
  (~12.2k), mcp_tool.py (~3.1k); add yuanbao adapter, bump platform
  adapter count 18 -> 20
- agent-loop.md: run_agent.py line count 10.7k -> 13.7k
- tools-runtime.md: add vercel_sandbox backend
- adding-tools.md: remove stale 'Discovery import added to
  model_tools.py' checklist item (registry auto-discovery)
- adding-platform-adapters.md: mark send_typing / get_chat_info as
  concrete base methods; only connect/disconnect/send are abstract
- acp-internals.md: ACP sessions now persist to SessionDB
  (~/.hermes/state.db); acp.run_agent call uses
  use_unstable_protocol=True
- cron-internals.md: gateway runs scheduler in a dedicated background
  thread via _start_cron_ticker, not on a maintenance cycle; locking
  is cross-process via fcntl.flock (Unix) / msvcrt.locking (Windows)
- gateway-internals.md: gateway/run.py ~12k lines
- provider-runtime.md: cron DOES support fallback (run_job reads
  fallback_providers from config)
- session-storage.md: SCHEMA_VERSION = 11 (not 9); add migrations
  10 and 11 (trigram FTS, inline-mode FTS5 re-index); add
  api_call_count column to Sessions DDL; document messages_fts_trigram
  and state_meta in the architecture tree
- context-compression-and-caching.md: remove the obsolete 'context
  pressure warnings' section (warnings were removed for causing
  models to give up early)
- context-engine-plugin.md: compress() signature now includes
  focus_topic param
- extending-the-cli.md: _build_tui_layout_children signature now
  includes model_picker_widget; add to default layout

Also fixed three pre-existing broken links/anchors the build warned
about (docker.md -> api-server.md, yuanbao.md -> cron-jobs.md and
tips#background-tasks, nix-setup.md -> #container-aware-cli).

Regenerated per-skill pages via website/scripts/generate-skill-docs.py
so catalog tables and sidebar are consistent with current SKILL.md
frontmatter.

docusaurus build: clean, no broken links or anchors.
2026-04-29 20:55:59 -07:00

12 KiB

title sidebar_label description
Manim Video — Manim CE animations: 3Blue1Brown math/algo videos Manim Video Manim CE animations: 3Blue1Brown math/algo videos

{/* This page is auto-generated from the skill's SKILL.md by website/scripts/generate-skill-docs.py. Edit the source SKILL.md, not this page. */}

Manim Video

Manim CE animations: 3Blue1Brown math/algo videos.

Skill metadata

Source Bundled (installed by default)
Path skills/creative/manim-video
Version 1.0.0

Reference: full SKILL.md

:::info The following is the complete skill definition that Hermes loads when this skill is triggered. This is what the agent sees as instructions when the skill is active. :::

Manim Video Production Pipeline

When to use

Use when users request: animated explanations, math animations, concept visualizations, algorithm walkthroughs, technical explainers, 3Blue1Brown style videos, or any programmatic animation with geometric/mathematical content. Creates 3Blue1Brown-style explainer videos, algorithm visualizations, equation derivations, architecture diagrams, and data stories using Manim Community Edition.

Creative Standard

This is educational cinema. Every frame teaches. Every animation reveals structure.

Before writing a single line of code, articulate the narrative arc. What misconception does this correct? What is the "aha moment"? What visual story takes the viewer from confusion to understanding? The user's prompt is a starting point — interpret it with pedagogical ambition.

Geometry before algebra. Show the shape first, the equation second. Visual memory encodes faster than symbolic memory. When the viewer sees the geometric pattern before the formula, the equation feels earned.

First-render excellence is non-negotiable. The output must be visually clear and aesthetically cohesive without revision rounds. If something looks cluttered, poorly timed, or like "AI-generated slides," it is wrong.

Opacity layering directs attention. Never show everything at full brightness. Primary elements at 1.0, contextual elements at 0.4, structural elements (axes, grids) at 0.15. The brain processes visual salience in layers.

Breathing room. Every animation needs self.wait() after it. The viewer needs time to absorb what just appeared. Never rush from one animation to the next. A 2-second pause after a key reveal is never wasted.

Cohesive visual language. All scenes share a color palette, consistent typography sizing, matching animation speeds. A technically correct video where every scene uses random different colors is an aesthetic failure.

Prerequisites

Run scripts/setup.sh to verify all dependencies. Requires: Python 3.10+, Manim Community Edition v0.20+ (pip install manim), LaTeX (texlive-full on Linux, mactex on macOS), and ffmpeg. Reference docs tested against Manim CE v0.20.1.

Modes

Mode Input Output Reference
Concept explainer Topic/concept Animated explanation with geometric intuition references/scene-planning.md
Equation derivation Math expressions Step-by-step animated proof references/equations.md
Algorithm visualization Algorithm description Step-by-step execution with data structures references/graphs-and-data.md
Data story Data/metrics Animated charts, comparisons, counters references/graphs-and-data.md
Architecture diagram System description Components building up with connections references/mobjects.md
Paper explainer Research paper Key findings and methods animated references/scene-planning.md
3D visualization 3D concept Rotating surfaces, parametric curves, spatial geometry references/camera-and-3d.md

Stack

Single Python script per project. No browser, no Node.js, no GPU required.

Layer Tool Purpose
Core Manim Community Edition Scene rendering, animation engine
Math LaTeX (texlive/MiKTeX) Equation rendering via MathTex
Video I/O ffmpeg Scene stitching, format conversion, audio muxing
TTS ElevenLabs / Qwen3-TTS (optional) Narration voiceover

Pipeline

PLAN --> CODE --> RENDER --> STITCH --> AUDIO (optional) --> REVIEW
  1. PLAN — Write plan.md with narrative arc, scene list, visual elements, color palette, voiceover script
  2. CODE — Write script.py with one class per scene, each independently renderable
  3. RENDERmanim -ql script.py Scene1 Scene2 ... for draft, -qh for production
  4. STITCH — ffmpeg concat of scene clips into final.mp4
  5. AUDIO (optional) — Add voiceover and/or background music via ffmpeg. See references/rendering.md
  6. REVIEW — Render preview stills, verify against plan, adjust

Project Structure

project-name/
  plan.md                # Narrative arc, scene breakdown
  script.py              # All scenes in one file
  concat.txt             # ffmpeg scene list
  final.mp4              # Stitched output
  media/                 # Auto-generated by Manim
    videos/script/480p15/

Creative Direction

Color Palettes

Palette Background Primary Secondary Accent Use case
Classic 3B1B #1C1C1C #58C4DD (BLUE) #83C167 (GREEN) #FFFF00 (YELLOW) General math/CS
Warm academic #2D2B55 #FF6B6B #FFD93D #6BCB77 Approachable
Neon tech #0A0A0A #00F5FF #FF00FF #39FF14 Systems, architecture
Monochrome #1A1A2E #EAEAEA #888888 #FFFFFF Minimalist

Animation Speed

Context run_time self.wait() after
Title/intro appear 1.5s 1.0s
Key equation reveal 2.0s 2.0s
Transform/morph 1.5s 1.5s
Supporting label 0.8s 0.5s
FadeOut cleanup 0.5s 0.3s
"Aha moment" reveal 2.5s 3.0s

Typography Scale

Role Font size Usage
Title 48 Scene titles, opening text
Heading 36 Section headers within a scene
Body 30 Explanatory text
Label 24 Annotations, axis labels
Caption 20 Subtitles, fine print

Fonts

Use monospace fonts for all text. Manim's Pango renderer produces broken kerning with proportional fonts at all sizes. See references/visual-design.md for full recommendations.

MONO = "Menlo"  # define once at top of file

Text("Fourier Series", font_size=48, font=MONO, weight=BOLD)  # titles
Text("n=1: sin(x)", font_size=20, font=MONO)                  # labels
MathTex(r"\nabla L")                                            # math (uses LaTeX)

Minimum font_size=18 for readability.

Per-Scene Variation

Never use identical config for all scenes. For each scene:

  • Different dominant color from the palette
  • Different layout — don't always center everything
  • Different animation entry — vary between Write, FadeIn, GrowFromCenter, Create
  • Different visual weight — some scenes dense, others sparse

Workflow

Step 1: Plan (plan.md)

Before any code, write plan.md. See references/scene-planning.md for the comprehensive template.

Step 2: Code (script.py)

One class per scene. Every scene is independently renderable.

from manim import *

BG = "#1C1C1C"
PRIMARY = "#58C4DD"
SECONDARY = "#83C167"
ACCENT = "#FFFF00"
MONO = "Menlo"

class Scene1_Introduction(Scene):
    def construct(self):
        self.camera.background_color = BG
        title = Text("Why Does This Work?", font_size=48, color=PRIMARY, weight=BOLD, font=MONO)
        self.add_subcaption("Why does this work?", duration=2)
        self.play(Write(title), run_time=1.5)
        self.wait(1.0)
        self.play(FadeOut(title), run_time=0.5)

Key patterns:

  • Subtitles on every animation: self.add_subcaption("text", duration=N) or subcaption="text" on self.play()
  • Shared color constants at file top for cross-scene consistency
  • self.camera.background_color set in every scene
  • Clean exits — FadeOut all mobjects at scene end: self.play(FadeOut(Group(*self.mobjects)))

Step 3: Render

manim -ql script.py Scene1_Introduction Scene2_CoreConcept  # draft
manim -qh script.py Scene1_Introduction Scene2_CoreConcept  # production

Step 4: Stitch

cat > concat.txt << 'EOF'
file 'media/videos/script/480p15/Scene1_Introduction.mp4'
file 'media/videos/script/480p15/Scene2_CoreConcept.mp4'
EOF
ffmpeg -y -f concat -safe 0 -i concat.txt -c copy final.mp4

Step 5: Review

manim -ql --format=png -s script.py Scene2_CoreConcept  # preview still

Critical Implementation Notes

Raw Strings for LaTeX

# WRONG: MathTex("\frac{1}{2}")
# RIGHT:
MathTex(r"\frac{1}{2}")

buff >= 0.5 for Edge Text

label.to_edge(DOWN, buff=0.5)  # never < 0.5

FadeOut Before Replacing Text

self.play(ReplacementTransform(note1, note2))  # not Write(note2) on top

Never Animate Non-Added Mobjects

self.play(Create(circle))  # must add first
self.play(circle.animate.set_color(RED))  # then animate

Performance Targets

Quality Resolution FPS Speed
-ql (draft) 854x480 15 5-15s/scene
-qm (medium) 1280x720 30 15-60s/scene
-qh (production) 1920x1080 60 30-120s/scene

Always iterate at -ql. Only render -qh for final output.

References

File Contents
references/animations.md Core animations, rate functions, composition, .animate syntax, timing patterns
references/mobjects.md Text, shapes, VGroup/Group, positioning, styling, custom mobjects
references/visual-design.md 12 design principles, opacity layering, layout templates, color palettes
references/equations.md LaTeX in Manim, TransformMatchingTex, derivation patterns
references/graphs-and-data.md Axes, plotting, BarChart, animated data, algorithm visualization
references/camera-and-3d.md MovingCameraScene, ThreeDScene, 3D surfaces, camera control
references/scene-planning.md Narrative arcs, layout templates, scene transitions, planning template
references/rendering.md CLI reference, quality presets, ffmpeg, voiceover workflow, GIF export
references/troubleshooting.md LaTeX errors, animation errors, common mistakes, debugging
references/animation-design-thinking.md When to animate vs show static, decomposition, pacing, narration sync
references/updaters-and-trackers.md ValueTracker, add_updater, always_redraw, time-based updaters, patterns
references/paper-explainer.md Turning research papers into animations — workflow, templates, domain patterns
references/decorations.md SurroundingRectangle, Brace, arrows, DashedLine, Angle, annotation lifecycle
references/production-quality.md Pre-code, pre-render, post-render checklists, spatial layout, color, tempo

Creative Divergence (use only when user requests experimental/creative/unique output)

If the user asks for creative, experimental, or unconventional explanatory approaches, select a strategy and reason through it BEFORE designing the animation.

  • SCAMPER — when the user wants a fresh take on a standard explanation
  • Assumption Reversal — when the user wants to challenge how something is typically taught

SCAMPER Transformation

Take a standard mathematical/technical visualization and transform it:

  • Substitute: replace the standard visual metaphor (number line → winding path, matrix → city grid)
  • Combine: merge two explanation approaches (algebraic + geometric simultaneously)
  • Reverse: derive backward — start from the result and deconstruct to axioms
  • Modify: exaggerate a parameter to show why it matters (10x the learning rate, 1000x the sample size)
  • Eliminate: remove all notation — explain purely through animation and spatial relationships

Assumption Reversal

  1. List what's "standard" about how this topic is visualized (left-to-right, 2D, discrete steps, formal notation)
  2. Pick the most fundamental assumption
  3. Reverse it (right-to-left derivation, 3D embedding of a 2D concept, continuous morphing instead of steps, zero notation)
  4. Explore what the reversal reveals that the standard approach hides