AI-enhanced segmentation and automation flows