Do Transformers Use their Depth Adaptively? Evidence from a Relational Reasoning Task

Alicia Curth, Rachel Lawrence, Sushrut Karmalkar, Niranjani Prasad
4/14/2026
cs.LGcs.CL
transformer-attention

No confident code implementation found for this paper.

Abstract

We investigate whether transformers use their depth adaptively across tasks of increasing difficulty. Using a controlled multi-hop relational reasoning task based on family stories, where difficulty is determined by the number of relationship hops that must be composed, we monitor (i) how predictions evolve across layers via early readouts (the logit lens) and (ii) how task-relevant information is integrated across tokens via causal patching.

Show full abstract

For pretrained models, we find some limited evidence for adaptive depth use: some larger models need fewer layers to arrive at plausible answers for easier tasks, and models generally use more layers to integrate information across tokens as chain length increases. For models finetuned on the task, we find clearer and more consistent evidence of adaptive depth use, with the effect being stronger for less constrained finetuning regimes that do not preserve general language modeling abilities.

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{curth2026transformers,
  title  = {Do Transformers Use their Depth Adaptively? Evidence from a Relational Reasoning Task},
  author = {Alicia Curth and Rachel Lawrence and Sushrut Karmalkar and Niranjani Prasad},
  year   = {2026},
  eprint = {2604.12426},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2604.12426v1}
}

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/2604.12426.svg)](https://codeofpaper.com/paper/2604.12426)

Discussion