Reactor makes it easy to build applications with real-time world models. In just a few lines of code, you connect to a model, receive live video, and send commands to steer what it generates while it runs, enabling entirely new types of applications that were not possible before.
<1sRound-trip latency
ZeroInfrastructure to manage
1,000sof GPUs, on demand
Connect to Reactor’s SDK and immediately start steering real-time video:
import { Reactor } from "@reactor-team/js-sdk";const video = document.querySelector("video")!;const reactor = new Reactor({ modelName: "reactor/helios" });// Render frames as soon as they arrive.reactor.on("trackReceived", (name, track) => { if (name !== "main_video") return; video.srcObject = new MediaStream([track]); void video.play();});// Once the session is ready, set a prompt and start generating.reactor.on("statusChanged", async (status) => { if (status !== "ready") return; await reactor.sendCommand("set_prompt", { prompt: "A serene mountain landscape at sunrise" }); await reactor.sendCommand("start", {});});const jwt = await getToken(); // token minted on your serverawait reactor.connect(jwt);
import { ReactorProvider, ReactorView, useReactor } from "@reactor-team/js-sdk";import { useEffect } from "react";function Studio() { const { status, sendCommand } = useReactor((s) => ({ status: s.status, sendCommand: s.sendCommand, })); // Once the session is ready, set a prompt and start generating. useEffect(() => { if (status !== "ready") return; sendCommand("set_prompt", { prompt: "A serene mountain landscape at sunrise" }); sendCommand("start", {}); }, [status]); return <ReactorView className="w-full aspect-video" />;}export default function App({ token }: { token: string }) { // token is minted on your server return ( <ReactorProvider modelName="reactor/helios" jwtToken={token} connectOptions={{ autoConnect: true }}> <Studio /> </ReactorProvider> );}
import asyncioimport osfrom reactor_sdk import Reactorasync def main(): async with Reactor(model_name="reactor/helios", api_key=os.environ["REACTOR_API_KEY"]) as reactor: await reactor.connect() # Receive decoded frames as NumPy arrays. output = reactor.tracks.with_direction("recvonly").with_kind("video").one() @output.on_frame def on_frame(frame): ... # Set a prompt and start generating. await reactor.send_command("set_prompt", {"prompt": "A serene mountain landscape at sunrise"}) await reactor.send_command("start", {})asyncio.run(main())
Or scaffold a complete, runnable app — SDK installed and secure auth already wired up — in one command: