Matrix-Game-3.5 is a memory-enhanced interactive world model focused on 720p long-horizon, camera-controllable video generation, supporting both first-person and third-person modes. Its core goal is to achieve scene consistency over long time spans and precise camera control in real-time streaming interactive scenarios.
In terms of main capabilities, the project introduces three key technologies. First, Patch Memory and Warped PRoPE form a parameter-free long-term geometric memory framework: Patch Memory lifts past observations into 3D memory, enabling cross-view scene recall through geometric alignment and visibility-aware retrieval; Warped PRoPE folds camera projection matrices into spatiotemporal RoPE, jointly modeling temporal relations and view geometry, thereby providing long-horizon consistency and precise camera control without modifying the backbone network. Second, static-dynamic disentangled world representation: static scenes maintain long-term geometric memory through Patch Memory, while dynamic subjects maintain identity and appearance through lightweight multi-view reference tokens; combined with motion-aware filtering and leak-free subject training, it unifies geometric consistency and subject consistency, alleviating ghosting and identity drift in long-horizon generation. Third, long-horizon real-time distillation: from a bidirectional diffusion model to a few-step causal generator, using Flow Matching in the perceptual feature space to jointly learn autoregressive denoising and few-step generation as a strong initialization, then progressively distilling CFG, camera control, and memory conditioning through curriculum-style self-rollout DMD, achieving minute-level, few-step, real-time interactive generation.
In terms of models, two pretrained 5B base (bidirectional) models are currently provided, both built on Wan2.2-TI2V-5B, available in the Matrix-Game-3.5-Base Hugging Face repository. The standard three-step first-person causal checkpoint is located at Matrix-Game-3.5-Distilled.
In terms of usage, base model inference uses infer.py, requiring an anchor image, camera trajectory, and text prompt; third-person inference optionally accepts a protagonist reference crop. Results are output to the outputs/{first_person,third_person}/<timestamp>/ directory, containing result.mp4 (generated video), memory_visualization.mp4 (diagnostic two-row panel: generation | mosaic memory), and subject_ref_preview.jpg (third-person mainangular reference canvas). Distilled causal inference uses infer_distilled.py, with the standard three-step first-person causal checkpoint, following the same explicit image/camera/prompt interface as the base model, without requiring a training run, validation artifacts, manifest, or accompanying metadata. For the detailed input contract and the full command-line interface, see DISTILLED_INFERENCE.md; for a single-block smoke test, configs/infer_distilled.yaml can be used. The camera format (--camera) is an .npz file containing extrinsics_c2w (N,4,4 camera-to-world matrices, with metric translation) and intrinsics (N,4 [fx,fy,cx,cy], or (4,)/(3,3)/(N,3,3), in units of anchor image pixels). Trajectories shorter than 1 + 84 × num_blocks poses are padded by holding the last pose.
Environment requirements: one NVIDIA GPU with at least 40 GB of VRAM is required (A/H series have been tested); 704×1280 generation peaks at about 40 GB. Linux operating system, at least 64 GB of memory. The repository contains several third-party components: a DiffSynth-based model/pipeline library (diffsynth/), a frustum reprojection engine for Mosaic Memory (frustum/), and the Depth-Anything-3 source code (third_party/depth-anything-3/). All Python dependencies are pinned in requirements.txt, and no additional manual build is required (no need to compile flash-attention). The bundled third-party source code is already included in the repository and imported directly from source, with no additional installation or compilation step required.
Checkpoint placement: choose one of the base or distilled Matrix-Game checkpoints. Wan2.2-TI2V-5B and Depth-Anything-3 are shared dependencies for both inference paths. Place or symlink the downloaded files under checkpoints/. Custom locations can be specified with the --wan-dir, --tokenizer-dir, and --da3-dir arguments; base inference accepts --ckpt, and distilled inference requires an explicit --checkpoint. Shared dependency paths can also be set via the WAN22_TI2V_5B_DIR, UMT5_TOKENIZER_DIR, and DA3_MODEL_PATH environment variables.
Applicable scenarios include interactive video generation research requiring long-horizon consistency and camera controllability, such as first-person or third-person perspective virtual world exploration, real-time streaming content generation, and so on. In terms of limitations, a relatively high hardware configuration is required (an NVIDIA GPU with at least 40 GB of VRAM, a Linux system with at least 64 GB of memory), and the model scale currently provided is 5B. The project is licensed under the Apache License 2.0, and the bundled assets under samples/first_person/ come from SANA-WM-Bench (CC BY 4.0).