Upload svd_llm/heal/llama2-13b-base/README.md with huggingface_hub
Browse files
svd_llm/heal/llama2-13b-base/README.md
ADDED
|
@@ -0,0 +1,53 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: llama2
|
| 3 |
+
base_model: NousResearch/Llama-2-13b-hf
|
| 4 |
+
tags:
|
| 5 |
+
- svd
|
| 6 |
+
- low-rank
|
| 7 |
+
- model-compression
|
| 8 |
+
- llama2
|
| 9 |
+
---
|
| 10 |
+
|
| 11 |
+
# SVD-LLM (ICLR 2025): LLaMA-2-13B base @ 7.74B, KD-healed
|
| 12 |
+
|
| 13 |
+
SVD-LLM: truncation-aware data whitening (256 wikitext2 samples) + closed-form parameter update, official code ([AIoT-MLSys-Lab/SVD-LLM @ 7538cca](https://github.com/AIoT-MLSys-Lab/SVD-LLM)), uniform ~41.6% removal across all 7 projection types of all 40 layers.
|
| 14 |
+
|
| 15 |
+
- **7.738B params** (7,737,799,680; down from 13.02B, ~40.6% reduction)
|
| 16 |
+
- Healed with pure forward-KL distillation from the dense 13B base teacher: **60M tokens**,
|
| 17 |
+
held-out KL **1.6616 -> 0.1912**, probe MMLU (limit 40/subtask) **25.75% -> 43.33%**
|
| 18 |
+
- ⚠️ **Probe-only evaluation**: full-benchmark evaluation (full MMLU / HellaSwag / BoolQ /
|
| 19 |
+
TriviaQA / GSM8K) was intentionally NOT run for the base-model series. All numbers below
|
| 20 |
+
come from the same probe harness (lm-eval 0.4.12, MMLU limit=40 questions/subtask,
|
| 21 |
+
n=2280, seed 1234, fp16) and are mutually comparable.
|
| 22 |
+
|
| 23 |
+
| Reference (same probe harness) | probe MMLU |
|
| 24 |
+
|---|---:|
|
| 25 |
+
| unhealed 7.74B (same structure, unhealed sibling dir) | 25.75% |
|
| 26 |
+
| **this checkpoint (healed 60M)** | **43.33%** |
|
| 27 |
+
| FP16 dense 13B base teacher | 54.25% |
|
| 28 |
+
|
| 29 |
+
(SVD-LLM V2 / TR-3 base 13B siblings are still being produced; this table will gain those
|
| 30 |
+
rows when they land.)
|
| 31 |
+
|
| 32 |
+
## How to load
|
| 33 |
+
|
| 34 |
+
```python
|
| 35 |
+
import json
|
| 36 |
+
from lowrank_linear import build, materialize_all
|
| 37 |
+
|
| 38 |
+
model = build("NousResearch/Llama-2-13b-hf",
|
| 39 |
+
json.load(open("ranks.json")), "state_dict_fp16.pt",
|
| 40 |
+
device="cuda")
|
| 41 |
+
# for generation/eval: fuse the factors first (inference-only)
|
| 42 |
+
materialize_all(model)
|
| 43 |
+
```
|
| 44 |
+
|
| 45 |
+
`ranks.json` maps each compressed projection path to its integer rank; untouched weights are
|
| 46 |
+
stock LLaMA-2-13B base tensors. The full healing-provenance record (data mixture & revisions,
|
| 47 |
+
decontamination, SHA256 of inputs/checkpoint, 5M milestone trajectory) is in `provenance.json`.
|
| 48 |
+
|
| 49 |
+
## License
|
| 50 |
+
|
| 51 |
+
Derived from Meta's LLaMA 2 (`NousResearch/Llama-2-13b-hf`, an unofficial redistribution of
|
| 52 |
+
the same weights). Subject to the **LLaMA 2 Community License** — see
|
| 53 |
+
https://ai.meta.com/llama/license/.
|