Antidote on Tiny Aya: attack and repaired LoRA adapters

Content warning. These are deliberately harmful research artifacts from a safety evaluation. The attack adapters were fine-tuned on harmful BeaverTails answers and make the model comply with harmful requests; the generations include those answers. Use them only to study attacks and defences.

LoRA adapters for CohereLabs/tiny-aya-global from experiment 1 of the ValueShift Lexsi hackathon entry: does Antidote (post-fine-tuning pruning of a harmful update) beat matched pruning nulls? Attack language: ru. Code, method and results: see the GitHub repository linked from the write-up. Per-run scores and generations: ValueShift/exp1-antidote-ru-logs.

Contents

Folder What
adapters/d{dose}_s{seed}/ Harmful attack adapter: LoRA r=16 on q_proj, k_proj, v_proj, o_proj, gate_proj, up_proj, down_proj, SST2 + dose harmful pairs, attack seed seed. attack_meta.json has the training log and harmful example ids.
repaired/<run_id>/ The attack adapter after a repair. repair_meta.json describes it.
relearn/<arm>+RL<k>__.../ A repaired adapter after k further harmful fine-tuning steps (relearning re-attack).

run_id = d<dose>_s<seed>__<arm>__a<alpha>[__m<mask seed>]. Arms: A3 Antidote (Wanda on the LoRA factors, harmful calibration), A4a random pruning, A5a magnitude-only pruning, A6 norm-matched shrink, A7 benign calibration. Merged-weight arms (A1, A2) are not stored: they are rebuilt from the attack adapter by the code.

Load

from transformers import AutoModelForCausalLM, AutoTokenizer
from peft import PeftModel

tok = AutoTokenizer.from_pretrained("CohereLabs/tiny-aya-global")
base = AutoModelForCausalLM.from_pretrained("CohereLabs/tiny-aya-global", torch_dtype="bfloat16", device_map="auto")
model = PeftModel.from_pretrained(base, "ValueShift/exp1-antidote-ru-adapters", subfolder="repaired/d100_s0__A3__a0.2")

License: the adapters are derived from CohereLabs/tiny-aya-global and follow its license.

Downloads last month
-
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for ValueShift/exp1-antidote-ru-adapters

Adapter
(393)
this model

Collection including ValueShift/exp1-antidote-ru-adapters