The Casson-Maxwell model is particularly useful for studying viscoplastic fluids or fluids with yield stress, making it applicable to various engineering applications, including extrusion processes, coating applications, and biomedical fluid dynamics. Casson-Maxwell fluid flow enhances mass transfer rates due to the combined effects of non-Newtonian viscosity and viscoelastic behavior. This is particularly useful in processes where mass transfer limitations play a significant role, such as in multiphase reactions or reactive distillation systems. In the context of the above applications the present model, is the combination of Casson- Maxwell fluids that flow through the varying gap of the spinning cone and disk system (CDS) for the heat transfer enhancement. The magnetic field is also imposed in the upright direction to the flow field. The solution of the transform equations has been obtained through artificial neural networks (ANN). The skin friction, heat transfer rate, and comparative analysis have been done. The Casson-Maxwell parameters that depend on the viscoelastic behavior and high viscosity term, causes the fluid to slow down and tends to store the temperature, for a long time as compared to traditional fluids. The radial component of velocity decreases due to the increase in magnetic field. The relative error of the reference and targeted dates is calculated to demonstrate the best precision efficiency of ANN, with a range of 10−3 to 10−4.