Machine learning-assisted in-situ adaptive strategies for the control of defects and anomalies in metal additive manufacturing | Synapse