cs.CLAug 18, 2026

Do Large Language Models Play Six Degrees of Separation? Measuring Topological Compression in Long-Context Manifolds

Authors: Md. Faiyaz Abdullah Sayeedi

Organizations: BRAC University, Bangladesh

Abstract

Large Language Models (LLMs) demonstrate remarkable multi-hop reasoning capabilities over long contexts, yet the internal mechanisms enabling these distant cognitive leaps remain poorly understood. Traditional attention-based interpretability often fails to capture true semantic proximity due to routing artifacts like attention sinks. In this paper, we bypass attention weights to directly analyze the dynamic geometry of the hidden state manifold, proving that deep LLM latent spaces natively organize into Small-World networks. By sparsifying the continuous similarity matrices of long-context representations into unweighted graphs, we trace the connectivity between highly disjoint semantic anchors across two distinct architectures. Our findings reveal a sharp topological phase transition: while early syntactic layers remain entirely fractured, deep reasoning layers abruptly compress massive conceptual distances into highly navigable pathways strictly bounded by the "Six Degrees of Separation" limit (=< 6 semantic hops). Furthermore, we demonstrate the practical efficacy of this framework by applying it to zero-shot hallucination detection within Retrieval-Augmented Generation (RAG) using the RAGognize dataset. We show that factually grounded generations maintain structural integrity with their source context (approximately 3 hops), whereas hallucinations induce severe topological collapse. Ultimately, this work mathematically formalizes how transformers execute abstract reasoning and provides a novel, strictly geometric signature for evaluating factual reliability.

Figures & tables

Appendix figures & tables1 asset

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. Truth as a Trajectory: What Internal Representations Reveal About Large Language Model Reasoning

    Mar 1, 2026Hamed Damirchi, Ignacio Meza De la Jara, Ehsan Abbasnejad +3LLM InterpretabilityRepresentation Geometry in Language Models

  2. When Do Hallucinations Arise? A Graph Perspective on the Evolution of Path Reuse and Path Compression

    Apr 4, 2026Xinnan Dai, Kai Yang, Cheng Luo +3Hallucination in Language ModelsKnowledge Conflicts in Language Models

  3. Geometric Latent Reasoning Induces Shorter Generations in LLMs

    Jun 1, 2026Shashi Kumar, Yacouba Kaloga, Petr Motlicek +2Efficient Language Model ReasoningContinuous Latent Reasoning