> ## 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 catalog of every model — slug, typed SDK package, and links to its schema — is at /model-api-reference/overview. 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.

# Vidu S2-Editing prompt guide

> Choose a reference image for each edit type and switch looks during a live edit.

The Reactor model takes no text prompt. Give it one reference image and an `editing_type` that says
how to use the image. You can change either one while the edit runs.

## Pick an edit type

First decide what you want to change. Then choose an image that shows that look, garment, character,
or place.

| `editing_type` | What changes | Example reference |
| - | - | - |
| `style_transfer` | The look of the scene. | A clay animation portrait. |
| `virtual_tryon` | An item the person wears. | A sequined jacket. |
| `subject_replacement` | The person's appearance. | A marble statue. |
| `background_replacement` | The scene behind them. | A Mars landscape. |

`style_transfer` is the default if you omit `editing_type`.

## Choose the reference image

### Style transfer

Use an image whose colors and rendering style you want to apply. The JS SDK example includes clay
animation, stained glass, woodblock print, and blueprint images.

### Virtual try-on

Use an image that clearly shows the item you want to try on. The JS SDK example includes a sequined
jacket, dinosaur costume, sunflower hat, and rainbow wig. Keep the matching part of your body in the
camera frame.

### Subject replacement

Use an image of the person or character whose appearance you want. The JS SDK example includes a
marble statue, an astronaut, and a garden gnome. Keep the person on camera in frame.

### Background replacement

Use an image of the place you want behind the person on camera. The JS SDK example includes a Mars
landscape, a TV news studio, and a Tokyo alley.

## Frame your camera

Keep the part of the person you want to edit in the camera frame.

* Light the person evenly from the front.
* Keep the camera track flowing. A stalled camera stalls the edit.

## Upload or URL

Pass the image as an upload with `reference_image`, or as a public http(s) URL with
`reference_image_url`. Both take PNG, JPG, or WebP, under 10 MB.

The model does not apply an uploaded image's EXIF orientation. Rotate a phone photo before you
upload it. For a URL, the model fetches the image when the edit starts or you send a switch.

## Switch mid-edit

`switch_reference` changes the image, the edit type, or both, while the edit runs. What you omit
stays as it is:

| To do this | Send |
| - | - |
| Try a different outfit | `{ reference_image_url: jacketUrl, editing_type: "virtual_tryon" }` |
| Read the same image a different way | `{ editing_type: "style_transfer" }` |
| Change both at once | `{ reference_image_url: beachUrl, editing_type: "background_replacement" }` |

The picture changes after the switch is sent. If the switch fails, the previous look stays. A
`command_error` for `switch_reference` can arrive after the reply. Send each switch once. Do not
resend it when nothing seems to change.

## Handle content refusals

Vidu S2-Editing is moderated. An edit stopped for its content ends with
`end_reason: "content_policy"`, and `last_error.reason` says why. Show that reason to the user
rather than retrying with the same image.

## See also

* [Schema](/model-api-reference/vidu-s2-editing/schema): every command, parameter, and message.
* [Tutorial](/model-api-reference/vidu-s2-editing/tutorial): build a browser app from start to
  finish.
* [Content moderation](/resources/content-moderation): how Reactor moderates the models it serves.
