Added pagination. Fixed generate to include tip.