config#
Saved execution policy for GDN/KDA state QAT.
Classes
One execution policy shared by the chunked prefix and recurrent suffix. |
|
Assign a complete policy to supported modules matching |
- class LinearAttentionConfig#
Bases:
ModeloptBaseConfigOne execution policy shared by the chunked prefix and recurrent suffix.
servinguses native forward arithmetic with a differentiable adjoint;flais the disabled/default path.vllmtargets vLLM 0.30.0’s Triton prefill and single-token, non-speculative decode with BF16 operands and FP32 recurrent storage. Deployment must explicitly select Triton prefill (gdn_prefill_backend="triton") and enable packed recurrent decode (VLLM_ENABLE_FLA_PACKED_RECURRENT_DECODE=1). Mixed prefill/decode batches and automatic FlashInfer/CuTe dispatch are outside this profile. KDA uses the standalone FLA/Triton API, with no model-level serving guarantee.vllm_kimi_k3explicitly selects vLLM’s Kimi-K3 Triton kernels (also used by Kimi-Linear in vLLM 0.30), raw projections and that model package’s dependencies. These targets are saved in ModelOpt/Megatron policy metadata, not HF export; they do not configure or validate a remote server. Kimi serving must set bothkda_prefill_backendandkda_decode_backendtotriton; the supported gate is unbounded softplus.replayssmtargets the quantized-ReplaySSM fork’s INT8/Hadamard kernels. One quantized checkpoint feeds both reads and recurrence updates; separate read and recurrence precisions require the GDN-onlyreplayssm_two_precisionprofile: an FP32 anchor, FP8 block128 read copy along K, and a fixed 16-token window. It imports upstream ReplaySSM emulation; runtime caches use FP32 storage. For the shared-checkpoint fork,replay_window=1refreshes every token. Fresh prefill has no internal state QDQ. Two-precision replay reads the unrounded prefill checkpoint for its first output, then encodes the read copy.TensorQuantizer enables QDQ and owns the public profiles’ format and grouping; the ReplaySSM fork owns its checkpoint encoding.
state_block_vcontrols grouping only for legacy per-tile quantizers.- backend: Literal['fla', 'serving']#
- model_config = {'extra': 'forbid', 'validate_assignment': True}#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- precision: Literal['vllm', 'vllm_kimi_k3', 'replayssm', 'replayssm_two_precision']#
- replay_window: int#
- state_block_v: Literal[16, 32, 64, 128]#
- property state_codec#
The native profile fixes the codec; it is not an independent setting.
- class LinearAttentionPolicyEntry#
Bases:
ModeloptBaseConfigAssign a complete policy to supported modules matching
module_name.Rules apply in order: the last match wins, without merging fields. Unmatched rules are ignored locally, as with quant_cfg, so a shared recipe can be applied independently to pipeline stages and virtual-pipeline chunks.
- model_config = {'extra': 'forbid', 'validate_assignment': True}#
Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].
- module_name: str#