Added constructor param to specify max corpus size.