Refactor o, moving the bulk of the codebase into a _transform.js helper.
Refactor a to match new o.