Short answer
A transformer is a deep learning architecture built around attention. It powers most large language models and many image and audio systems.
Why it matters
Diagram
Article
Architecture sketch
Vaswani et al. (2017) introduced multi-head self-attention, positional information, and stacked feed-forward blocks. Encoders build bidirectional representations; decoders generate autoregressively; encoder–decoder models suit sequence-to-sequence tasks.
Residual connections and layer normalization stabilize deep stacks, enabling large-scale training.
Why they won
Better parallelization than recurrent nets on modern accelerators, plus strong long-range dependency modeling, made transformers the default backbone for NLP and beyond.
Examples
Chat completion
Translation
FAQ
Are all LLMs transformers?
Do transformers only work on text?
Sources
-
Attention Is All You Need
NeurIPS / arXivFoundational transformer architecture paper.
-
Deep Learning
MIT PressCanonical deep learning textbook by Goodfellow, Bengio, and Courville.
-
BERT: Pre-training of Deep Bidirectional Transformers for Language Understanding
NAACL / arXivBERT pretraining paper.
-
Hugging Face Documentation
Hugging FaceOpen model hub and Transformers library docs.