updating batch example to use required prameters