Difference between xgboost_ray and XGBoostTrainer?

What’s the difference? Which one to use?

XGBoostTrainer uses xgboost_ray underneath and provides a Ray AIR-compatible API. If you are a new user, using XGBoostTrainer over xgboost_ray is recommended. That being said, xgboost_ray supports some extra data formats and elastic training, while those features are not yet present in XGBoostTrainer API.