From 7fbedbd300f187269253536c7d033546b8d0e229 Mon Sep 17 00:00:00 2001 From: NanoCode012 Date: Fri, 20 Feb 2026 06:32:26 +0700 Subject: [PATCH] fix(doc): add limitation for unfrozen_parameters (#3416) --- src/axolotl/utils/schemas/config.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/axolotl/utils/schemas/config.py b/src/axolotl/utils/schemas/config.py index 91bc221ac..f1627367b 100644 --- a/src/axolotl/utils/schemas/config.py +++ b/src/axolotl/utils/schemas/config.py @@ -446,7 +446,16 @@ class AxolotlInputConfig( }, ) - unfrozen_parameters: list[str] | None = None + unfrozen_parameters: list[str] | None = Field( + default=None, + json_schema_extra={ + "description": "List of regex patterns for parameter names to keep unfrozen. " + "All other parameters will be frozen via requires_grad=False. " + "Note: range-based patterns (e.g. embed_tokens.weight$[:32000]) use gradient " + "zeroing rather than a true freeze, so weight decay will still apply to the " + "frozen portion and optimizer states are allocated for the full parameter." + }, + ) sequence_len: int = Field( default=512,