when fine-tuning 7b with lora, i set target modules to "all-linear", which layers does…
- User
when fine-tuning 7b with lora, i set target modules to "all-linear", which layers does this include in transformer LLM?
- Assistant
When fine-tuning a 7-billion-parameter transformer language model (LLM) using Low-Rank Adaptation (LoRA) and setting the target modules to "all-linear," you are specifying that LoRA should be applied to all linear (fully connected) layers within the model. In transformer architectures, these linear layers typically include:
-
Attention Mechanism Linear Layers:
- Query, Key, and Value Projections: These layers transform input embeddings into query, key, and value vectors for the attention mechanism.
-
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.