Skip to content

Add composable world-model pipelines and Cosmos3 export - #466

Draft
xiaoyu-work wants to merge 7 commits into
mainfrom
xiaoyu-work/cosmos3-world-model
Draft

Add composable world-model pipelines and Cosmos3 export#466
xiaoyu-work wants to merge 7 commits into
mainfrom
xiaoyu-work/cosmos3-world-model

Conversation

@xiaoyu-work

Copy link
Copy Markdown
Contributor

Introduce executable pipeline schema 1.1 with typed generated-input programs, recurrent state lifecycle, scheduler and autoregressive controls, parameterized transforms, runtime assets, and dtype/EP hints.

Implement complete Cosmos3 Omni and Edge exports with the shared MoT generator, Wan video VAE, optional AVAE audio tokenizer, domain-aware action heads, real checkpoint weight routing, CLI support, documentation, and numerical tests.

Introduce executable pipeline schema 1.1 with typed generated-input programs, recurrent state lifecycle, scheduler and autoregressive controls, parameterized transforms, runtime assets, and dtype/EP hints.

Implement complete Cosmos3 Omni and Edge exports with the shared MoT generator, Wan video VAE, optional AVAE audio tokenizer, domain-aware action heads, real checkpoint weight routing, CLI support, documentation, and numerical tests.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 997ab62c-69cb-4802-a5c6-fddd51bfd583
Signed-off-by: Xiaoyu Zhang <xiaoyuzhang@microsoft.com>
@CLAassistant

CLAassistant commented Aug 8, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.


import onnx_ir as ir

from mobius._configs.per_model import _cosmos3_edge_vision # noqa: F401
from mobius.tasks._cosmos3_audio import select_cosmos3_audio_task
from mobius.tasks._wan_vae import WanVAETask

logger = logging.getLogger(__name__)
Focus the world-model guides on export commands, package contents, supported checkpoints, runtime usage, and practical options. Remove internal architecture and manifest implementation details from the user guide.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 997ab62c-69cb-4802-a5c6-fddd51bfd583
Signed-off-by: Xiaoyu Zhang <xiaoyuzhang@microsoft.com>
@github-actions

github-actions Bot commented Aug 8, 2026

Copy link
Copy Markdown

Performance Comparison

Comparing 78437cdaefd430

Model Metric Baseline Current Delta
bert (feature-extraction) model_size_bytes 359 KB 359 KB +0.0%
bert (feature-extraction) num_nodes 60 60 +0.0%
falcon model_size_bytes 364 KB 364 KB +0.0%
falcon num_nodes 68 68 +0.0%
gemma2 model_size_bytes 428 KB 428 KB +0.0%
gemma2 num_nodes 107 107 +0.0%
gpt2 model_size_bytes 388 KB 388 KB +0.0%
gpt2 num_nodes 54 54 +0.0%
llama model_size_bytes 425 KB 425 KB +0.0%
llama num_nodes 62 62 +0.0%
llama (static-cache) model_size_bytes 425 KB 425 KB +0.0%
llama (static-cache) num_nodes 58 58 +0.0%
mamba (ssm-text-generation) model_size_bytes 296 KB 296 KB +0.0%
mamba (ssm-text-generation) num_nodes 98 98 +0.0%
phi3 model_size_bytes 421 KB 421 KB +0.0%
phi3 num_nodes 60 60 +0.0%
phi3 (static-cache) model_size_bytes 421 KB 421 KB +0.0%
phi3 (static-cache) num_nodes 56 56 +0.0%
qwen2 model_size_bytes 425 KB 425 KB +0.0%
qwen2 num_nodes 62 62 +0.0%
qwen2 (static-cache) model_size_bytes 425 KB 425 KB +0.0%
qwen2 (static-cache) num_nodes 58 58 +0.0%
qwen3_5_moe (hybrid-text-generation) model_size_bytes 506 KB 506 KB +0.0%
qwen3_5_moe (hybrid-text-generation) num_nodes 275 275 +0.0%
qwen3_5_text (hybrid-text-generation) model_size_bytes 458 KB 458 KB +0.0%
qwen3_5_text (hybrid-text-generation) num_nodes 129 129 +0.0%
qwen3_5_vl (hybrid-qwen-vl) model_size_bytes 977 KB 977 KB +0.0%
qwen3_5_vl (hybrid-qwen-vl) num_nodes 431 431 +0.0%
t5 (seq2seq) model_size_bytes 836 KB 836 KB +0.0%
t5 (seq2seq) num_nodes 166 166 +0.0%
whisper (speech-to-text) model_size_bytes 1008 KB 1008 KB +0.0%
whisper (speech-to-text) num_nodes 128 128 +0.0%

No performance regressions.

@github-actions

github-actions Bot commented Aug 8, 2026

Copy link
Copy Markdown

🏗️ Architecture Diff

Comparing 78437cdaefd430

Model Sub-model Changes Status
bert (feature-extraction) model 0
falcon model 0
gemma2 model 0
gemma4 (gemma4) decoder 0
gemma4 (gemma4) embedding 0
gemma4 (gemma4) vision_encoder 0
gemma4_text model 0
gpt2 model 0
llama model 0
llama (static-cache) model 0
mamba (ssm-text-generation) model 0
phi3 model 0
phi3 (static-cache) model 0
qwen model 0
qwen (static-cache) model 0
qwen2 model 0
qwen2 (static-cache) model 0
qwen2_moe model 0
qwen2_moe (static-cache) model 0
qwen3 model 0
qwen3 (static-cache) model 0
qwen3_5_moe (hybrid-text-generation) model 0
qwen3_5_text (hybrid-text-generation) model 0
qwen3_5_vl (hybrid-qwen-vl) decoder 0
qwen3_5_vl (hybrid-qwen-vl) embedding 0
qwen3_5_vl (hybrid-qwen-vl) vision_encoder 0
qwen3_moe model 0
qwen3_moe (static-cache) model 0
qwen3_next (hybrid-text-generation) model 0
t5 (seq2seq) decoder 0
t5 (seq2seq) encoder 0
whisper (speech-to-text) decoder 0
whisper (speech-to-text) encoder 0

No architecture changes detected.


Legend: ⚪ No change · 🔵 Minor (attrs/inits) · 🟡 Moderate (nodes added/removed) · 🔴 Major (interface changed)

Add model-agnostic build, generation, and pipeline configuration for world-model exporters, plus safe shared helpers for diffusers-style checkpoint inspection and asset resolution.

Keep LLM ArchitectureConfig and every model/component implementation unchanged; Cosmos3 Omni and Edge only consume the new outer pipeline configuration.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 997ab62c-69cb-4802-a5c6-fddd51bfd583
Signed-off-by: Xiaoyu Zhang <xiaoyuzhang@microsoft.com>
Match upstream chunk-zero temporal resampling so Cosmos3 can decode a single latent frame without running Conv on an empty temporal extent. Preserve bit-identical multi-frame behavior and add ORT/PyTorch parity coverage.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 997ab62c-69cb-4802-a5c6-fddd51bfd583
Signed-off-by: Xiaoyu Zhang <xiaoyuzhang@microsoft.com>
Replace the fixed SigLIP1-style vision graph with the published packed variable-resolution SigLIP2 contract, correct block-major projection ordering, and use interleaved multimodal RoPE.

Add image/video feature routing, processor metadata, real-checkpoint numerical parity tests, and image/video understanding coverage while preserving text-only behavior.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 997ab62c-69cb-4802-a5c6-fddd51bfd583
Signed-off-by: Xiaoyu Zhang <xiaoyuzhang@microsoft.com>
Describe conditioned video encoding, classifier-free guidance, prompt packing, and official Cosmos3 Edge generation recipes in pipeline.json. Ship the recommended negative prompt when available and preserve checkpoint-specific action behavior.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 997ab62c-69cb-4802-a5c6-fddd51bfd583
Signed-off-by: Xiaoyu Zhang <xiaoyuzhang@microsoft.com>
Comment thread src/mobius/_cosmos3_edge_world_model.py Fixed
Comment thread src/mobius/_cosmos3_world_model_test.py Fixed
Apply the repository Ruff formatter to resolve CI formatting findings.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 997ab62c-69cb-4802-a5c6-fddd51bfd583
Signed-off-by: Xiaoyu Zhang <xiaoyuzhang@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants