Efficient and Minimax-optimal In-context Nonparametric Regression with Transformers

Michelle Ching, Ioana Popescu, Nico Smith, Tianyi Ma, William G. Underwood +1 more
1/21/2026
stat.MLcs.LGmath.ST
transformer-attention

No confident code implementation found for this paper.

Abstract

We study in-context learning for nonparametric regression with $α$-Hölder smooth regression functions, for some $α>0$. We prove that, with $n$ in-context examples and $d$-dimensional regression covariates, a pretrained transformer with $Θ(\log n)$ parameters and $Ω\bigl(n^{2α/(2α+d)}\log^3 n\bigr)$ pretraining sequences can achieve the minimax-optimal rate of convergence $O\bigl(n^{-2α/(2α+d)}\bigr)$ in mean squared error.

Show full abstract

Our result requires substantially fewer transformer parameters and pretraining sequences than previous results in the literature. This is achieved by showing that transformers are able to approximate local polynomial estimators efficiently by implementing a kernel-weighted polynomial basis and then running gradient descent.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{ching2026efficient,
  title  = {Efficient and Minimax-optimal In-context Nonparametric Regression with Transformers},
  author = {Michelle Ching and Ioana Popescu and Nico Smith and Tianyi Ma and William G. Underwood and Richard J. Samworth},
  year   = {2026},
  eprint = {2601.15014},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2601.15014v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2601.15014.svg)](https://codeofpaper.com/paper/2601.15014)

Discussion