trainer-api using task-manager. WIP, WARNING - untested!