vllm.lora.peft_helper
¶
Classes:
-
PEFTHelper–A helper class for PEFT configurations, specifically designed for LoRA.
PEFTHelper
dataclass
¶
A helper class for PEFT configurations, specifically designed for LoRA. This class handles configuration validation, compatibility checks for various LoRA implementations.
Methods:
-
get_rank_and_scaling–Return the rank and scaling PEFT uses for
module_name, taking -
validate_legal–Validates the LoRA configuration settings against application
_validate_features()
¶
Check if there are any unsupported LoRA features.
get_rank_and_scaling(module_name)
¶
Return the rank and scaling PEFT uses for module_name, taking
rank_pattern and alpha_pattern into account.
module_name is the name in the adapter checkpoint, without the
base_model.model. prefix and before any weights mapping.
validate_legal(lora_config)
¶
Validates the LoRA configuration settings against application constraints and requirements.