COLING 2025main1 citations

Position Information Emerges in Causal Transformers Without Positional Encodings via Similarity of Nearby Embeddings

Chunsheng Zuo, Pavel Guerzhoy, Michael Guerzhoy

Abstract

Transformers with causal attention can solve tasks that require positional information without using positional encodings. In this work, we propose and investigate a new hypothesis about how positional information can be stored without using explicit positional encoding. We observe that nearby embeddings are more similar to each other than faraway embeddings, allowing the transformer to potentially reconstruct the positions of tokens. We show that this pattern can occur in both the trained and the randomly initialized Transformer models with causal attention and no positional encodings over a common range of hyperparameters.

BibTeX
@inproceedings{zuo-etal-2025-position,
    title = "Position Information Emerges in Causal Transformers Without Positional Encodings via Similarity of Nearby Embeddings",
    author = "Zuo, Chunsheng  and
      Guerzhoy, Pavel  and
      Guerzhoy, Michael",
    editor = "Rambow, Owen  and
      Wanner, Leo  and
      Apidianaki, Marianna  and
      Al-Khalifa, Hend  and
      Eugenio, Barbara Di  and
      Schockaert, Steven",
    booktitle = "Proceedings of the 31st International Conference on Computational Linguistics",
    month = jan,
    year = "2025",
    address = "Abu Dhabi, UAE",
    publisher = "Association for Computational Linguistics",
    url = "https://aclanthology.org/2025.coling-main.632/",
    pages = "9418--9430"
}
Position Information Emerges in Causal Transformers Without Positional Encodings via Similarity of Nearby Embeddings · COLING 2025