Add a loader generator task.

Related to #360.