atlas

Research map / Architectures and efficiency / Attention and transformers

In-Context Denoising with One-Layer Transformers: Connections between Attention and Associative Memory Retrieval

ICML 2025 · Architectures and efficiency › Attention and transformers · approach: Attention head mechanisms · 0 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.

Introduces in-context denoising, showing single-layer (linear or softmax) attention can approximate Bayes-optimal denoisers on linear, spherical, and Gaussian-mixture token distributions, and that one attention step equals one gradient step on a context-aware dense associative memory energy.

Problem

Understanding how transformer attention relates to dense associative memory (modern Hopfield) networks beyond exact retrieval, and whether in-context learning can solve unsupervised denoising tasks with few layers.

Approach

Frame denoising of a query given L clean context tokens drawn from a random task distribution as in-context learning; derive Bayes-optimal posterior-mean denoisers for linear manifolds, spheres, and clusters, show one-layer attention matches them, and interpret the attention step as one gradient-descent step on a context-dependent DAM energy with the query as initial state.

Key results

Measured effects reported in the paper

What was changedWhereMeasuredEffect
Increase context length (ablation)One-layer attention denoiser · Linear manifoldsMSEHelped
Use softmax attention instead of linear attention (ablation)One-layer denoiser · Linear manifoldsMSENo clear effect
Evaluate on subspace dimensions different from the training dimension d=8 (ablation)Linear attention denoiser trained on random d=8 subspaces · Linear manifolds; inference-time dimension shiftdenoising performanceHurt
Iterate the denoising update instead of taking one step (ablation)Attention-derived dense associative memory · Nonlinear manifold denoisingdenoising performanceHurt

Surprising findings

Limitations

Experimental setup

Datasets: synthetic linear manifold tokens synthetic sphere tokens synthetic Gaussian mixture tokens

Benchmarks: synthetic in-context denoising tasks (linear, sphere, Gaussian mixture)

Metrics: mean squared error comparison to Bayes optimal MSE

Baselines: Bayes optimal denoiser zero predictor linear attention

Builds on: Ramsauer et al. hopfield is all you need linear transformers emulate gradient descent mimetic initialization

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