refactored outputs to services