> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reactor.inc/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> To build and serve your own model, start at /deploy/development/quickstart and /deploy/development/overview. Deploying is the default path: reactor init scaffolds a workspace, reactor auth login authenticates, and reactor model deploy registers the model, publishes the release with the weights/ folder, and activates it on Reactor's GPUs, in one command from that workspace. Docker must be running, because the publish step builds the image locally. Bump model.version in reactor.yaml before redeploying a change, because a release that already has an image is reactivated as it is. Deployment access is granted per account, so contact team@reactor.inc if a deploy is refused. Every key in reactor.yaml is documented at /deploy/platform/reactor-yaml. Model code imports reactor_runtime; Python client code imports reactor_sdk. The runtime overview explains the model interface. Running the model on your own machine with reactor run is optional and needs a GPU you attach with --gpus; /deploy/development/local-testing covers that loop and pairs a complete brightness model with a Python client test in a separate brightness-test workspace.
> Reactor hosts multiple models, each with its own connect slug (modelName) and command/event schema. The video model catalog — slug, typed SDK package, and links to its schema — is at /model-api-reference/overview. Robotics policy documentation starts at /robotics/overview; X-WAM observations, actions, and client integration are under /robotics/xwam/; Cosmos3 Nano Policy DROID is under /robotics/cosmos/nano-policy-droid/. Some models expose one slug per experience (e.g. HappyOyster); always take the slug from the model's own pages, never guess it.
> Fastest path to a working app: `npx create-reactor-app my-app --model=<slug>` scaffolds a complete app with secure auth wired up. Typed TypeScript SDKs are published as @reactor-models/<model>; Python uses the base reactor-sdk package.
> Auth: exchange an API key (rk_...) for a JWT via POST https://api.reactor.inc/tokens from your server. Never put the API key in client-side code.
> Append .md to any docs URL for clean Markdown. Search these docs via the MCP server at https://docs.reactor.inc/mcp.

# XMAX X2.1 prompt guide

> Write editing instructions and combine them with reference images and drag control.

The source video supplies the scene and its motion. A reference image supplies appearance. The
prompt describes the change. Drag points supply positions that guide motion.

## Describe the edit

Name the target, the visible change, and the parts of the scene to preserve. Start with one edit.

**Too vague**

```text theme={"theme":{"light":"github-light","dark":"github-dark-high-contrast"}}
Make this magical and cinematic.
```

**More specific**

```text theme={"theme":{"light":"github-light","dark":"github-dark-high-contrast"}}
A small fireball appears in the person's open right palm and follows the hand.
Preserve the person's face, clothing, room, and camera.
```

These examples are starting points. Adjust them to the actual source and reference image.

## Replace a character or object

Upload a clear image of the desired subject with `set_reference_image`. Describe which source
subject to replace.

```text theme={"theme":{"light":"github-light","dark":"github-dark-high-contrast"}}
Replace the person on the left with the character from the reference image.
Preserve the person's pose and movement. Keep the other person and room unchanged.
```

When several subjects are visible, use position or appearance to identify one. A phrase such as "the
person in the blue jacket" is clearer than "them."

A reference replacement applies from the next block while the stream continues. Expect one short
pause as it applies. The edit moves to the new reference over the next few blocks. To change only
the editing instruction, send the complete replacement prompt with `set_prompt`.

## Replace clothing

Use the reference image for the desired outfit. Name the garment to change and the identity features
to preserve.

```text theme={"theme":{"light":"github-light","dark":"github-dark-high-contrast"}}
Replace only the central person's jacket with the jacket from the reference image.
The jacket follows the person's movement. Preserve the face, hair, trousers, and background.
```

## Guide motion with drag points

A still image can serve as the source when your app publishes it as repeated video frames. For
drag-only animation, set `prompt` to `""`. The empty string starts generation without a text
instruction.

For a guided action, name the subject and its movement:

```text theme={"theme":{"light":"github-light","dark":"github-dark-high-contrast"}}
The red paper glider follows the drag trajectory and tilts as it turns.
Keep the city and camera fixed.
```

Start a drag on the intended subject. Use a smooth path and hold the endpoint briefly. Send the
positions from the last four source-frame ticks, oldest first, with
[`set_pointers`](https://docs.reactor.inc/model-api-reference/xmax-x2-1/schema#set_pointers).

> [!NOTE]
>
> Drag points guide generated motion. They do not guarantee object selection or exact pixel
> placement. Send four empty lists to end a drag.

## Change prompts during a run

A new prompt replaces the previous instruction from the next generated block. Restate the whole
desired edit.

```text theme={"theme":{"light":"github-light","dark":"github-dark-high-contrast"}}
The paper glider rests on the table. Keep the scene still.
```

If a prompt describes continuous motion, releasing a drag does not remove that instruction. For
precise application controls, update both the prompt and the drag window when the user releases the
pointer.

## See also

* [Overview](https://docs.reactor.inc/model-api-reference/xmax-x2-1/overview.md)
* [Command and message schema](https://docs.reactor.inc/model-api-reference/xmax-x2-1/schema.md)
* [Tutorial](https://docs.reactor.inc/model-api-reference/xmax-x2-1/tutorial.md)
* [Commands and messages](https://docs.reactor.inc/concepts/commands-and-messages.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.