Skip to content

vllm.model_executor.layers.quantization.mxfp4

Classes:

GptOssMxfp4Config

Bases: Mxfp4Config

MXFP4 config for GPT-OSS checkpoints.

Checkpoints carry "quant_method": "mxfp4" in their JSON config. override_quantization_method() maps that to the canonical internal name so that the rest of the loading path uses "gpt_oss_mxfp4" consistently.

GptOssMxfp4MoEMethod

Bases: FusedMoEMethodBase

MXFP4 MoE quantization method.

Mxfp4Config

Bases: QuantizationConfig

Canonical base config for MXFP4 quantization.

Subclasses override get_name() and override_quantization_method() to register themselves as the handler for a specific checkpoint format.

_make_moe_method(moe)

MoE method for RoutedExperts. Subclasses override to pick a checkpoint-specific kernel family.

Mxfp4MoEMethod

Bases: FusedMoEMethodBase

MXFP4 MoE quantization method.

Methods:

  • dequantize_weight –

    Yield (experts, w13, w2) dequantized MXFP4 experts, for online

_build_moe_kernel(layer)

Build the modular MoE kernel from the (already in-format) weights.

dequantize_weight(layer)

Yield (experts, w13, w2) dequantized MXFP4 experts, for online requantization.

_use_k3_situ_aiter(moe)

Route Kimi-K3 weight-only MXFP4 SiTU MoE to AITER SiTUv2 on gfx950.