Skip to main content
XMAX X2.1 edits video as you stream it. Publish a webcam, a video clip, or a still image as video. Use a prompt to describe the edit, a reference image to supply appearance, and drag points to guide motion. This reference has four pages: this overview, the schema, the prompt guide, and the tutorial. The base Reactor client connects with reactor/xmax-x2-1 and sends named commands. The typed SDK, @reactor-models/xmax-x2-1, provides the same commands as named methods and React hooks. See Typed Model SDKs.

At a glance

Use the full model name when you open a session. The CLI and pricing catalog use the short slug xmax-x2-1. See Pricing & Billing.

Key features

Edit a live source

Publish video on source and receive the edited video on main_video. Change the prompt during a run.

Supply a reference

Upload a character or object image for a swap or insertion. Replace it during a run to change the reference in the stream.

Guide motion

Send drag positions for each frame in a four-frame window. Use an empty prompt for motion without a text instruction.

Quick start

The example template is the planned destination for source selection and editing controls.
This browser example uses the base SDK. Provide a <video id="output" autoplay playsinline muted> element and a server token route as described in Authentication.
For named methods and React controls, use XmaxX21Model or useXmaxX21 from the typed SDK.

How it works

  1. Connect to reactor/xmax-x2-1.
  2. Publish a source video track.
  3. Set a prompt. Generation starts when a prompt is set and source frames arrive. The empty string is valid.
  4. Read the output dimensions from generation_started or state_update.
  5. Change the prompt, reference image, or drag window as needed.
  6. Call reset to stop generation and clear the prompt, reference image, and drag points.
There is no start command. A null prompt means no prompt was set. An empty string means generation can run without text guidance. Reset keeps the session’s output dimensions.