IC-493A linear direction in the input embedding space of Llama-2-7B-Chat, Llama-2-13B-Chat, Mistral-7B-Instruct-v0.3, and Phi-3-mini-128k predicts instruction-following success, generalizes across tasks but not instruction types, and can be used to improve adherence via representation engineering

Juyeon Heo, Christina Heinze-Deml, Oussama Elachqar, Kwan Ho Ryan Chan, Shirley You Ren, Andrew Miller, Udhyakumar Nallasamy, Jaya Narain

SourceDo LLMs ``know'' internally when they follow instructions?

The authors trained linear probes on frozen model representations to identify a direction in input embedding space that separates instruction-following successes from failures. This direction generalizes across unseen tasks (AUROC 0.70–0.88 for the first token) but not across unseen instruction types (AUROC 0.50–0.55, near chance), even when the training set is expanded to 23 instruction types. The information is available from the first token, before any response generation begins. When representations in the last layer are shifted along this direction (representation engineering), instruction-following success rates improve over both original outputs and random-direction shifts, while response quality is maintained or improved.

Evidence
interventional
Key metric
Task generalization AUROC (first token): Llama-2-7B 0.77±0.04, Llama-2-13B 0.83±0.03, Mistral-7B 0.74±0.02, Phi-3 0.88±0.03. Instruction-type generalization AUROC (first token): Llama-2-7B 0.52±0.03, Llama-2-13B 0.56±0.06, Mistral-7B 0.50±0.05, Phi-3 0.55±0.04. RE success rate (last layer): Llama-2-7B 0.57→0.59, Llama-2-13B 0.61→0.65, Mistral-7B 0.58→0.64, Phi-3 0.71→0.74 (inst-follow vs original).
Caveat
Analysis limited to 5 simple instruction types (or 23 in the expanded experiment) and 100 tasks; the authors note that unambiguously interpreting the meaning of the dimension remains an open question. Results are consistent across the four models studied but may not generalize to other architectures.
Model
Llama 2 / Llama 2 base Llama 2 7B Chat / Llama-2-chat-7b, Llama-2-13B-Chat, Mistral 7B / Mistral / Mistral 3 7B / Mistral-0.2-7B / Mistral-v0.1 Mistral-7B-Instruct-v0.3, Phi-3 Phi-3-mini-128k-instruct
Concepts
Linear representation
Datasets
IFEval / IFEval-Simple [source], IFEval / IFEval-Simple [eval]
Methods
Linear Probing / Ridge regression linear probing / Linear probe / Linear probe fine-tuning / Linear regression probing / Linear ridge regression probes / Supervised probing / ERM linear probe [primary], Representation Engineering / Representation engineering (control vectors) / Zou et al. 2023 (Representation Engineering) / Zou et al. (representation engineering) [primary], Principal component analysis [supporting]
Related work
Marks & Tegmark (geometry of truth) [builds-on], Azaria & Mitchell (internal state knows when lying) [builds-on], Zou et al. (representation engineering) [builds-on]
Related findings
IC-494
Extraction
automatic-extraction