How do sparse attention patterns that combine local windows with global tokens preserve long-range information?
Last updated
Local sliding windows let each token attend to nearby neighbors cheaply (O(n·w)), while a few global tokens (e.g. [CLS]) attend to and are attended by every position, acting as hubs.
Any two distant tokens connect in at most two hops (token → global → token), and stacking layers spreads information across the whole sequence at roughly linear cost. Random or dilated links (BigBird, Longformer) shorten paths further.
Limitation: the global hub is a bottleneck, so fine-grained long-range retrieval (e.g. copying a specific distant token) can be weaker than with full attention.