atlas

Research map / Large language models / Language, safety and interpretability

Unveiling and Manipulating Prompt Influence in Large Language Models

ICLR 2024 · Large language models › Language, safety and interpretability · approach: In-context learning analysis · 2 citations (OpenAlex)

Read the paperCheck your idea against 108,967 papers

AI-extracted summary. Written by AI from the paper's full text. Numbers and claims can be wrong or missing context, so check the paper before you cite or build on it.

Proposes Token Distribution Dynamics (TDD), which projects every input token's hidden states through the LM head to score prompt-token saliency for contrastive LLM generation, and applies it to zero-shot toxicity suppression and sentiment steering.

Problem

Input saliency for autoregressive LLMs: existing saliency methods (gradient, attention/vector, perturbation) misalign with next-token generation objectives or rely on linearity assumptions that break down in deep LLMs, so prompt influence on outputs is poorly explained.

Approach

Uses the LM head to project each input token's intermediate and final hidden states onto vocabulary distributions and measures saliency as the change in target-minus-alternative probability dynamics, in forward, backward, or bidirectional directions, requiring only forward passes and no hyperparameters.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Use TDD-backward instead of Con-GI for saliency explanationsGPT2-large · BLiMP (11 datasets)AOPC (%): 64.71 -> 70.46Helped
Use TDD-bidirectional instead of Con-GI for saliency explanationsGPTJ-6B · BLiMP (11 datasets)AOPC (%): 64.89 -> 71.05Helped
Use TDD-bidirectional instead of Con-GI for saliency explanationsBLOOM-7B · BLiMP (11 datasets)AOPC (%): 65.18 -> 70.22Helped
Use TDD-backward instead of Con-GI for saliency explanationsPythia-6.9B · BLiMP (11 datasets)AOPC (%): 64.59 -> 71.29Helped
Use TDD-bidirectional instead of Con-GI for saliency explanationsLLaMA2-7B · BLiMP (11 datasets)AOPC (%): 59.73 -> 65.51Helped
Neutralize salient toxic prompt triggers using TDD-bidirectionalGPT2 · REALTOXICPROMPTS subsetToxicity: 0.24 -> 0.20Helped
Replace the salient sentiment cue with a negative steering token using TDD-bidirectionalGPT2 · Neutral to negative (OWT)Negative percent: 0.82 -> 0.87Helped
Replace the salient sentiment cue with a positive steering token using TDD-bidirectionalGPT2 · Neutral to positive (OWT)Positive percent: 0.68 -> 0.78Helped
Use TDD-bidirectional for multiple target and alternative tokensGPT2-large · SST2AOPC (%): 56.27 -> 63.30Helped
Use TDD-bidirectional for multiple target and alternative tokensGPT2-large · AG's NewsAOPC (%): 66.34 -> 69.48Helped
Remove alternative tokens from TDD-forward (ablation)TDD-forward · BLiMP (11 datasets), GPT2-largeAOPC (%): 67.28 -> 66.55Hurt
Remove alternative tokens from TDD-backward (ablation)TDD-backward · BLiMP (11 datasets), GPT2-largeAOPC (%): 70.46 -> 67.48Hurt

Surprising findings

Limitations

Experimental setup

Datasets: BLiMP (11 subsets) REALTOXICPROMPTS (1,225-prompt subset) OWT neutral prompts (5000) SenticNet word lists AG's News SST2

Benchmarks: BLiMP REALTOXICPROMPTS OWT AG's News SST2

Metrics: AOPC Sufficiency Toxicity (Perspective API attributes) Fluency (GPT2-XL perplexity) Dist-1/2/3 positive/negative sentiment percentage

Baselines: Integrated Gradients Contrastive Gradient Norm Contrastive Gradient x Input Rollout WORDFILTER FFNControl Style Prompting Augmented Style Prompting

Builds on: contrastive explanations for LLMs logit lens integrated gradients AtMan

Closest papers by meaning

Writing a paper in this area? scime draft is a free LaTeX editor with AI included, real-time co-authors and a check of your references and venue rules before you submit. It also imports OpenAI Prism projects.

Open scime draft

Get the next scime Dispatch and a monthly field update

Free. We send a confirmation link first; every email has a one-click unsubscribe. Privacy