Table of Contents
Fetching ...

Layer-Order Inversion: Rethinking Latent Multi-Hop Reasoning in Large Language Models

Xukai Liu, Ye Liu, Jipeng Zhang, Yanghai Zhang, Kai Zhang, Qi Liu

TL;DR

The paper challenges the widely cited hop-aligned circuit view of latent multi-hop reasoning in LLMs by identifying layer-order inversion, where later-hop entities become decodable earlier than bridge entities. It proposes a probabilistic recall-and-extract framework in which shallow MLPs perform probabilistic recall and deeper attention extracts the final answer, explaining both observed layer patterns and chain-of-thought gains. It validates these ideas with systematic Patchscopes probing and hidden-state analyses on the MQuAKE benchmark across up to four-hop queries, connecting prior circuit-like observations to probabilistic recall dynamics. The work provides new insights into internal knowledge recall and extraction, with implications for model editing and interventions aimed at improving robust multi-hop reasoning in LLMs.

Abstract

Large language models (LLMs) perform well on multi-hop reasoning, yet how they internally compose multiple facts remains unclear. Recent work proposes \emph{hop-aligned circuit hypothesis}, suggesting that bridge entities are computed sequentially across layers before later-hop answers. Through systematic analyses on real-world multi-hop queries, we show that this hop-aligned assumption does not generalize: later-hop answer entities can become decodable earlier than bridge entities, a phenomenon we call \emph{layer-order inversion}, which strengthens with total hops. To explain this behavior, we propose a \emph{probabilistic recall-and-extract} framework that models multi-hop reasoning as broad probabilistic recall in shallow MLP layers followed by selective extraction in deeper attention layers. This framework is empirically validated through systematic probing analyses, reinterpreting prior layer-wise decoding evidence, explaining chain-of-thought gains, and providing a mechanistic diagnosis of multi-hop failures despite correct single-hop knowledge. Code is available at https://github.com/laquabe/Layer-Order-Inversion.

Layer-Order Inversion: Rethinking Latent Multi-Hop Reasoning in Large Language Models

TL;DR

The paper challenges the widely cited hop-aligned circuit view of latent multi-hop reasoning in LLMs by identifying layer-order inversion, where later-hop entities become decodable earlier than bridge entities. It proposes a probabilistic recall-and-extract framework in which shallow MLPs perform probabilistic recall and deeper attention extracts the final answer, explaining both observed layer patterns and chain-of-thought gains. It validates these ideas with systematic Patchscopes probing and hidden-state analyses on the MQuAKE benchmark across up to four-hop queries, connecting prior circuit-like observations to probabilistic recall dynamics. The work provides new insights into internal knowledge recall and extraction, with implications for model editing and interventions aimed at improving robust multi-hop reasoning in LLMs.

Abstract

Large language models (LLMs) perform well on multi-hop reasoning, yet how they internally compose multiple facts remains unclear. Recent work proposes \emph{hop-aligned circuit hypothesis}, suggesting that bridge entities are computed sequentially across layers before later-hop answers. Through systematic analyses on real-world multi-hop queries, we show that this hop-aligned assumption does not generalize: later-hop answer entities can become decodable earlier than bridge entities, a phenomenon we call \emph{layer-order inversion}, which strengthens with total hops. To explain this behavior, we propose a \emph{probabilistic recall-and-extract} framework that models multi-hop reasoning as broad probabilistic recall in shallow MLP layers followed by selective extraction in deeper attention layers. This framework is empirically validated through systematic probing analyses, reinterpreting prior layer-wise decoding evidence, explaining chain-of-thought gains, and providing a mechanistic diagnosis of multi-hop failures despite correct single-hop knowledge. Code is available at https://github.com/laquabe/Layer-Order-Inversion.
Paper Structure (41 sections, 5 equations, 18 figures, 4 tables)

This paper contains 41 sections, 5 equations, 18 figures, 4 tables.

Figures (18)

  • Figure 1: An illustration of latent multi-hop reasoning in LLMs. The layer-order inversion contradicts hop-aligned circuits, while our probabilistic recall-and-extract framework allows direct recall of answer entities without explicit bridge entities.
  • Figure 2: An illustration of latent multi-hop reasoning in LLMs from a probabilistic perspective. (a) Electron behavior follows a probabilistic distribution rather than fixed orbits. (b) Hop-aligned circuit hypothesis assumes layer-by-layer recall of bridge entities. (c) Observed layer-order inversion, where later-hop entities may emerge earlier than bridge entities. (d) Probabilistic recall-and-extract framework combining vertical and horizontal recall, where the final answer entity need not strictly depend on the explicit generation of bridge entities.
  • Figure 3: Patchscopes results for GPT-J (left) and Llama3 (right) on the Correct subset. We probe hidden states at the last subject token (top) and the last token of the query (bottom) under three settings: raw, 90% gf, and 90% lf.
  • Figure 4: Layer-wise generation distributions produced by Patchscopes on the Correct subset.
  • Figure 5: Nomarlized similarity of mlp_fc_in at the subject between multi-hop queries and their single-hop queries.
  • ...and 13 more figures