After a little more reading: I guess this can all be done in MediaLab using the d parameter with a .que file.