Back when I worked as an art director at New York Magazine, I made a few gif animations for different text generators. Basically, there was a huge list of phrases in a json file and one would get displayed at random whenever the button was clicked.
This one was created for the final season of 30 Rock. The gif animation was a bit crude on purpose making Jack Donaghy (Alec Baldwin) look more like a puppet.
Did some digging and found the original article here!