Refactored to use the new chanchero framework for task based computing.