Downloads · 30 days
2
11% of all-time downloads
Jeesup/llama2_7b_chat_remove_50_seed42_jbbmix_calib
llama2_7b_chat_remove_50_seed42_jbbmix_calib is a machine learning model from Jeesup. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as llama2.
meta-llama/Llama-2-7b-chat-hf compressed with the complete SVD-LLM method (AIoT-MLSys-Lab/SVD-LLM, commit 7538cca98880), run as the authors' code rather than reimplemented. Llama-2 is multi-head, so component/svdllama…
Downloads · 30 days
2
11% of all-time downloads
All-time downloads
18
Public
Parameters
6.7B
13.5 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors13.5 GB · 99%
From the Hugging Face model README
meta-llama/Llama-2-7b-chat-hf compressed with the complete SVD-LLM method
(AIoT-MLSys-Lab/SVD-LLM, commit
7538cca98880), run as the authors' code rather than
reimplemented. Llama-2 is multi-head, so component/svd_llama.py is the authors'
file unmodified (gqa_patched: False); the only adaptation is a
compatibility shim that trims the causal mask transformers >= 4.48 builds one
column wider than the keys, which upstream's exact-shape assertion rejects.
yahma/alpaca-cleanedOnly the whitening calibration set. SVD-LLM chooses which singular components to keep by reconstruction importance on calibration data, and the published recipe uses WikiText-2 alone -- a distribution containing no harmful requests. This cell adds JailbreakBench's 100 harmful behaviours (JailbreakBench/JBB-Behaviors, harmful split) to that set, rendered prompt-only (the user turn plus the assistant header, no response, so the corpus does not decide by fiat whether it profiles refusal or compliance).
| corpus | sequences | tokens | detail |
|---|---|---|---|
wikitext2 | 255 | 522,240 | upstream get_calib_train_data |
jbb_harmful | 2 | 4,096 | 100 unique prompts, prompt-only=True |
The WikiText half is the identical get_calib_train_data("wikitext2", 256, seed 42) call the published cells make, so this arm adds sequences rather
than replacing any. The harmful prompts are 0.78% of the whitening token
budget: 100 behaviours are only 2,653 Llama-2 tokens, and a packed calibration
sequence must be exactly 2048 tokens long, so all 100 fit in 2 sequences
(54 appear twice as fill). Everything downstream -- truncation, both LoRA stages,
the fold -- is unchanged.
Why so small a share can matter: whitening factorises W S = U Sigma V^T with
S S^T = E[x x^T], so importance is measured after dividing by S. Directions
carrying little calibration energy are amplified in the whitened basis, and
adding energy along directions WikiText never excites can move the truncation
ranking far more than the token share suggests.
| Metric | Value |
|---|---|
| Parameter fraction retained | 0.4999 |
| WikiText-2 perplexity | 13.5883 |
| arc_easy (acc_norm) | 0.5168 |
| arc_challenge (acc_norm) | 0.2978 |
| hellaswag (acc_norm) | 0.5167 |
| winogrande (acc) | 0.5627 |
| openbookqa (acc_norm) | 0.3520 |
| piqa (acc_norm) | 0.6610 |
| mathqa (acc_norm) | 0.2399 |
| zero-shot mean | 0.4496 |
| AdvBench HarmBench ASR | 0.0750 |
| StrongREJECT HarmBench ASR | 0.0799 |
| Refusal rate, AdvBench (keyword) | 0.9731 |
| Refusal rate, benign control (keyword) | 0.0111 |
| Over-refusal rate (XSTest-safe) | 0.4426 |
| Over-refusal rate (OR-Bench-Hard-1K) | 0.4798 |
| Over-refusal macro rate | 0.4612 |
Over-refusal judging is reliable for this cell (XSTest-safe scored fraction 0.98; OR-Bench-Hard-1K scored fraction 0.99).
whitening_compression.json records the calibration set and all 224 per-matrix
ranks; build_manifest.json records the full build.
WikiText-2 perplexity; ARC-Easy/Challenge, HellaSwag, WinoGrande, OpenBookQA,
PIQA and MathQA zero-shot; AdvBench and StrongREJECT generation judged by
cais/HarmBench-Llama-2-13b-cls; over-refusal on XSTest-safe and OR-Bench-Hard-1K
judged by allenai/wildguard. All generation uses the chat template, greedy.
W = U @ V), so it loads with stock transformers and
needs no custom modelling code.