Training-free method controls large language model behavior with simple edits

Training-Free Task Vectors for LLM Behavioral Control

Machine LearningArtificial Intelligence

Summary

Adjusting how large language models behave usually requires costly retraining. This paper presents a way to change a model's behavior without any retraining by finding directions in the model's settings using only normal usage data. The method allows adding, removing, or combining behaviors in a controlled way and works well while keeping the model's general skills intact. The researchers tested their approach on tasks controlling model behavior and found it effective compared to other methods. This could make it easier to modify AI models after they are built.

large language modelsmodel editingweight spacefine-tuningactivation steeringtask vectorsmodel controlforward passbehavior modification

Authors

Gabriel J. Perin, Lucas Boscaini, André Araujo, Nina S. T. Hirata

Abstract

Task vectors enable post-training model editing by identifying semantically meaningful directions in weight space, typically computed as the difference between a fine-tuned model and its pretrained initialization. However, this reliance on fine-tuning makes discovering such directions costly and limits the practicality of post-training model editing. To address this limitation, we introduce Training-Free Task Vectors (TFTVs), a novel method to compute task-vector-like directions without requiring fine-tuning. Our method maps activation steering vectors to rank-one weight-space edits using only forward-pass statistics, while satisfying arithmetic properties that directly support learning via addition, forgetting via subtraction, and the composition of multiple edits. Empirically, we evaluate TFTVs on large language model behavioral control tasks and show that they consistently amplify, suppress, and compose target behaviors while preserving general knowledge and problem-solving skills. We also validate our method against other editing and steering baselines, experimentally demonstrating that TFTVs achieve stronger trait control with better or competitive utility preservation. We hope our work opens new directions for the community in post-training model editing and broader training-free model control. Code is available on the project website: tftv-llm.github.io.