refactor how we pass arguments to smr-map and smr-reduce