Foundation models for robust machine learning