vllm.transformers_utils.configs.speculators.algos ¶
update_dflash ¶
Apply DFlash specific configuration transformations to the dict used to construct the Transformers PreTrainedConfig.
DFlash specific fields: - draft_vocab_size: Size of the draft model's vocabulary - target_hidden_size: Hidden size of the target model - mask_token_id (required): Token ID used for parallel drafting mask placeholders - aux_hidden_state_layer_ids (required): Layer indices from the target model whose intermediate hidden states are used as context for the DFlash drafter. Mapped to both eagle_aux_hidden_state_layer_ids (for gpu_model_runner) and dflash_config.target_layer_ids (for the DFlash model).
Source code in vllm/transformers_utils/configs/speculators/algos.py
update_eagle3 ¶
Apply Eagle-3 specific configuration transformations to the dict used to construct the Transformers PreTrainedConfig.
Eagle-3 specific fields: - draft_vocab_size: Size of the draft model's vocabulary - target_hidden_size: Hidden size of the target model - norm_before_residual: Whether to apply norm before residual connection - norm_before_fc: Whether to apply RMSNorm before the fc projection - eagle_aux_hidden_state_layer_ids: List of layer indices from the base model to use as auxiliary inputs for the Eagle3 drafter. These layers provide intermediate hidden states that help the drafter make better predictions. This is the standard field used in Eagle3 checkpoints.