Tofu is an image processing system developed by COOKPAD that generates thumbnail images on demand from original images stored in S3. Previously, COOKPAD would generate all thumbnail sizes upfront, using significant storage. Tofu addresses this by using a Apache module called mod_tofu that generates thumbnails from original images only when requested. This on-demand approach is faster, more scalabl