From 70affd580a555856188fe296ae307329810f433f Mon Sep 17 00:00:00 2001 From: david-cortes Date: Wed, 27 Dec 2023 19:19:05 +0100 Subject: [PATCH] improve wording on compatibility note --- R-package/R/utils.R | 8 ++++---- R-package/man/a-compatibility-note-for-saveRDS-save.Rd | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/R-package/R/utils.R b/R-package/R/utils.R index e0683b84555a..75cc3a75e2b5 100644 --- a/R-package/R/utils.R +++ b/R-package/R/utils.R @@ -360,10 +360,10 @@ NULL #' accessible in later releases of XGBoost. To ensure that your model can be accessed in future #' releases of XGBoost, use \code{\link{xgb.save}} or \code{\link{xgb.save.raw}} instead. #' -#' Currently, it is not possible to use R serializers like `readRDS` to load an XGBoost. model -#' saved with an XGBoost. version lower than 2.1.0, and it's not possible to load an XGBoost. model -#' saved with R serializers like `readRDS` under XGBoost. version 2.1.0 when using an older version -#' of XGBoost. +#' Note that XGBoost models in R starting from version `2.1.0` and onwards, and XGBoost models +#' before version `2.1.0`; have a very different R object structure and are incompatible with +#' each other. Hence, models that were saved with R serializers live `saveRDS` or `save` before +#' version `2.1.0` will not work with latter `xgboost` versions and vice versa. #' #' Furthermore, note that using the package `qs` for serialization will require version 0.26 or #' higher of said package, and will have the same compatibility restrictions as R serializers. diff --git a/R-package/man/a-compatibility-note-for-saveRDS-save.Rd b/R-package/man/a-compatibility-note-for-saveRDS-save.Rd index 9b1bddeba4e3..705f504af57a 100644 --- a/R-package/man/a-compatibility-note-for-saveRDS-save.Rd +++ b/R-package/man/a-compatibility-note-for-saveRDS-save.Rd @@ -14,10 +14,10 @@ accessible in later releases of XGBoost. To ensure that your model can be access releases of XGBoost, use \code{\link{xgb.save}} or \code{\link{xgb.save.raw}} instead. } \details{ -Currently, it is not possible to use R serializers like \code{readRDS} to load an XGBoost. model -saved with an XGBoost. version lower than 2.1.0, and it's not possible to load an XGBoost. model -saved with R serializers like \code{readRDS} under XGBoost. version 2.1.0 when using an older version -of XGBoost. +Note that XGBoost models in R starting from version \verb{2.1.0} and onwards, and XGBoost models +before version \verb{2.1.0}; have a very different R object structure and are incompatible with +each other. Hence, models that were saved with R serializers live \code{saveRDS} or \code{save} before +version \verb{2.1.0} will not work with latter \code{xgboost} versions and vice versa. Furthermore, note that using the package \code{qs} for serialization will require version 0.26 or higher of said package, and will have the same compatibility restrictions as R serializers.