Table of Contents
Fetching ...

Intrinsic Self-Correction in LLMs: Towards Explainable Prompting via Mechanistic Interpretability

Yu-Ting Lee, Fu-Chieh Chang, Hui-Ying Shih, Pei-Yuan Wu

TL;DR

This work probes intrinsic self-correction in LLMs through mechanistic interpretability, introducing prompt-induced shifts and steering vectors to reveal how self-correction prompts steer hidden representations along interpretable latent directions. Across five open-source models and detoxification/toxification tasks, the study shows early rounds where shifts align with non-toxic or toxic directions, respectively, suggesting a representation-level mechanism beyond task scores. The authors propose a binary latent-feature steering framework and discuss scaling, robustness, and design implications for prompting. The findings offer a principled lens on how in-context prompting moves model representations and open avenues for robust prompt design and interpretability-driven safety checks.

Abstract

Intrinsic self-correction refers to the phenomenon where a language model refines its own outputs purely through prompting, without external feedback or parameter updates. While this approach improves performance across diverse tasks, its internal mechanism remains poorly understood. We analyze intrinsic self-correction from a representation-level perspective. We formalize and introduce the notion of a prompt-induced shift, which is the change in hidden representations caused by a self-correction prompt. Across 5 open-source LLMs, prompt-induced shifts in text detoxification and text toxification align with latent directions constructed from contrastive pairs. In detoxification, the shifts align with the non-toxic direction; in toxification, they align with the toxic direction. These results suggest that intrinsic self-correction functions as representation steering along interpretable latent directions, beyond what standard metrics such as task scores or model confidence capture. Our analysis offers an interpretability-based account of intrinsic self-correction and contributes to a more systematic understanding of LLM prompting.

Intrinsic Self-Correction in LLMs: Towards Explainable Prompting via Mechanistic Interpretability

TL;DR

This work probes intrinsic self-correction in LLMs through mechanistic interpretability, introducing prompt-induced shifts and steering vectors to reveal how self-correction prompts steer hidden representations along interpretable latent directions. Across five open-source models and detoxification/toxification tasks, the study shows early rounds where shifts align with non-toxic or toxic directions, respectively, suggesting a representation-level mechanism beyond task scores. The authors propose a binary latent-feature steering framework and discuss scaling, robustness, and design implications for prompting. The findings offer a principled lens on how in-context prompting moves model representations and open avenues for robust prompt design and interpretability-driven safety checks.

Abstract

Intrinsic self-correction refers to the phenomenon where a language model refines its own outputs purely through prompting, without external feedback or parameter updates. While this approach improves performance across diverse tasks, its internal mechanism remains poorly understood. We analyze intrinsic self-correction from a representation-level perspective. We formalize and introduce the notion of a prompt-induced shift, which is the change in hidden representations caused by a self-correction prompt. Across 5 open-source LLMs, prompt-induced shifts in text detoxification and text toxification align with latent directions constructed from contrastive pairs. In detoxification, the shifts align with the non-toxic direction; in toxification, they align with the toxic direction. These results suggest that intrinsic self-correction functions as representation steering along interpretable latent directions, beyond what standard metrics such as task scores or model confidence capture. Our analysis offers an interpretability-based account of intrinsic self-correction and contributes to a more systematic understanding of LLM prompting.
Paper Structure (25 sections, 3 equations, 8 figures)

This paper contains 25 sections, 3 equations, 8 figures.

Figures (8)

  • Figure 1: An example of intrinsic self-correction for text detoxification in a Q&A scenario, with Toxicity measured by RoBERTa-toxicity-classifier logacheva-etal-2022-paradetox.
  • Figure 2: Evolution of toxicity scores with strong prompts scored by RoBERTa. We report the mean plus and minus standard deviation of toxicity for detoxification and toxification with strong prompts. In four of five models, most changes occur in rounds 1–2 and curves plateau thereafter. For toxification, later rounds exhibit higher variance, largely because occasional refusals yield near-zero toxicity while successful toxic generations score much higher.
  • Figure 3: Cosine similarity between prompt-induced shifts and non-toxicity steering vectors. For each layer, we plot $\operatorname{CosSim}(\ell_{1}, \boldsymbol{\mu}^{(l)})$ and $\operatorname{CosSim}(\ell_{2}, \boldsymbol{\mu}^{(l)})$ under strong prompts, compared against the random baseline. In the effective rounds, curves separate from baseline, typically peak in mid-to-late layers in absolute value, and exhibit positive values for non-toxic prompts and negative for toxic prompts. Occasional round-2 attenuation or sign flips likely reflect last-token sensitivity.
  • Figure 4: Evolution of toxicity scores with strong prompts scored by Detoxify.
  • Figure 5: Evolution of toxicity scores with weak prompts scored by RoBERTa.
  • ...and 3 more figures