Template for Ruby batch processing