AI-driven Optimization in Healthcare: the Diagnostic Process