Moving random functions into their own module