I literally publish open-source packages on how to use this technology.
https://github.com/minimaxir/gpt-2-simple
https://github.com/minimaxir/aitextgen