vllm.model_executor.models.falcon_h1
¶
Inference-only FalconH1 model.
Classes:
-
FalconH1ForCausalLM– -
FalconH1ParallelHybrid–A hybrid decoder layer for FalconH1 where the input is processed
-
FalconH1SSMDecoderLayer–
FalconH1ForCausalLM
¶
Bases: Module, HasInnerState, SupportsLoRA, SupportsPP, IsHybrid
Methods:
-
get_mamba_state_shape_from_config–Calculate shapes for Mamba's convolutional and state caches.
get_mamba_state_shape_from_config(vllm_config)
classmethod
¶
Calculate shapes for Mamba's convolutional and state caches.
Parameters:
-
(vllm_config¶VllmConfig) –vLLM config
Returns:
FalconH1ParallelHybrid
¶
Bases: Module
A hybrid decoder layer for FalconH1 where the input is processed in parallel through both the self-attention branch and the SSM (Mamba) branch. Their outputs are then summed to produce the final hidden state.
This layer uses
- FalconH1AttentionDecoderLayer for the multi-head self-attention branch.
- FalconH1SSMDecoderLayer for the state-space (Mamba) branch.
FalconH1SSMDecoderLayer
¶
Bases: Module
_init_mup_vector()
¶
Non learnable per-block scaling vector composed of element-wise multipliersapplied to each separate contiguous block of the output of the linear projection (in_proj) before further processing (gating, convolution, SSM):
- Z block: [0 : d_ssm] → zxbcdt_multipliers[0]
- X block: [d_ssm : 2 * d_ssm] → zxbcdt_multipliers[1]
- B block: [2 * d_ssm : 2 * d_ssm + G * S] → zxbcdt_multipliers[2]
- C block: [2 * d_ssm + G * S : 2 * d_ssm + 2 * G * S]
→ zxbcdt_multipliers[3]
- dt block: [2 * d_ssm + 2 * G * S : end] → zxbcdt_multipliers[4]
where
- d_ssm: Dimension of state-space model latent
- G: Number of groups (n_groups)
- S: SSM state size per group
- All indices are divided by tp_size to support tensor parallelism