modify the mapreduce procedures