6 min read

Remotion with Gemini CLI: make a product video from the terminal

By Founder & Research Lead, Kalaris Labs · Updated

Gemini CLI is an agent in your terminal that reads files, writes code and runs commands. Remotion needs nothing more, so the CLI can take a video from an empty folder to an MP4.

The missing piece is a reference. Below, a library of launch videos measured frame by frame goes into settings.json, and Gemini works from one of them.

Want only the install and a few prompts? The Gemini CLI launch video page has them on one screen.

Why Gemini CLI suits video work

  • A large context window holds a whole storyboard and shot list at once.
  • GEMINI.md keeps your brand and project rules for every session.
  • The /mcp command shows connected servers and their tools at a glance.
  • It runs everything in your terminal, so renders land in your project.

Start a Remotion project

Remotion turns React components into video: every frame is a render of your component at that frame number, so Gemini CLI edits a video the way it edits any other code. You need Node.js. Ask Gemini CLI to scaffold the project, or run it yourself:

npx create-video@latest

Give Gemini CLI a reference to work from

A blank prompt gets a generic video. A real launch video measured frame by frame gets one with a rhythm: when each shot starts, how it enters and how much moves. The library at https://kuchi.kalarislabs.com/mcp is a free MCP server with no sign-in and no API key. Add it to Gemini CLI:

1. Add this to ~/.gemini/settings.json, then restart Gemini CLI. No sign-in is needed.

{
  "mcpServers": {
    "kuchi": {
      "httpUrl": "https://kuchi.kalarislabs.com/mcp"
    }
  }
}

2. Optional: install the Kuchi skill so the workflow is loaded from the start.

npx skills add kalarislabs/kuchi

Then paste the setup prompt, so the agent knows how to use the library:

Setup prompt
Connect the Kuchi MCP server at https://kuchi.kalarislabs.com/mcp (Streamable HTTP, no sign-in) and confirm it works by listing its tools.

Kuchi is a library of real product-launch videos to use as inspiration templates. When I want a launch video, read kuchi_get_workflow and follow it: get a short list with kuchi_suggest_templates and show me each one's poster and link so I can choose, in chat or by picking a video on kuchi.kalarislabs.com and pasting its link. Once I pick one, study it with kuchi_get_breakdown, look at its storyboard and note what each shot shows, then call kuchi_plan_remake with my product details and your shot analysis, and ask me for my logo, screenshots and anything else it lists as missing. Build to the blueprint's frames. Before you deliver, run kuchi_check_remake and compare your frames with the reference. Copy only the reference's motion and taste; everything on screen comes from my product.

The prompts, in order

  1. Suggest launch video templates for an AI writing tool. Show me each poster and link.
  2. Study the one I picked: list every shot with its start and end frame and what it shows.
  3. Plan my remake at 30 seconds with the assets in ./brand.
  4. Scaffold Remotion and build the shots on those frames.
  5. Check the remake, compare stills with the reference, fix, render.

Writing one shot in Remotion

A Remotion video is a React component rendered once per frame. Inside a shot, useCurrentFrame() returns the frame number counted from the start of that shot's <Sequence>, and useVideoConfig() gives the fps and size. Everything that moves is a function of that number, which is why Gemini CLI can match a reference to the frame: an entrance that takes 12 frames in the reference takes exactly 12 frames in yours.

The blueprint says how each shot enters. Each entrance has a direct translation:

Blueprint `enters`In Remotion
cutNo entrance animation: the shot is fully on screen at its first frame.
transitionAnimate over the first frames: interpolate(frame, [0, 12], [0, 1], { extrapolateRight: 'clamp' }) for opacity, or a spring() for scale or position.
holdSame scene as the shot before: keep the layout and resume the motion where it stopped.
blank_black, blank_whitePut a frame or two of solid black or white between the shots, as the reference does.

Here is a product-screen shot that enters with a short transition, written the way Gemini CLI should write every shot: assets from public/ through staticFile(), timing from the frame number, nothing random.

src/shots/Shot3.tsx
import { AbsoluteFill, Img, interpolate, spring, staticFile, useCurrentFrame, useVideoConfig } from 'remotion';

// Blueprint shot 3: kind ui_screen, enters "transition", motion "medium".
export const Shot3 = () => {
  const frame = useCurrentFrame();
  const { fps } = useVideoConfig();
  const opacity = interpolate(frame, [0, 12], [0, 1], { extrapolateRight: 'clamp' });
  const rise = spring({ frame, fps, config: { damping: 200 } });

  return (
    <AbsoluteFill style={{ background: '#0b0b0f', alignItems: 'center', justifyContent: 'center' }}>
      <Img
        src={staticFile('screens/dashboard.png')}
        style={{ width: '78%', borderRadius: 16, opacity, transform: `translateY(${(1 - rise) * 40}px)` }}
      />
    </AbsoluteFill>
  );
};

For a screen recording use <OffthreadVideo src={staticFile('screens/demo.mp4')} /> instead of <Img>. Never use Math.random() or the clock inside a shot: Remotion renders frames in parallel and out of order, so anything not derived from the frame number flickers. Use Remotion's random(seed) when you need variation.

Preview, check and render

Open the Remotion Studio to scrub through the video while Gemini CLI works, render single frames to compare with the reference at the times the check gives, then render the file. Launch stands for your composition id.

npx remotion studio
npx remotion still Launch out/frame-90.png --frame=90
npx remotion render Launch out/launch.mp4

What trips people up in Gemini CLI

  • Using "url" instead of "httpUrl" in settings.json. Gemini CLI reads "httpUrl" for Streamable HTTP servers.
  • Not restarting after editing settings.json. The CLI loads servers at start.
  • Letting it invent a logo. If an asset is missing, ask for a marked placeholder and add yours later.

Questions

Can Gemini CLI make videos?

It can write and render a Remotion video in your project. The video is code you keep and can re-render.

Where is the Gemini CLI MCP config?

In ~/.gemini/settings.json under mcpServers. Use httpUrl for a remote Streamable HTTP server.

How do I see if the server loaded?

Run /mcp inside Gemini CLI. It lists each server and its tools.