AI could be a disaster for humanity. A top computer scientist thinks he has the solution.