Refactor corpus size and ping to their own methods.