LLM-Microscope: Uncovering the Hidden Role of Punctuation in Context Memory of Transformers

Fuente: arXiv
Enregistré dans:
Détails bibliographiques
Auteurs principaux: Razzhigaev, Anton, Mikhalchuk, Matvey, Rahmatullaev, Temurbek, Goncharova, Elizaveta, Druzhinina, Polina, Oseledets, Ivan, Kuznetsov, Andrey
Format: Preprint
Publié: 2025
Sujets:
Accès en ligne:
Tags: Ajouter un tag
Pas de tags, Soyez le premier à ajouter un tag!
_version_ 1866929723720859648
author Razzhigaev, Anton
Mikhalchuk, Matvey
Rahmatullaev, Temurbek
Goncharova, Elizaveta
Druzhinina, Polina
Oseledets, Ivan
Kuznetsov, Andrey
author_facet Razzhigaev, Anton
Mikhalchuk, Matvey
Rahmatullaev, Temurbek
Goncharova, Elizaveta
Druzhinina, Polina
Oseledets, Ivan
Kuznetsov, Andrey
contents We introduce methods to quantify how Large Language Models (LLMs) encode and store contextual information, revealing that tokens often seen as minor (e.g., determiners, punctuation) carry surprisingly high context. Notably, removing these tokens -- especially stopwords, articles, and commas -- consistently degrades performance on MMLU and BABILong-4k, even if removing only irrelevant tokens. Our analysis also shows a strong correlation between contextualization and linearity, where linearity measures how closely the transformation from one layer's embeddings to the next can be approximated by a single linear mapping. These findings underscore the hidden importance of filler tokens in maintaining context. For further exploration, we present LLM-Microscope, an open-source toolkit that assesses token-level nonlinearity, evaluates contextual memory, visualizes intermediate layer contributions (via an adapted Logit Lens), and measures the intrinsic dimensionality of representations. This toolkit illuminates how seemingly trivial tokens can be critical for long-range understanding.
format Preprint
id arxiv_https___arxiv_org_abs_2502_15007
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle LLM-Microscope: Uncovering the Hidden Role of Punctuation in Context Memory of Transformers
Razzhigaev, Anton
Mikhalchuk, Matvey
Rahmatullaev, Temurbek
Goncharova, Elizaveta
Druzhinina, Polina
Oseledets, Ivan
Kuznetsov, Andrey
Computation and Language
Artificial Intelligence
We introduce methods to quantify how Large Language Models (LLMs) encode and store contextual information, revealing that tokens often seen as minor (e.g., determiners, punctuation) carry surprisingly high context. Notably, removing these tokens -- especially stopwords, articles, and commas -- consistently degrades performance on MMLU and BABILong-4k, even if removing only irrelevant tokens. Our analysis also shows a strong correlation between contextualization and linearity, where linearity measures how closely the transformation from one layer's embeddings to the next can be approximated by a single linear mapping. These findings underscore the hidden importance of filler tokens in maintaining context. For further exploration, we present LLM-Microscope, an open-source toolkit that assesses token-level nonlinearity, evaluates contextual memory, visualizes intermediate layer contributions (via an adapted Logit Lens), and measures the intrinsic dimensionality of representations. This toolkit illuminates how seemingly trivial tokens can be critical for long-range understanding.
title LLM-Microscope: Uncovering the Hidden Role of Punctuation in Context Memory of Transformers
topic Computation and Language
Artificial Intelligence
url https://arxiv.org/abs/2502.15007