How to generate text: using different decoding methods for language generation with Transformers Note: Edited on July 2023 with up-to-date references and examples. Introduction In recent years, there has been an increasing interest in open-ended language generation thanks to the rise of large transformer-based language models trained on millions of webpages, including OpenAI's ChatGPT and Meta's L
![How to generate text: using different decoding methods for language generation with Transformers](https://cdn-ak-scissors.b.st-hatena.com/image/square/fb86c79dc281a8171567cb411446777699ba1ea8/height=288;version=1;width=512/https%3A%2F%2Fhuggingface.co%2Fblog%2Fassets%2F02_how-to-generate%2Fthumbnail.png)