Restructured builder type to use monad instance for failure