Skip to main content
Task Arithmetic treats fine-tuning as a vector in parameter space. This page defines task vectors, their linear combinations, and the rules for adding skills and removing biases. Reference: Ilharco et al. 2022.

Task Vector Definition

Given a pre-trained base model theta_pre and a fine-tuned model theta_ft:
tau is a task vector: a set of parameter deltas that encode the skill or behavior learned during fine-tuning.

Linear Combinations

Multiple task vectors can be combined with scalar coefficients:

Adding Skills

To add a skill, set the corresponding alpha to a positive value:
Multiple skills can be added simultaneously:

Forgetting and Negation

To remove a bias or unwanted behavior, negate the task vector:
This is the basis of forgetting controls in EMEP. See Catastrophic Forgetting Controls for extended discussion. Reference: McCloskey & Cohen 1989; Kirkpatrick et al. 2017.

Combination Rules

Preconditions

All task vectors must be derived from the same theta_pre. Merging task vectors from different base models is undefined and produces INVALID.

Failure Modes