DoRA: Weight-Decomposed Low-Rank Adaptation
Citation. Shih-Yang Liu (NVIDIA and HKUST), Chien-Yi Wang, Hongxu Yin, Pavlo Molchanov and Yu-Chiang Frank Wang (all NVIDIA). Then Kwang-Ting Cheng (HKUST) and Min-Hung Chen (NVIDIA). "DoRA: Weight-Decomposed Low-Rank Adaptation". arXiv:2402.09353, version 6 of 9 July 2024. Version 1 is of 14 February 2024. Venue: Proceedings of the 41st International Conference on Machine Learning (ICML 2024), PMLR 235. The arXiv comment says "ICML2024(Oral)". The code is at github.com/NVlabs/DoRA. The acknowledgements say that Hugging Face put DoRA into its peft package. They also say that Answer.AI made the QDoRA code and runs that Section 6.1 reports. The paper gives no funding statement.
Status. Planned. #4782 (catastrophic interference, weight-space programming and LoRA) would use it in its LoRA strand. It also adds a method to the open #5133 (the weight change at a pole). The method splits each neuron's weight change into a change of length and a change of direction. No code, skill or protocol in this repo depends on it. The maintainer designs the campaign to fix models, so this page reports evidence and records questions only.
Read. On 2026-11-19 we downloaded the arXiv v6 PDF (23 pages) with curl and converted it with pdftotext. The reader was this page's author, a model (Claude Opus 5.5). We read in the source's own text the abstract, Sections 1 to 7, the acknowledgements and the impact statement. We also read Appendices A.1 to A.9. We read Tables 1 to 15 as extracted text. We did not see the figures as images, so for Figures 1 to 11 we have the captions and the numbers that the text states. We did not read the references in full, or versions 1 to 5. To settle which axis of a weight matrix the magnitude lies on, we also read the official file commonsense_reasoning/peft/src/peft/tuners/dora.py in the code repository.
Summary
Claim. LoRA and full fine-tuning (FT) change a weight's magnitude and direction in different patterns. DoRA splits each pre-trained weight into a magnitude vector and a direction matrix. It trains the magnitude directly and the direction through LoRA. It learns more like FT, it beats LoRA on many tasks, and it merges into the weights after training at no extra inference cost.
Method.
- The split. The paper writes a weight W ∈ R^(d×k) as W = m · V/‖V‖_c. Here ‖·‖_c is the norm of each column, so m ∈ R^(1×k) holds one length per column, and each column of V/‖V‖_c has unit length (Eq. 2).
- DoRA. Training starts from m = ‖W0‖_c and V = W0. V stays frozen, m trains, and LoRA adds BA to V. The merged weight is W′ = m · (W0 + BA)/‖W0 + BA‖_c (Eq. 5). To save memory, the backward pass treats the norm ‖V + ΔV‖_c as a constant (Section 4.3).
- Which axis. The paper's text does not say which axis of W is the input. The official code takes the norm of an
nn.Linearweight overdim=1. So each output feature of a layer has one magnitude scalar. - The analysis (Section 3.2). For each matrix and checkpoint, ΔM is the mean over columns of |m_t − m_0| (Eq. 3). ΔD is the mean over columns of 1 − cos between the tuned column and the pre-trained column (Eq. 4). The case study is VL-BART on four image-text tasks. It reads the query and value matrices of six layers at three intermediate steps and the final step, for FT, LoRA and DoRA.
- Experiments. Commonsense reasoning (8 tasks, one merged training set) on LLaMA-7B, LLaMA-13B, LLaMA2-7B and LLaMA3-8B. Image-text and video-text tasks on VL-BART. Visual instruction tuning on LLaVA-1.5-7B. Alpaca instruction tuning on LLaMA-7B and LLaMA2-7B, with MT-Bench scores from a GPT-4 judge on 80 questions. Rank sweeps, a sweep of training-set size, and DoRA combined with VeRA (DVoRA).
- Baselines. LoRA, Prefix, Series and Parallel adapters, VeRA and FT. The LLaMA-7B and LLaMA-13B baselines come from Hu et al. (2023). LoRA on LLaMA2-7B and LLaMA3-8B uses the hyperparameters of Hu et al. (2023). DoRA keeps LoRA's rank and changes "only the learning rate".
- Modules. For commonsense reasoning, DoRA adapts Q, K, V, Up and Down (Table 8). LLaVA and Alpaca runs adapt Q, K, V, O, Up, Down and Gate (Tables 10 and 11).
- Runs. The text gives one result for each setting. It names no seeds, intervals or tests.
Findings, as the source reports them. All numbers are from the text or from the tables.
| Setting | Result |
|---|---|
| Correlation of ΔD and ΔM, VL-BART query matrices (Section 4.1) | FT −0.62, DoRA −0.31, LoRA 0.83 |
| Commonsense, average accuracy (Table 1) | LLaMA-7B: LoRA 74.7, DoRA 78.4, DoRA at half rank 77.5. LLaMA-13B: LoRA 80.5, DoRA 81.5, Parallel adapter 81.4 |
| Commonsense, average accuracy (Table 1) | LLaMA2-7B: LoRA 77.6, DoRA 79.7, DoRA at half rank 80.5. LLaMA3-8B: LoRA 80.8, DoRA 85.2, DoRA at half rank 85.0 |
| Share of trainable parameters (Table 1) | LLaMA-7B: LoRA 0.83%, DoRA 0.84%. The magnitude vectors add 0.01% |
| VL-BART image-text, average (Table 2) | FT 77.3, LoRA 76.5, DoRA 77.4 |
| VL-BART video-text, average (Table 3) | FT 87.5, LoRA 83.5, DoRA 85.4 |
| LLaVA-1.5-7B, seven benchmarks, average (Tables 4 and 12) | FT 66.5, LoRA 66.9, DoRA 67.6 |
| MT-Bench score, Alpaca 10K (Table 5) | LLaMA-7B: LoRA 5.1, DoRA 5.5, VeRA 4.3, DVoRA 5.0. LLaMA2-7B: LoRA 5.7, DoRA 6.0, VeRA 5.5, DVoRA 6.0 |
| MT-Bench against training-set size, LLaMA2-7B (Section 5.4) | At 7,000 samples, DoRA and DVoRA lead LoRA and VeRA by 0.3 and 0.33. At 1,000, by 0.29 and 0.22 |
| Rank sweep, LLaMA-7B commonsense average (Table 15) | LoRA r = 4, 8, 16, 32, 64: 39.5, 40.7, 70.9, 74.7, 65.8. DoRA: 61.9, 77.9, 77.5, 78.4, 72.1 |
| Magnitude only in some modules (Table 6) | Direction in Q, K, V and magnitude in all seven modules: 77.5 on LLaMA-7B (0.39% of parameters), 81.3 on LLaMA-13B (0.31%) |
| Memory saving of the detached norm (Table 7) | LLaMA-7B 37.3 GB to 28.2 GB, average 78.3 to 78.1. VL-BART 23.4 GB to 20.5 GB, average 77.3 to 77.4 |
| QDoRA on Orca-Math, by Answer.AI (Section 6.1) | QDoRA beats QLoRA by 0.19 on LLaMA2-7B and 0.23 on LLaMA3-8B in exact match. It "slightly outperforms" FT |
| Deviation from the pre-trained weights, LLaMA2-7B (Section 5.1, A.4) | DoRA's ΔM and ΔD are smaller than LoRA's in Q, K and V at every layer. Figures 3 and 8 only, no numbers in the text |
Where the claims go beyond the evidence
- The analysis that motivates the method is small. The correlations −0.62, −0.31 and 0.83 come from one model, VL-BART. Each one has six layers at four checkpoints, so about 24 points, with no interval. The text does not state the number of points.
- The analysis covers attention only. Section 3 reads the query and value matrices, and Appendix A.4 reads Q, K and V of LLaMA2-7B. No figure or table reads the MLP matrices. The experiments apply the method to Up, Down and Gate too.
- The gradient argument is a sketch. Section 4.2 assumes that two updates have equal gradient norms. It then says that the conclusion "generally holds in practice", with Figure 2(c) as the only evidence.
- The baselines are not tuned alike. DoRA changes its learning rate from the LoRA setting. The LoRA rows on LLaMA-7B and LLaMA-13B come from Hu et al. (2023), and on LLaMA2-7B and LLaMA3-8B they use that paper's hyperparameters. So part of the gap can be the learning rate.
- Some LoRA runs seem to fail, not to underfit. In Table 15, LoRA at r = 64 scores 17.6 on HellaSwag, and LoRA at r = 4 and 8 averages about 40. DoRA at r = 64 scores 40.7 on HellaSwag. HellaSwag has four choices, so these scores are near or below chance. The "+37.2%" gap at r = 8 compares DoRA with such a run. One run per setting cannot tell an unstable run from a lack of capacity.
- The same setting has two numbers. Table 1 gives DoRA 78.4 on LLaMA-7B. Tables 6 and 7 give 78.1 for the same configuration, and Section 4.3 says that every later run uses the detached norm.
- The introduction picks the larger gain. It gives "+2.9 on LLaMA2-7B", which is the half-rank DoRA. Full-rank DoRA leads LoRA by 2.1 there, and the half-rank one beats it.
- "Less deviation explains the gain" is an inference. Section 5.1 concludes that the hypothesis "is valid" because DoRA moves the weights less and scores higher. Both facts can come from one cause, such as a different learning rate. No run tests the link.
- No intervals or seeds anywhere. Many gaps are small, for example 81.5 against 81.4 for the Parallel adapter on LLaMA-13B. MT-Bench uses one GPT-4 judge on 80 questions.
- Some results are not the authors' runs. QDoRA comes from Answer.AI's project. The text-to-image result in Section 6.2 is a set of images with no metric.
- The paper measures no forgetting. All scores are on the target tasks. The paper says nothing about the base model's skill on other tasks, or about single units.
The authors state their scope in Section 5.3. There, LoRA beats FT, and they say that FT "might be experiencing issues with overfitting", so DoRA's gain may be smaller.
Use in this repo
- The repo has no LoRA, DoRA or fine-tuning code.
fixing-models.mdnotes that the repo has no fine-tuning or weight-edit code. DoRA appears only as a baseline inloki-knowledge-implanting.md. There, on Llama3.1-8B, DoRA's forgetting Avg is 4.92% against 16.11% for the ToolACE LoRA. Those are LoKI's numbers, not this paper's. - On the input side, DoRA's magnitude is a per-neuron scalar.
docs/PROTOCOL.mddefines a neuron as one coordinate ofact(gate(x)) * up(x), the input to the down projection. Innn.Linear, row i of W_gate and of W_up holds neuron i's input weights. DoRA's magnitude has one scalar for each output feature, so it is one scalar for each neuron there. This is our inference from the code, not a claim of the paper. - On the output side, it is not. The output features of W_down are residual dimensions. Neuron i's output weights are column i of W_down, and DoRA gives no scalar for that column. So a DoRA change to W_down rescales residual dimensions across all neurons. A per-neuron read of Δ in W_down does not match DoRA's split.
- The keep test already removes the per-neuron magnitude.
docs/analyses/base-instruct.mdscales each pole's threshold by the ratio of its maximum in the instruct model to its maximum in the base model. A positive rescale of row i of W_up multiplies the activation by the same factor, so the verdict does not change. The Pearson correlation in that analysis is also blind to a positive rescale. So both measures see only the direction part, for W_up. - The gate is different. The gate passes through SiLU, which is not linear. So a rescale of row i of W_gate changes the shape of the activation, most near zero and on the negative side. A negative pole may move under a pure magnitude change of the gate, while a positive pole with large pre-activations moves little.
- The scale ratio still goes with failure at its extremes. We counted this from
docs/analyses/base-instruct-0.5b.jsonlon 2026-11-19, so it is our reading, not the analysis's. On Qwen2.5-0.5B, the median ratio is 0.956 for poles that keep and 0.957 for poles that fail. But 26 poles have a ratio below 0.8 or above 1.25, and only 16 of them keep (62%, against 236 of 285 for the rest). A two-sided Fisher exact test gives p = 0.016. We chose the 0.8 to 1.25 band ourselves, so this result is exploratory. The three lowest ratios (0.17, 0.46 and 0.64) all fail. On Qwen2.5-1.5B, all 3 poles outside the band keep. - What this adds to #5133. #5133 reads the norm of Δ in each pole's own rows and columns. That norm mixes a change of length and a change of direction. The paper's Eq. 3 and 4 split them. For each pole, read ΔM_i = |‖w′_i‖ − ‖w_i‖| / ‖w_i‖ and ΔD_i = 1 − cos(w′_i, w_i), on row i of W_gate and of W_up. Then test which one predicts failure. The argument above predicts that ΔD on W_up predicts failure, and that ΔM on W_up tracks the scale ratio. Column i of W_down can have the same split, but it is not DoRA's axis. This fits as a comment on #5133, not as a new issue.
- A merged DoRA change is not low rank. This point is our algebra from Eq. 5, not a claim of the paper. Row i of the merged weight is s_i(w_i + (BA)_i), with s_i = m_i/‖w_i + (BA)_i‖. So Δ_i = (s_i − 1)w_i + s_i(BA)_i. The first term rescales the rows of W0, and it can have full rank. So the rank read in #5133 step 1 cannot tell a merged DoRA, or any per-neuron rescale, from a full fine-tune. Reading the rank of the row-normalized change, W′/‖W′‖_row − W0/‖W0‖_row, removes that term.
- The paper's FT pattern could be read on the Qwen pairs. The paper finds that FT's ΔD and ΔM correlate negatively across layers and steps. The same pair can be read per layer from the Qwen2.5 base and instruct weights, without training. A negative slope would not show that the instruct model used FT, because the paper's evidence is about 24 points on one model. So this belongs in #5133's rows as a description, not as a test of how Qwen's makers tuned it. The analysis does not record whether Qwen2.5 used LoRA or FT.
- A fine-tune can change behaviour and keep every explanation. Table 6 tunes only the magnitudes of O, Gate, Up and Down, with direction in Q, K and V only. It reaches 77.5 on LLaMA-7B against LoRA's 74.7. A magnitude-only change of W_up leaves each neuron's input direction in place, so the keep test would pass every pole there. Yet the neuron's weight in the model's output changes. So an explanation that keeps does not show that the neuron's role keeps. This is evidence for the fix campaign, not a design.
- The same holds over training.
papers/neuron-development/reads Pythia-70m's 86 VERIFIED poles by correlation with their final form. The median is 0.62 at step 16,000, and adjacent checkpoints correlate at a median of 0.78 to 0.82. That correlation is also blind to a positive rescale. So the reported drift is a change of direction or shape, not of scale. - Neighbouring reviews.
lora-learns-less-forgets-less.mdargues that a LoRA change moves every neuron of a layer in one shared r-dimensional subspace. DoRA adds one free scalar per neuron on the input side. So under DoRA, neurons can change their scale freely, while their directions still share that subspace.text-to-lora.mdmakes adapters with a hypernetwork, and a DoRA-style adapter would add a magnitude vector to its output. - A question for the maintainer. Should the keep test report the scale ratio as an outcome of its own, beside keep or fail? Today the test divides the ratio out. A pole that keeps its explanation at 0.17 of its old range does much less in the model. This changes what "keeps" means, so this page records it as a question and opens no issue.