Separating workflow function.