How do I randomize the location where an AI is chasing the player?

So, for example get the locations and make them closer to the player.