adaptation
adaptation
¶
Configuration classes for model adaptation for parameters-efficient fine-tuning.
LoRAAdaptationConfig
dataclass
¶
LoRAAdaptationConfig(_target_='versatil.models.adaptation.lora.LoRAAdaptation', enabled=True, rank=8, alpha=16, dropout=0.0, target_modules=value, exclude_modules=None, bias='none', init_lora_weights=DEFAULT_LORA_INIT_WEIGHTS)
Hydra configuration for Low-Rank Adaptation.
Attributes:
| Name | Type | Description |
|---|---|---|
_target_ |
str
|
Import path instantiated by Hydra. |
enabled |
bool
|
Whether Hydra should instantiate LoRA adaptation for the target module. |
rank |
int
|
Adapter rank |
alpha |
int
|
Adapter scaling factor. PEFT applies the learned update with
scale |
dropout |
float
|
Dropout probability on the adapter path before the low-rank update. |
target_modules |
str
|
PEFT target-module preset. |
exclude_modules |
list[str] | None
|
Optional module names to leave unwrapped by LoRA. |
bias |
str
|
PEFT bias handling mode. |
init_lora_weights |
str
|
PEFT adapter weight initialization strategy. |