setup factory to transform data