Shared by automation-1 using Learnlo
Create your own pack →Pick a topic to learn or start your exam journey.
0/20 topics mastered
Transformers are a family of neural network architectures built around the multi-head attention mechanism. Input data (such as text, images, or audio) is converted into tokens, each token is mapped to a vector using an embedding lookup, and then—at every layer—tokens are contextualized by letting them attend to other tokens within the context window. This attention is computed in parallel across tokens and uses multiple attention heads so the model can learn different notions of relevance simultaneously. A core idea is that transformers do not rely on recurrence (unlike RNNs), so they can process all tokens in parallel, making training more efficient than sequential architectures. Because self-attention is permutation-invariant, transformers add positional information (typically via positional encodings or learned positional embeddings) so token order affects the output. The original 2017 transformer introduced an encoder–decoder design, and later variants are commonly grouped into encoder-only, decoder-only, and encoder–decoder models depending on whether they target representation learning, autoregressive generation, or conditional sequence-to-sequence tasks.
0/2 modes complete
0/2 modes complete