Batching examples to improve client side performance