Motion SDK

Installation

Install the CLI for headless renders, the Rust crates, and the browser player.

Motion SDK is pre-alpha. Everything installs from the repository for now.

CLI

The motion-sdk CLI validates scenes and renders them headless. It needs Rust (install it with rustup) and a GPU. Any Vulkan, Metal or DX12 GPU works, and so does a software driver like Mesa lavapipe on a server.

git clone https://github.com/brainfish-ai/motion && cd motion
cargo install --locked --path crates/motion-sdk-cli
motion-sdk --version

On Debian or Ubuntu without a GPU, install lavapipe and pick Vulkan:

sudo apt-get install -y mesa-vulkan-drivers
export WGPU_BACKEND=vulkan

MP4 export compiles OpenH264 from source, so the build needs a C++ compiler, plus nasm (optional) for its assembly. See Export for the licensing notes.

Rust Crates

[dependencies]
motion-sdk-spec = { git = "https://github.com/brainfish-ai/motion" }
motion-sdk-render = { git = "https://github.com/brainfish-ai/motion" }
motion-sdk-export = { git = "https://github.com/brainfish-ai/motion" }

motion-sdk-spec alone gives you the types, the JSON Schema, validation and patch streaming, with no GPU dependency.

Browser

@motion-sdk/core isn't on npm yet. Build it from the repo (Node 24 and the wasm32-unknown-unknown Rust target):

npm install
npm run build:wasm   # wasm-bindgen + wasm-opt; fetches pinned tools on first run
npm run dev          # playground at http://localhost:5173
import { createPlayer } from "@motion-sdk/core"

const player = await createPlayer(canvas, scene)

See the Player API.

TypeScript

@motion-sdk/scene has the scene types (generated from the Rust spec) and typed helpers, so scenes written in TypeScript are checked by the compiler. It's a workspace package with no runtime dependencies.

import { defineScene, mesh } from "@motion-sdk/scene"

export default defineScene({ nodes: { orb: { mesh: mesh({ sphere: {} }, { material: "preset:chrome" }) } } })

See TypeScript SDK.

Agent Skills

npx skills@latest add brainfish-ai/motion

This installs every skill in skills/. See Skills.