extract patterns to utils