How language models work

What happens inside the systems that read and write text, from words as numbers to the machinery that predicts what comes next.