Tweaked generate example