Fine-tune LLMs from one YAML. Layer streaming trains an 8B model on a 4 GB laptop GPU.
Python cliconsumer-gpudpofine-tuningggufhuggingfacellmllmopslocal-ailocal-llmloralow-vrammachine-learningollamapeftpythonpytorchqlorasfttransformers
docs(peft): name the Granite base #1132 actually ships (#1373)
Alpamys Makazhan24340c657acb
diff --git a/changelog.d/0.75.1/1164.fixed.md b/changelog.d/0.75.1/1164.fixed.mdindex af221309..4116bb6c 100644--- a/changelog.d/0.75.1/1164.fixed.md+++ b/changelog.d/0.75.1/1164.fixed.md@@ -6,7 +6,7 @@resolve to the four attention projections enumerated from the architecture on themeta device, the same policy as every other row of that table.- **Granite 4.0 says at setup that `auto` adapts only part of the decoder (#1122 by @MakazhanAlpamys in #1164).**- `granitemoehybrid` is a hybrid: on `granite-4.0-tiny-base-preview` only 4 of the 40+ `granitemoehybrid` is a hybrid: on `granite-4.0-h-tiny-base` only 4 of the 40decoder layers define a `self_attn` at all — the other 36 are Mamba-2 blocks — sothe attention-projection entry reaches a tenth of the model. Training now prints ayellow `Partial LoRA coverage:` line naming the model type, the counted fractiondiff --git a/docs/peft-and-efficiency.md b/docs/peft-and-efficiency.mdindex 153f0358..0ac25b14 100644--- a/docs/peft-and-efficiency.md+++ b/docs/peft-and-efficiency.md@@ -248,7 +248,7 @@ an explicit target list always wins unchanged:the refusal. `training.lora.target_parameters` on its own also suffices.**`granitemoehybrid` is adapted only in part, and says so at setup.** Granite 4.0-is a hybrid: on `ibm-granite/granite-4.0-tiny-base-preview` only 4 of the 40+is a hybrid: on `ibm-granite/granite-4.0-h-tiny-base` only 4 of the 40decoder layers carry a `self_attn` at all (`config.layer_types` is 36`linear_attention` + 4 `full_attention`), so the attention-projection entry abovereaches a tenth of the decoder. The other 36 layers are Mamba-2 blocksdiff --git a/src/soup_cli/utils/peft_wiring.py b/src/soup_cli/utils/peft_wiring.pyindex f5ae08e1..4368e7e2 100644--- a/src/soup_cli/utils/peft_wiring.py+++ b/src/soup_cli/utils/peft_wiring.py@@ -97,7 +97,9 @@ MOE_TEXT_LORA_TARGETS: dict[str, Any] = {# names are different. Previously invisible to the ratchet because the# recipe named ``THUDM/glm-4.6``, which 404s (#1132 repoints it)."glm4_moe": ("q_proj", "k_proj", "v_proj", "o_proj"),- # Granite 4.0 (``ibm-granite/granite-4.0-tiny-base-preview``) is a HYBRID:+ # Granite 4.0 (``ibm-granite/granite-4.0-h-tiny-base``, the base the+ # ``granite-4-sft`` recipe names since #1132, laid out exactly like its+ # ``-tiny-base-preview``) is a HYBRID:# ``config.layer_types`` is 36 ``linear_attention`` blocks and only 4# ``full_attention`` ones, and only those 4 of the 40 decoder layers define a# ``self_attn`` at all (measured: layers 5, 15, 25, 35). So this entry adaptsdiff --git a/tests/test_issue1122_glm4_granite_moe_targets.py b/tests/test_issue1122_glm4_granite_moe_targets.pyindex 8e373704..d4b13c0e 100644--- a/tests/test_issue1122_glm4_granite_moe_targets.py+++ b/tests/test_issue1122_glm4_granite_moe_targets.py@@ -4,8 +4,11 @@recipe names, but a base whose ``config.json`` cannot be fetched is recorded as``unresolvable`` and skipped. Two were: ``THUDM/glm-4.6`` (404) and``ibm-granite/granite-4.0-tiny-base`` (404). #1132 repoints them at-``zai-org/GLM-4.6`` and ``ibm-granite/granite-4.0-tiny-base-preview``, which+``zai-org/GLM-4.6`` and ``ibm-granite/granite-4.0-h-tiny-base``, whichresolve -- and pull two uncovered MoE ``model_type`` values into the catalogue.+The Granite measurement below was taken on the preview, before #1132 settled on+the GA base; the two ``config.json`` files give the same layout (40 layers,+attention at 5, 15, 25 and 35) and differ only in routed experts (62 vs 64).Measured with ``AutoConfig.from_pretrained`` + ``AutoModelForCausalLM.from_config``on the meta device (no weights downloaded), 2026-09-22, transformers 5.17.0: