Persistent Topological Features in Large Language Models
Yuri Gardinazzi, Karthik Viswanathan, Giada Panerai, Alessio Ansuini, Alberto Cazzaniga, Matteo Biagetti

TL;DR
This paper introduces a topological data analysis framework using zigzag persistence to analyze and interpret the internal representations of large language models, providing new insights into their decision-making processes.
Contribution
It develops a novel application of zigzag persistence to track topological features across model layers, offering a system-level perspective on language model representations.
Findings
Descriptors are sensitive to different models and datasets.
The framework can inform layer pruning with competitive results.
Provides a new statistical view of prompt transformations.
Abstract
Understanding the decision-making processes of large language models is critical given their widespread applications. To achieve this, we aim to connect a formal mathematical framework - zigzag persistence from topological data analysis - with practical and easily applicable algorithms. Zigzag persistence is particularly effective for characterizing data as it dynamically transforms across model layers. Within this framework, we introduce topological descriptors that measure how topological features, -dimensional holes, persist and evolve throughout the layers. Unlike methods that assess each layer individually and then aggregate the results, our approach directly tracks the full evolutionary path of these features. This offers a statistical perspective on how prompts are rearranged and their relative positions changed in the representation space, providing insights into the system's…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Code & Models
Videos
Taxonomy
TopicsTopic Modeling · Advanced Graph Neural Networks
