# GPT: generative pre-training

Date: 11 June 2018 · Era: V · Transformers · Category: model · Significance: 4/5
People: Alec Radford, Karthik Narasimhan, Tim Salimans, Ilya Sutskever
Organisations: OpenAI

Canonical: https://shapeofintelligence.com/timeline/2018-gpt-1/ · Dataset and text CC BY 4.0

> OpenAI pre-trains a twelve-layer transformer decoder to predict the next word in 7,000 books, then fine-tunes it; one model tops nine language benchmarks.

## What had to happen

30 events back to 1943, oldest first. Direct influences are marked *direct*.

- [1943 · A logical calculus of nervous activity](https://shapeofintelligence.com/md/timeline/1943-mcculloch-pitts-neuron/)
- [1949 · Cells that fire together wire together](https://shapeofintelligence.com/md/timeline/1949-hebb-organization-of-behavior/)
- [1958 · The perceptron learns](https://shapeofintelligence.com/md/timeline/1958-perceptron/)
- [1960 · ADALINE and the least-mean-squares rule](https://shapeofintelligence.com/md/timeline/1960-adaline-lms/)
- [1965 · Moore's law](https://shapeofintelligence.com/md/timeline/1965-moores-law/)
- [1969 · Perceptrons](https://shapeofintelligence.com/md/timeline/1969-perceptrons-book/)
- [1970 · Reverse-mode automatic differentiation](https://shapeofintelligence.com/md/timeline/1970-linnainmaa-backprop/)
- [1974 · Werbos applies backpropagation to neural networks](https://shapeofintelligence.com/md/timeline/1974-werbos-backprop/)
- [1980 · The Neocognitron](https://shapeofintelligence.com/md/timeline/1980-neocognitron/)
- [1982 · The Hopfield network](https://shapeofintelligence.com/md/timeline/1982-hopfield-network/)
- [1985 · The Boltzmann machine](https://shapeofintelligence.com/md/timeline/1985-boltzmann-machine/)
- [1986 · Backpropagation](https://shapeofintelligence.com/md/timeline/1986-backpropagation/)
- [1989 · LeNet reads handwritten postcodes](https://shapeofintelligence.com/md/timeline/1989-lenet/)
- [1990 · Finding structure in time](https://shapeofintelligence.com/md/timeline/1990-elman-network/)
- [1991 · The vanishing gradient problem](https://shapeofintelligence.com/md/timeline/1991-vanishing-gradient/)
- [1997 · Long short-term memory](https://shapeofintelligence.com/md/timeline/1997-lstm/)
- [1998 · MNIST and LeNet-5](https://shapeofintelligence.com/md/timeline/1998-mnist-lenet5/)
- [1999 · The first GPU](https://shapeofintelligence.com/md/timeline/1999-geforce-256/)
- [2003 · A neural probabilistic language model](https://shapeofintelligence.com/md/timeline/2003-neural-language-model/) *direct*
- [2006 · Deep belief networks and the word 'deep'](https://shapeofintelligence.com/md/timeline/2006-deep-belief-nets/)
- [2007 · CUDA](https://shapeofintelligence.com/md/timeline/2007-cuda/)
- [2009 · ImageNet](https://shapeofintelligence.com/md/timeline/2009-imagenet/)
- [2010 · Rectified linear units](https://shapeofintelligence.com/md/timeline/2010-relu/)
- [2012 · Dropout](https://shapeofintelligence.com/md/timeline/2012-dropout/)
- [2012 · AlexNet wins ImageNet](https://shapeofintelligence.com/md/timeline/2012-alexnet/)
- [2014 · Attention](https://shapeofintelligence.com/md/timeline/2014-bahdanau-attention/)
- [2014 · Sequence to sequence learning](https://shapeofintelligence.com/md/timeline/2014-seq2seq/)
- [2015 · Batch normalisation](https://shapeofintelligence.com/md/timeline/2015-batchnorm/)
- [2015 · Residual networks](https://shapeofintelligence.com/md/timeline/2015-resnet/)
- [2017 · Attention is all you need](https://shapeofintelligence.com/md/timeline/2017-attention-is-all-you-need/) *direct*

The recipe that produced every later GPT is in a paper OpenAI posted on 11 June 2018 with little fanfare. Take the decoder half of the transformer, twelve layers and 117 million parameters. Train it on the BooksCorpus, 7,000 unpublished novels, to predict each word from the ones before it, a task that needs no labels and for which the world's text is the dataset. Then fine-tune the same network briefly on each downstream task, question answering, textual entailment, sentence similarity, and it beats the specialised models on nine of twelve benchmarks.

The result confirmed what Elman had seen in miniature in 1990: predicting the next word forces a model to learn grammar, facts and reasoning as by-products. Alec Radford's paper made pre-training on raw text the foundation of natural-language processing, and it made the objective, next-token prediction, the one that would be scaled for the next eight years.

Google's BERT, four months later, used the encoder half and a fill-in-the-blank objective and was for a while the more influential of the two. But BERT could not generate text, and GPT could, and generation is what the public eventually got.

## What it led to

50 events downstream, through 2026.

Built on it directly:

- [2018 · BERT](https://shapeofintelligence.com/md/timeline/2018-bert/)
- [2019 · GPT-2 and the model too dangerous to release](https://shapeofintelligence.com/md/timeline/2019-gpt-2/)

And, through them, by era:

- V · Transformers: 7 events
- VI · Everyone: 27 events
- VII · Agents: 14 events

## Sources

- [Improving Language Understanding with Unsupervised Learning (OpenAI, 11 June 2018)](https://openai.com/index/language-unsupervised/) — announcement
- [Improving Language Understanding by Generative Pre-Training (paper)](https://cdn.openai.com/research-covers/language-unsupervised/language_understanding_paper.pdf) — paper

---

The Shape of Intelligence by Jamie McKaye (https://jamiemckaye.com) · Markdown mirror of https://shapeofintelligence.com/timeline/2018-gpt-1/

Before: [2017 · AlphaGo Zero learns from nothing](https://shapeofintelligence.com/md/timeline/2017-alphago-zero/) · After: [2018 · BERT](https://shapeofintelligence.com/md/timeline/2018-bert/)
