NeurIPS 2026QuestionsPapersAreasAboutMarkdown

Position Without Positional Embeddings: A Directional Mechanism in NoPE Transformers

Matan Avitan, Ido Nachum, Yanai Elazar, Yoav Goldberg

NeurIPS page · OpenReview · Open on the map

Category: Interpretability & Model Adaptation › Transformer In-Context Reasoning · Type: new method · Keywords: positional embeddings, directional encoding, transformer architecture, sequence order

Areas: Model Architectures & Sequence Modeling › Language Model Architectures › Attention Geometry

Summary

The paper introduces a directional mechanism in NoPE transformers that recovers absolute position without positional embeddings, using a compact two-layer design where prefix averaging and attention mixing encode position in direction.

Explained to a 5-year-old

Computers need to know the order of words. Usually they add special marks for each word's position. This paper shows a way to know order without those marks. It uses a trick where the direction of signals changes as words appear. By looking at these directions, the computer can figure out which word comes first, second, and so on.

Explained to a 5-year-old, longer

Transformers are computer programs that read sequences of words. They need to understand which word comes before another. Usually they attach a special number to each word to remember its place. Adding these numbers uses extra memory and can be complicated. This paper finds a way to keep track of order without those numbers. It works by making the signals point in different directions depending on where the word appears. The first layer of the model creates a shared direction that starts the sequence. The second layer splits this direction into two parts and mixes them based on the word's position. By watching how the direction changes, the model can read off the exact position of each word. This directional trick is simple and uses less extra information than before. The researchers also show that two different versions of the model end up using the same trick. This discovery could help build smaller, more efficient language models in the future.

For a technical reader

The paper shows that transformers can infer absolute token positions without adding explicit positional embeddings, which are normally used to encode order. It does this by encoding position in the direction of internal signals rather than their magnitude, using a two-layer architecture where the first layer creates a shared directional component and the second layer mixes two directional vectors based on a position-dependent attention weight. This directional mechanism is compact, linearly decodable, and can be instantiated by two different model variants that converge to the same underlying principle when trained to predict position. The result is a simpler, parameter-efficient way to preserve sequence order that could reduce overhead in future models. By removing the need for positional embeddings, the approach may simplify model design and improve efficiency on devices with limited memory.

Problem

How can autoregressive transformers infer absolute token positions without using explicit positional embeddings?

Method

The approach uses a two-layer transformer where the first layer creates a shared directional component via prefix averaging, and the second layer’s attention output-value matrix maps contributions into distinct directions, mixing them with a position-dependent weight to produce a directional trajectory that can be linearly decoded for position.

Results

The approach successfully extracts absolute position using a directional mechanism and demonstrates that two variants converge to the same underlying principle when trained to predict position.

Contributions

The paper identifies that position can be encoded in direction rather than magnitude, proposes a compact two-layer transformer mechanism achieving this, and shows that multiple variants converge to the same theoretical mechanism.

This page was written by language models from the title and abstract of each paper, and the answers were checked by two other models. It can be wrong: check the paper itself. Suggest a correction