Fix Marc gen, add count key task