TinyLoRA
5 memberslucid.peft.tuners.tinyloralucid.peft.tuners.tinylora — TinyLoRA: a trainable vector of a few numbers projected into the SVD basis.
TinyLoRA (Morris et al., 2026, arXiv:2602.04118) freezes the truncated SVD of each adapted weight and
trains a vector of u numbers, which fixed random matrices turn into the small matrix between the
frozen factors; modules can share the vector, down to one vector for the whole model. Pick it for an
adapter of tens of parameters, or fewer.
Where the reference library keeps them, so isinstance(m, TinyLoraLayer) and from lucid.peft.tuners.tinylora import TinyLoraConfig, Linear read as they do there. One layer type for
each module the method adapts, nn.Linear and nn.Embedding. TinyLoraConfig and
TinyLoraModel (which holds the trained vectors) are here and exported from lucid.peft.
Importing the package registers the method (its config under PeftType.TINYLORA, its tuner and
layers), which is what makes get_peft_model and PeftModel.from_pretrained know it.
Morris, John X., et al. "Learning to Reason in 13 Parameters." [arXiv:2602.04118](https://arxiv.org/abs/2602.04118), 2026.
TinyLoRA (Morris et al., 2026, arXiv:2602.04118 — Learning to Reason in 13 Parameters) freezes the
rank-r SVD of each adapted weight, , and trains only a vector
of u numbers. Fixed random tensors project it into an matrix
, and the update is . weight_tying between
0 and 1 sets how much of the modules share; at 1 the whole model learns u numbers.
Classes
TinyLoraConfig9 methodsHow lucid.peft.get_peft_model adapts a model with TinyLoRA.
EmbeddingAn nn.Embedding with a TinyLoRA update: the table is looked up as .
LinearAn nn.Linear with a TinyLoRA update: , .
TinyLoraLayer21 methodsAdapter bookkeeping and the vector-to-update map shared by the TinyLoRA layers.
TinyLoraModel17 methodsA model with TinyLoRA layers put into it, the vectors they train, and the tools to take them out.