For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /max/get-started.md).
Mojo package
state_space
State space model kernels for Mamba and related architectures.
This package provides GPU and CPU kernel implementations for the selective scan, causal conv1d, and SSD (state-space duality) operations used by Mamba, Mamba-2, and Gated DeltaNet models, including variable-length sequence variants for continuous-batching inference.
Both forward and update (decode-step) paths are included, and operation
registrations in the *_ops modules wire these kernels into the MAX graph
compiler.
Modulesβ
- β
causal_conv1d: Core Causal Conv1D Kernel Implementations. - β
causal_conv1d_ops: Causal Conv1D operation registrations for state space models. - β
gated_delta: Gated DeltaNet recurrence kernel for Qwen3.5: Pass 2 of two-pass prefill. - β
gated_delta_conv1d: Causal depthwise conv1d for the Gated DeltaNet two-pass prefill. - β
gated_group_rmsnorm: Fused gated group-RMSNorm for the Mamba-2 mixer (norm_before_gate=False). - β
mamba2_ssd_scan: Mamba-2 SSD (state-space duality) varlen prefill scan. - β
rms_norm_fused_residual: RMSNorm with fused residual connection for state space models. - β
rms_norm_fused_residual_ops: RMSNorm fused residual op registration for state space models. - β
selective_scan: Selective scan kernel implementations for Mamba SSM prefill and decode. - β
selective_scan_ops: Selective scan operation registrations for Mamba SSM. - β
varlen_causal_conv1d: Causal Conv1D with variable length sequence support (vLLM interface). - β
varlen_causal_conv1d_ops: Varlen Causal Conv1D operation registrations for Mamba SSM. - β
varlen_selective_scan: Variable-length selective scan kernels for Mamba SSM architecture. - β
varlen_selective_scan_ops: Varlen selective scan operation registrations for Mamba SSM.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!