WIP operation refactoring using partial algebras.