← Glossary

attention mechanism

The part of a transformer that decides which earlier tokens matter for the token being produced now. Its cost grows with the square of the context, which is why long contexts are expensive.

ai 1 video 1 mention also: self-attention

Where it comes up