Completed compression API refactoring