Consistency of random-walk based network embedding algorithms