Extract most of the transformation into an externally accessible