All models

Text-to-LoRA / Doc-to-LoRA (T2L)

A hypernetwork that writes LoRA adapters for a language model from a text description of the task.

Language · 96 operations Checked

100%

Showing the top corner; full diagram not loaded yetShowing a small copy; full diagram not loaded yetLarge diagram, not loaded yet

Open SVG

Loading diagram (62 KB)

Open in a new tab

Click or tap a spot to read it up close. Scroll or drag inside the diagram to move through it. Zoom with + and − or Ctrl and scroll. Press 0 for the whole graph. Swipe inside the diagram to move through it. Use + and − to zoom.

At a glance

Parameters
142.5M
Operations
96
Framework
PyTorch
Recurrent
No
Published
ICML 2025
Cited by
0 (as of 27 October 2026)
Authors
Rujikorn Charakorn, Edoardo Cetin, Yujin Tang, Robert Tjarko Lange
License
Apache-2.0
Checked
Passed: the trace was replayed operation by operation and matched the model's own output for this input.

Files

The diagram is a drawing of a TorchLens trace of the source code. It contains no code or weights.

Details
Stable ID
m20938
Graph hash
5c8b45607bdfa067334c45e20ddba19740641b73775a5b8c06ac0b43f7c833ad
Skeleton hash
fd4a889e5b259d3ffc2c5cce40f7b772743232adf6516c2039aa3382296ee090
Architecture hash
a005354f7036d0a5e58ffafc72f553cedad6c004e6c3b177f51977b38ce21f77
Diagram SHA-256
e8d5e95dfeb83fcbd0b92fde99ae6e1e0089d133ae3914a67e37e81365ab0fa0
TorchLens version
2.36.0
Renderer
graphviz 2.43.0+pyvips 3.2.0+libvips 8.18.7+render-opts@06c1f0d3
Check
Forward pass replayed in PyTorch

What it is

Text-to-LoRA (T2L) adapts a large language model to a new task from nothing but a plain-language description of that task. It is a hypernetwork, a network that outputs the weights of another network: in a single forward pass it builds a LoRA adapter, the small low-rank weight update normally obtained by fine-tuning.

The task description is first embedded with gte-large-en-v1.5. For each target module and layer index, the hypernetwork combines that embedding with a learnable embedding of the module type and layer and generates the two low-rank matrices of the adapter. The paper proposes three variants, L, M and S, which share a backbone and differ only in their output heads and learnable embeddings. The adapters are rank 8 and target only the query and value projections of every attention block.

T2L can be trained either to reconstruct existing LoRAs or with supervised fine-tuning (SFT), and the paper finds that a reconstruction-trained T2L fails to generalize to unseen tasks while an SFT-trained one can learn to cluster tasks. This model is the SFT-trained configuration for Gemma-2-2b-Instruct, one of the base models the paper tests alongside Mistral-7B-Instruct and Llama-3.1-8B-Instruct.

Key idea. Text-to-LoRA showed that a hypernetwork can generate task-specific LoRA adapters for a language model from a text description in one forward pass, generalizing zero-shot to unseen tasks.

  • text-to-lora
  • t2l
  • hypernetwork
  • lora generation
  • low-rank adaptation
  • instant transformer adaptation
  • task description
  • llm adaptation

AI-written summary, based on the paper and checked automatically against it; not reviewed by a person. Corrections welcome.

Cite the paper

@misc{charakorn2025texttolorainstanttransformeradaption,
      title={Text-to-LoRA: Instant Transformer Adaption}, 
      author={Rujikorn Charakorn and Edoardo Cetin and Yujin Tang and Robert Tjarko Lange},
      year={2025},
      eprint={2506.06105},
      archivePrefix={arXiv},
      primaryClass={cs.LG},
      url={https://arxiv.org/abs/2506.06105}, 
}