Large language models (LLMs) are AI programs trained to refuse harmful requests. When these models are fine-tuned, trained further on specialized data, they often lose this refusal ability, even if the fine-tuning data is harmless. This is a practical problem for deploying customized AI assistants.
SPECTRA is a method that restores refusal without any retraining. It extracts a pattern called the 'refusal direction' from the original safe model and injects it into the fine-tuned model's internal parameters, targeting only the parts that respond to harmful inputs while leaving normal behavior unchanged.
Evaluations show SPECTRA substantially improves refusal behavior while preserving the model's general coherence and domain-specific knowledge. It does not increase the rate of refusing harmless requests. This means developers can customize LLMs for their applications without sacrificing safety, using a simple, training-free fix.
