MOSS-VL

MOSS-VL: A Multimodal Foundation for Video Understanding

MOSS-VL is the core multimodal model series in the OpenMOSS ecosystem, dedicated to pushing the frontier of visual understanding. To tackle the challenges inherent to video understanding, our technical roadmap pursues a systematic scaling strategy along three key dimensions.

Data Scaling

Building large-scale, high-quality multimodal datasets to drive strong generalization.

Parameter Scaling

Growing model capacity to precisely capture complex vision–language associations.

Context Scaling

Extending the temporal horizon to enable deep reasoning over long-form videos.

01 Architecture

Decoupling Visual Encoding from Cognitive Reasoning

MOSS-VL adopts a cross-attention-based architecture that decouples visual encoding from cognitive reasoning. This architecture provides a unified backbone for offline image and video understanding. With native support for interleaved modalities, the model handles complex image and video sequences in a unified pipeline, free of heavyweight preprocessing. Continuous-stream interaction is provided separately by MOSS-VL-Realtime.

MOSS-VL overall architecture
Figure 1: Overall architecture of MOSS-VL.

02 Absolute Timestamps

Anchoring Reasoning to a Precise Time Reference

To ensure the model precisely perceives the pace and duration of events, MOSS-VL injects an absolute timestamp into every sampled frame, anchoring the reasoning process to a precise temporal reference.

Input Representation

Timestamped sequence input illustration
Figure 2: Illustration of video sequence input with timestamps.

Precise time markers are interleaved throughout each video. Every timestamp is wrapped in dedicated special tokens (<|time_start|><|time_end|>), explicitly anchoring the temporal position of every visual frame:

<|im_start|><|vision_start|>
<|time_start|>0.0 seconds<|time_end|><|image_pad|>
<|time_start|>1.2 seconds<|time_end|><|image_pad|>
<|time_start|>2.3 seconds<|time_end|><|image_pad|>
...
<|vision_end|>The video shows a dynamic scene with continuous motion...<|im_end|>
Design Rationale

03 Cross-Attention Rotary Position Embedding

XRoPE: A Unified 3D Spatio-Temporal Coordinate Space

MOSS-VL employs a Cross-attention Rotary Position Embedding (XRoPE) tailored to its cross-attention-based vision–language architecture. This mechanism maps text tokens and video patches into a unified 3D coordinate space defined by time (t), height (h), and width (w).

MOSS-VL XRoPE architecture illustration
Figure 3: The MOSS-VL architecture equipped with cross-attention RoPE (XRoPE).

To optimize cross-modal alignment, XRoPE is injected into the vision-side Keys (K) to strengthen positional awareness while leaving the Values (V) untouched, preserving feature fidelity. Meanwhile, XRoPE is applied to the text-side Queries (Q), allowing the model to retrieve information from any spatio-temporal region through direct coordinate alignment.

Key Benefits

04 Demos

Capabilities at a Glance

Below are inference examples of MOSS-VL on real video inputs. For more examples, visit our interactive demo page, or try it online in the HuggingFace Space.


05 Training

Building Multimodal Capability Step by Step

MOSS-VL follows a multi-stage training approach that builds multimodal capability progressively.

MOSS-VL overall training data distribution
Figure 4: Overall training data distribution of MOSS-VL.

Pre-Training (PT)

MOSS-VL builds multimodal capability from scratch through a systematic four-stage pre-training pipeline:

STAGE 1
Vision–Language Alignment

Establishes the initial bridge between visual features and the language space. Training on large-scale image–text pairs teaches the model to associate visual concepts with their textual descriptions, while cultivating basic OCR ability to read text in images.

STAGE 2
Large-Scale Multimodal Pre-Training

Expands the model's exposure to a massive, diverse multimodal corpus, broadening its grasp of world knowledge and complex scenes, and laying a solid foundation for general intelligence and high-resolution perception. Short video clips are also introduced at this stage to seed video understanding.

STAGE 3
High-Quality Multimodal Pre-Training

Comprehensively raises model quality by training on abundant high-quality perception, understanding, and reasoning data. This stage combines fine-grained image perception, complex multi-image understanding, and high-fidelity video reasoning, strengthening the model's ability to capture intricate visual details and temporal relations.

