(#192) - WIP - make the batch size configurable

Needs a perf test to confirm that a batch size of 500 is better than 50, and that it doesn't cause OOMs in the average use case.