STAGE 4
Annealing & Long-Context Extrapolation

Extends the model's horizon to long-video understanding, while a carefully designed annealing strategy trains on curated top-tier multimodal data to push final performance to its peak.

Supervised Fine-Tuning (SFT)

On top of the pre-trained model, MOSS-VL is further refined through supervised fine-tuning (SFT) to align with human intent and fully unlock its interactive and instruction-following capabilities.

MOSS-VL SFT data composition
Figure 5: SFT data composition of MOSS-VL.
RLHF

06 Evaluation

A Balanced and Comprehensive Capability Profile

We evaluated MOSS-VL-Instruct-0708 for offline multimodal understanding across perception, video understanding, grounding, document / OCR, and reasoning. The table below reports the 0708 release alongside the previous MOSS-VL-0408 checkpoint and open-source baselines.

Overall Performance

Scores are reported per benchmark rather than collapsed into a single aggregate. Bold red marks the best reported score in each row, and underlining marks the second best.

Swipe horizontally inside the chart to view the full benchmark.

Figure 6: Offline benchmark comparison for MOSS-VL-0708, MOSS-VL-0408, and open-source baselines.

Highlights

Broad Video Evaluation
The 0708 release is evaluated across short- and long-video understanding, temporal reasoning, action recognition, and event localization benchmarks, including VideoMME, MLVU, LongVideoBench, EgoSchema, VSI-Bench, and TimeLens.
Multimodal Perception Coverage
The perception suite covers general image–text understanding, fine-grained recognition, counting, and spatial understanding through benchmarks such as MMBench, MMStar, RealWorldQA, BLINK, CountBench, CVBench, and V*.
Visual Reasoning Coverage
The reasoning section reports results on VLMsAreBlind, VisuLogic, ERQA, and EmbSpatial, while the grounding section includes RefCOCO-REC and Ref-Adv.
Document and OCR Coverage
The release is also evaluated on document and OCR tasks including DocVQA, ChartQA, InfoVQA, OCRBench, OCRBench-v2, and OmniDocBench.

07 Quick Start

Environment Setup & Inference

Environment Setup

conda create -n moss_vl python=3.12 pip -y
conda activate moss_vl
pip install -i https://pypi.org/simple --no-build-isolation -r requirements.txt

Model Inference

For more ready-to-run inference examples and demo assets, see inference/README.md. Inference supports full-modality offline queries, including text-only, single-image, multi-image, single-video, multi-video, and interleaved image–video inputs via the messages format.

Single-query inference with offline_generate
import queue
import threading
import torch
from transformers import AutoModelForCausalLM, AutoProcessor

checkpoint = "/path/to/dummy-checkpoint"

processor = AutoProcessor.from_pretrained(
    checkpoint,
    trust_remote_code=True,
    frame_extract_num_threads=1,
)
model = AutoModelForCausalLM.from_pretrained(
    checkpoint,
    trust_remote_code=True,
    device_map="auto",
    torch_dtype=torch.bfloat16,
    attn_implementation="flash_attention_2",
)

query = {
    "messages": [
        {
            "role": "user",
            "content": [
                {"type": "image", "image": "path/to/example.jpg"},
                {"type": "text", "text": "Describe this image."},
            ],
        }
    ],
    "media_kwargs": {},
    "generate_kwargs": {
        "max_new_tokens": 256,
        "do_sample": False,
        "vision_chunked_length": 64,
    },
}

input_queue = queue.Queue()
output_queue = queue.Queue()
worker = threading.Thread(
    target=model.offline_generate,
    args=(processor, input_queue, output_queue),
    kwargs={"vision_chunked_length": 64},
    daemon=True,
)
worker.start()

input_queue.put(query)
text_chunks = []
while True:
    item = output_queue.get()
    if item in {"<|round_start|>"}:
        continue
    if item == "<|round_end|>":
        break
    text_chunks.append(item)

print("".join(text_chunks))

input_queue.put({"stop_offline_generate": True})
worker.join()

For simple batch offline inference, you can also use offline_batch_generate directly:

Batch inference with offline_batch_generate
import torch
from transformers import AutoModelForCausalLM, AutoProcessor

checkpoint = "/path/to/dummy-checkpoint"

processor = AutoProcessor.from_pretrained(
    checkpoint,
    trust_remote_code=True,
    frame_extract_num_threads=1,
)
model = AutoModelForCausalLM.from_pretrained(
    checkpoint,
    trust_remote_code=True,
    device_map="auto",
    torch_dtype=torch.bfloat16,
    attn_implementation="flash_attention_2",
)

queries = [
    {
        "messages": [
            {
                "role": "user",
                "content": [{"type": "text", "text": "Describe sample A."}],
            }
        ],
        "media_kwargs": {},
        "generate_kwargs": {"max_new_tokens": 256, "do_sample": False},
    },
    {
        "messages": [
            {
                "role": "user",
                "content": [{"type": "text", "text": "Describe sample B."}],
            }
        ],
        "media_kwargs": {},
        "generate_kwargs": {"max_new_tokens": 256, "do_sample": False},
    },
]

with torch.no_grad():
    result = model.offline_batch_generate(
        processor,
        queries,
        vision_chunked_length=64,
    )

texts = [item["text"] for item in result["results"]]
print(texts)

Fine-Tuning

We provide a lightweight SFT fine-tuning framework built on HuggingFace transformers.Trainer, supporting both full-parameter training and LoRA, with independent control over whether the vision encoder, language model, and LM head participate in training.

# Full-parameter SFT (vision encoder frozen by default)
bash finetune/scripts/run_sft.sh

# LoRA SFT
pip install -i https://pypi.org/simple peft
bash finetune/scripts/run_sft_lora.sh

Training data uses a JSON structure compatible with the inference query format, requiring only an extra response field:

[
  {
    "prompt": "Describe this image.",
    "response": "A beautiful landscape painting surrounded by mountains.",
    "images": ["path/to/image.jpg"],
    "videos": []
  }
]

Multi-turn dialogue formats are also supported; see finetune/README.md for full documentation.


08 Download & Deployment

Open Weights

Model🤗 Download🤖 ModelScope
MOSS-VL-Base-0408 HuggingFace ModelScope
MOSS-VL-Instruct-0408 HuggingFace ModelScope
MOSS-VL-Base-0708 HuggingFace ModelScope
MOSS-VL-Instruct-0708 HuggingFace ModelScope
MOSS-VL-Realtime HuggingFace ModelScope

SGLang

SGLang officially supports MOSS-VL. For SGLang-based deployment and serving instructions, see sglang/README.md.

GitHub Repository
Source code, inference and fine-tuning scripts, and full documentation.
Interactive Demo
Experience MOSS-VL's image and video understanding online.
HuggingFace Space
Try it in your browser — no local deployment required.

09 Roadmap

Achieved & Upcoming

✅ Milestones Achieved

  • Core architecture: Implemented Cross-attention Rotary Position Embedding (XRoPE).
  • High-performance infrastructure: Integrated Megatron-LM and CUDA Flash Attention 3.
  • Model release: Open-sourced the MOSS-VL-Base and MOSS-VL-Instruct models.
  • Model inference: Released inference code supporting image and video understanding.
  • Real-time capability: The dedicated real-time video understanding model MOSS-VL-Realtime has been released.

🚀 Coming Soon

  • Training engine: The complete training code for MOSS-VL.
  • RL post-training: RLHF for the MOSS-VL series.
  • Technical report: A detailed technical report with experimental analysis.
Next in the Series
  • The second post in this series, MOSS-VL-Realtime, has been released — taking video understanding from "watching recordings" to "watching live".

10 News

Project Updates


Acknowledgements & Citation

Acknowledgements

We sincerely thank NVIDIA for the Megatron-LM framework and the Qwen team for the powerful Qwen series of language models; these outstanding open-source works laid a solid foundation for our training infrastructure and core language model. We are also deeply grateful to the SGLang team for the high-performance SGLang inference and serving framework, which provides vital support for the efficient deployment of MOSS-VL.

Citation

@misc{moss_vl_2026,
  title         = {{MOSS-VL Technical Report}},
  author        = {OpenMOSS Team},
  year          = {2026},
  howpublished  = {\url{https://github.com/OpenMOSS/MOSS-VL}},
  note          = {GitHub repository}
}