@elaraai/east-py-datascience 0.0.2-beta.6 → 0.0.2-beta.61
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/alns/alns.d.ts +528 -0
- package/dist/alns/alns.d.ts.map +1 -0
- package/dist/alns/alns.js +238 -0
- package/dist/alns/alns.js.map +1 -0
- package/dist/gp/gp.d.ts +120 -120
- package/dist/gp/gp.d.ts.map +1 -1
- package/dist/gp/gp.js +7 -7
- package/dist/gp/gp.js.map +1 -1
- package/dist/index.d.ts +5 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -2
- package/dist/index.js.map +1 -1
- package/dist/lightgbm/lightgbm.d.ts +168 -168
- package/dist/lightning/lightning.d.ts +1501 -0
- package/dist/lightning/lightning.d.ts.map +1 -0
- package/dist/lightning/lightning.js +376 -0
- package/dist/lightning/lightning.js.map +1 -0
- package/dist/mads/mads.d.ts +103 -103
- package/dist/mads/mads.d.ts.map +1 -1
- package/dist/mads/mads.js +5 -5
- package/dist/mads/mads.js.map +1 -1
- package/dist/mapie/mapie.d.ts +2058 -0
- package/dist/mapie/mapie.d.ts.map +1 -0
- package/dist/mapie/mapie.js +411 -0
- package/dist/mapie/mapie.js.map +1 -0
- package/dist/ngboost/ngboost.d.ts +126 -126
- package/dist/ngboost/ngboost.d.ts.map +1 -1
- package/dist/ngboost/ngboost.js +3 -3
- package/dist/ngboost/ngboost.js.map +1 -1
- package/dist/optuna/optuna.d.ts +314 -314
- package/dist/scipy/scipy.d.ts +535 -429
- package/dist/scipy/scipy.d.ts.map +1 -1
- package/dist/scipy/scipy.js +56 -3
- package/dist/scipy/scipy.js.map +1 -1
- package/dist/shap/shap.d.ts +1152 -358
- package/dist/shap/shap.d.ts.map +1 -1
- package/dist/shap/shap.js +189 -16
- package/dist/shap/shap.js.map +1 -1
- package/dist/simanneal/simanneal.d.ts +148 -148
- package/dist/sklearn/sklearn.d.ts +3104 -1316
- package/dist/sklearn/sklearn.d.ts.map +1 -1
- package/dist/sklearn/sklearn.js +325 -64
- package/dist/sklearn/sklearn.js.map +1 -1
- package/dist/torch/torch.d.ts +503 -350
- package/dist/torch/torch.d.ts.map +1 -1
- package/dist/torch/torch.js +39 -17
- package/dist/torch/torch.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/xgboost/xgboost.d.ts +803 -178
- package/dist/xgboost/xgboost.d.ts.map +1 -1
- package/dist/xgboost/xgboost.js +102 -1
- package/dist/xgboost/xgboost.js.map +1 -1
- package/package.json +4 -4
|
@@ -10,32 +10,80 @@
|
|
|
10
10
|
*
|
|
11
11
|
* @packageDocumentation
|
|
12
12
|
*/
|
|
13
|
-
import { StructType, VariantType, OptionType, IntegerType, FloatType, BlobType } from "@elaraai/east";
|
|
13
|
+
import { StructType, VariantType, OptionType, ArrayType, IntegerType, FloatType, BlobType } from "@elaraai/east";
|
|
14
14
|
export { VectorType, MatrixType, LabelVectorType } from "../types.js";
|
|
15
15
|
/**
|
|
16
16
|
* Configuration for XGBoost models.
|
|
17
17
|
*/
|
|
18
18
|
export declare const XGBoostConfigType: StructType<{
|
|
19
19
|
/** Number of boosting rounds (default 100) */
|
|
20
|
-
n_estimators: OptionType<IntegerType>;
|
|
20
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
21
21
|
/** Maximum tree depth (default 6) */
|
|
22
|
-
max_depth: OptionType<IntegerType>;
|
|
22
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
23
23
|
/** Learning rate / step size shrinkage (default 0.3) */
|
|
24
|
-
learning_rate: OptionType<FloatType>;
|
|
24
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
25
25
|
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
26
|
-
min_child_weight: OptionType<IntegerType>;
|
|
26
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
27
27
|
/** Subsample ratio of training instances (default 1.0) */
|
|
28
|
-
subsample: OptionType<FloatType>;
|
|
28
|
+
readonly subsample: OptionType<FloatType>;
|
|
29
29
|
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
30
|
-
colsample_bytree: OptionType<FloatType>;
|
|
30
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
31
31
|
/** L1 regularization term (default 0) */
|
|
32
|
-
reg_alpha: OptionType<FloatType>;
|
|
32
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
33
33
|
/** L2 regularization term (default 1) */
|
|
34
|
-
reg_lambda: OptionType<FloatType>;
|
|
34
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
35
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
36
|
+
readonly gamma: OptionType<FloatType>;
|
|
35
37
|
/** Random seed for reproducibility */
|
|
36
|
-
random_state: OptionType<IntegerType>;
|
|
38
|
+
readonly random_state: OptionType<IntegerType>;
|
|
37
39
|
/** Number of parallel threads (default -1 for all cores) */
|
|
38
|
-
n_jobs: OptionType<IntegerType>;
|
|
40
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
41
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
42
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
43
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
44
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
45
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
46
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
47
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
48
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
49
|
+
}>;
|
|
50
|
+
/**
|
|
51
|
+
* Configuration for XGBoost quantile regression.
|
|
52
|
+
* Trains separate models for each quantile.
|
|
53
|
+
*/
|
|
54
|
+
export declare const XGBoostQuantileConfigType: StructType<{
|
|
55
|
+
/** Quantiles to predict (e.g., [0.1, 0.5, 0.9] for 80% interval + median) */
|
|
56
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
57
|
+
/** Number of boosting rounds (default 100) */
|
|
58
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
59
|
+
/** Maximum tree depth (default 6) */
|
|
60
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
61
|
+
/** Learning rate / step size shrinkage (default 0.3) */
|
|
62
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
63
|
+
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
64
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
65
|
+
/** Subsample ratio of training instances (default 1.0) */
|
|
66
|
+
readonly subsample: OptionType<FloatType>;
|
|
67
|
+
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
68
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
69
|
+
/** L1 regularization term (default 0) */
|
|
70
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
71
|
+
/** L2 regularization term (default 1) */
|
|
72
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
73
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
74
|
+
readonly gamma: OptionType<FloatType>;
|
|
75
|
+
/** Random seed for reproducibility */
|
|
76
|
+
readonly random_state: OptionType<IntegerType>;
|
|
77
|
+
/** Number of parallel threads (default -1 for all cores) */
|
|
78
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
79
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
80
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
81
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
82
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
83
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
84
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
85
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
86
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
39
87
|
}>;
|
|
40
88
|
/**
|
|
41
89
|
* Model blob type for serialized XGBoost models.
|
|
@@ -44,22 +92,46 @@ export declare const XGBoostConfigType: StructType<{
|
|
|
44
92
|
*/
|
|
45
93
|
export declare const XGBoostModelBlobType: VariantType<{
|
|
46
94
|
/** XGBoost regressor model */
|
|
47
|
-
xgboost_regressor: StructType<{
|
|
95
|
+
readonly xgboost_regressor: StructType<{
|
|
48
96
|
/** Cloudpickle serialized model */
|
|
49
|
-
data: BlobType;
|
|
97
|
+
readonly data: BlobType;
|
|
50
98
|
/** Number of input features */
|
|
51
|
-
n_features: IntegerType;
|
|
99
|
+
readonly n_features: IntegerType;
|
|
100
|
+
/** Column indices of categorical features (for prediction) */
|
|
101
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
52
102
|
}>;
|
|
53
103
|
/** XGBoost classifier model */
|
|
54
|
-
xgboost_classifier: StructType<{
|
|
104
|
+
readonly xgboost_classifier: StructType<{
|
|
55
105
|
/** Cloudpickle serialized model */
|
|
56
|
-
data: BlobType;
|
|
106
|
+
readonly data: BlobType;
|
|
57
107
|
/** Number of input features */
|
|
58
|
-
n_features: IntegerType;
|
|
108
|
+
readonly n_features: IntegerType;
|
|
59
109
|
/** Number of classes */
|
|
60
|
-
n_classes: IntegerType;
|
|
110
|
+
readonly n_classes: IntegerType;
|
|
111
|
+
/** Column indices of categorical features (for prediction) */
|
|
112
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
113
|
+
}>;
|
|
114
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
115
|
+
readonly xgboost_quantile: StructType<{
|
|
116
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
117
|
+
readonly data: BlobType;
|
|
118
|
+
/** Quantiles this model predicts */
|
|
119
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
120
|
+
/** Number of input features */
|
|
121
|
+
readonly n_features: IntegerType;
|
|
122
|
+
/** Column indices of categorical features (for prediction) */
|
|
123
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
61
124
|
}>;
|
|
62
125
|
}>;
|
|
126
|
+
/**
|
|
127
|
+
* Result from XGBoost quantile prediction.
|
|
128
|
+
*/
|
|
129
|
+
export declare const XGBoostQuantilePredictResultType: StructType<{
|
|
130
|
+
/** Quantile values that were predicted */
|
|
131
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
132
|
+
/** Predictions matrix: (n_samples x n_quantiles) */
|
|
133
|
+
readonly predictions: ArrayType<ArrayType<FloatType>>;
|
|
134
|
+
}>;
|
|
63
135
|
/**
|
|
64
136
|
* Train an XGBoost regression model.
|
|
65
137
|
*
|
|
@@ -68,43 +140,68 @@ export declare const XGBoostModelBlobType: VariantType<{
|
|
|
68
140
|
* @param config - XGBoost configuration
|
|
69
141
|
* @returns Model blob containing trained regressor
|
|
70
142
|
*/
|
|
71
|
-
export declare const xgboost_train_regressor: import("@elaraai/east").PlatformDefinition<[
|
|
143
|
+
export declare const xgboost_train_regressor: import("@elaraai/east").PlatformDefinition<[ArrayType<ArrayType<FloatType>>, ArrayType<FloatType>, StructType<{
|
|
72
144
|
/** Number of boosting rounds (default 100) */
|
|
73
|
-
n_estimators: OptionType<IntegerType>;
|
|
145
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
74
146
|
/** Maximum tree depth (default 6) */
|
|
75
|
-
max_depth: OptionType<IntegerType>;
|
|
147
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
76
148
|
/** Learning rate / step size shrinkage (default 0.3) */
|
|
77
|
-
learning_rate: OptionType<FloatType>;
|
|
149
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
78
150
|
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
79
|
-
min_child_weight: OptionType<IntegerType>;
|
|
151
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
80
152
|
/** Subsample ratio of training instances (default 1.0) */
|
|
81
|
-
subsample: OptionType<FloatType>;
|
|
153
|
+
readonly subsample: OptionType<FloatType>;
|
|
82
154
|
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
83
|
-
colsample_bytree: OptionType<FloatType>;
|
|
155
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
84
156
|
/** L1 regularization term (default 0) */
|
|
85
|
-
reg_alpha: OptionType<FloatType>;
|
|
157
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
86
158
|
/** L2 regularization term (default 1) */
|
|
87
|
-
reg_lambda: OptionType<FloatType>;
|
|
159
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
160
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
161
|
+
readonly gamma: OptionType<FloatType>;
|
|
88
162
|
/** Random seed for reproducibility */
|
|
89
|
-
random_state: OptionType<IntegerType>;
|
|
163
|
+
readonly random_state: OptionType<IntegerType>;
|
|
90
164
|
/** Number of parallel threads (default -1 for all cores) */
|
|
91
|
-
n_jobs: OptionType<IntegerType>;
|
|
165
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
166
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
167
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
168
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
169
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
170
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
171
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
172
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
173
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
92
174
|
}>], VariantType<{
|
|
93
175
|
/** XGBoost regressor model */
|
|
94
|
-
xgboost_regressor: StructType<{
|
|
176
|
+
readonly xgboost_regressor: StructType<{
|
|
95
177
|
/** Cloudpickle serialized model */
|
|
96
|
-
data: BlobType;
|
|
178
|
+
readonly data: BlobType;
|
|
97
179
|
/** Number of input features */
|
|
98
|
-
n_features: IntegerType;
|
|
180
|
+
readonly n_features: IntegerType;
|
|
181
|
+
/** Column indices of categorical features (for prediction) */
|
|
182
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
99
183
|
}>;
|
|
100
184
|
/** XGBoost classifier model */
|
|
101
|
-
xgboost_classifier: StructType<{
|
|
185
|
+
readonly xgboost_classifier: StructType<{
|
|
102
186
|
/** Cloudpickle serialized model */
|
|
103
|
-
data: BlobType;
|
|
187
|
+
readonly data: BlobType;
|
|
104
188
|
/** Number of input features */
|
|
105
|
-
n_features: IntegerType;
|
|
189
|
+
readonly n_features: IntegerType;
|
|
106
190
|
/** Number of classes */
|
|
107
|
-
n_classes: IntegerType;
|
|
191
|
+
readonly n_classes: IntegerType;
|
|
192
|
+
/** Column indices of categorical features (for prediction) */
|
|
193
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
194
|
+
}>;
|
|
195
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
196
|
+
readonly xgboost_quantile: StructType<{
|
|
197
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
198
|
+
readonly data: BlobType;
|
|
199
|
+
/** Quantiles this model predicts */
|
|
200
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
201
|
+
/** Number of input features */
|
|
202
|
+
readonly n_features: IntegerType;
|
|
203
|
+
/** Column indices of categorical features (for prediction) */
|
|
204
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
108
205
|
}>;
|
|
109
206
|
}>>;
|
|
110
207
|
/**
|
|
@@ -115,43 +212,68 @@ export declare const xgboost_train_regressor: import("@elaraai/east").PlatformDe
|
|
|
115
212
|
* @param config - XGBoost configuration
|
|
116
213
|
* @returns Model blob containing trained classifier
|
|
117
214
|
*/
|
|
118
|
-
export declare const xgboost_train_classifier: import("@elaraai/east").PlatformDefinition<[
|
|
215
|
+
export declare const xgboost_train_classifier: import("@elaraai/east").PlatformDefinition<[ArrayType<ArrayType<FloatType>>, ArrayType<IntegerType>, StructType<{
|
|
119
216
|
/** Number of boosting rounds (default 100) */
|
|
120
|
-
n_estimators: OptionType<IntegerType>;
|
|
217
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
121
218
|
/** Maximum tree depth (default 6) */
|
|
122
|
-
max_depth: OptionType<IntegerType>;
|
|
219
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
123
220
|
/** Learning rate / step size shrinkage (default 0.3) */
|
|
124
|
-
learning_rate: OptionType<FloatType>;
|
|
221
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
125
222
|
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
126
|
-
min_child_weight: OptionType<IntegerType>;
|
|
223
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
127
224
|
/** Subsample ratio of training instances (default 1.0) */
|
|
128
|
-
subsample: OptionType<FloatType>;
|
|
225
|
+
readonly subsample: OptionType<FloatType>;
|
|
129
226
|
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
130
|
-
colsample_bytree: OptionType<FloatType>;
|
|
227
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
131
228
|
/** L1 regularization term (default 0) */
|
|
132
|
-
reg_alpha: OptionType<FloatType>;
|
|
229
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
133
230
|
/** L2 regularization term (default 1) */
|
|
134
|
-
reg_lambda: OptionType<FloatType>;
|
|
231
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
232
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
233
|
+
readonly gamma: OptionType<FloatType>;
|
|
135
234
|
/** Random seed for reproducibility */
|
|
136
|
-
random_state: OptionType<IntegerType>;
|
|
235
|
+
readonly random_state: OptionType<IntegerType>;
|
|
137
236
|
/** Number of parallel threads (default -1 for all cores) */
|
|
138
|
-
n_jobs: OptionType<IntegerType>;
|
|
237
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
238
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
239
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
240
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
241
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
242
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
243
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
244
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
245
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
139
246
|
}>], VariantType<{
|
|
140
247
|
/** XGBoost regressor model */
|
|
141
|
-
xgboost_regressor: StructType<{
|
|
248
|
+
readonly xgboost_regressor: StructType<{
|
|
142
249
|
/** Cloudpickle serialized model */
|
|
143
|
-
data: BlobType;
|
|
250
|
+
readonly data: BlobType;
|
|
144
251
|
/** Number of input features */
|
|
145
|
-
n_features: IntegerType;
|
|
252
|
+
readonly n_features: IntegerType;
|
|
253
|
+
/** Column indices of categorical features (for prediction) */
|
|
254
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
146
255
|
}>;
|
|
147
256
|
/** XGBoost classifier model */
|
|
148
|
-
xgboost_classifier: StructType<{
|
|
257
|
+
readonly xgboost_classifier: StructType<{
|
|
149
258
|
/** Cloudpickle serialized model */
|
|
150
|
-
data: BlobType;
|
|
259
|
+
readonly data: BlobType;
|
|
151
260
|
/** Number of input features */
|
|
152
|
-
n_features: IntegerType;
|
|
261
|
+
readonly n_features: IntegerType;
|
|
153
262
|
/** Number of classes */
|
|
154
|
-
n_classes: IntegerType;
|
|
263
|
+
readonly n_classes: IntegerType;
|
|
264
|
+
/** Column indices of categorical features (for prediction) */
|
|
265
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
266
|
+
}>;
|
|
267
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
268
|
+
readonly xgboost_quantile: StructType<{
|
|
269
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
270
|
+
readonly data: BlobType;
|
|
271
|
+
/** Quantiles this model predicts */
|
|
272
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
273
|
+
/** Number of input features */
|
|
274
|
+
readonly n_features: IntegerType;
|
|
275
|
+
/** Column indices of categorical features (for prediction) */
|
|
276
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
155
277
|
}>;
|
|
156
278
|
}>>;
|
|
157
279
|
/**
|
|
@@ -163,22 +285,37 @@ export declare const xgboost_train_classifier: import("@elaraai/east").PlatformD
|
|
|
163
285
|
*/
|
|
164
286
|
export declare const xgboost_predict: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
165
287
|
/** XGBoost regressor model */
|
|
166
|
-
xgboost_regressor: StructType<{
|
|
288
|
+
readonly xgboost_regressor: StructType<{
|
|
167
289
|
/** Cloudpickle serialized model */
|
|
168
|
-
data: BlobType;
|
|
290
|
+
readonly data: BlobType;
|
|
169
291
|
/** Number of input features */
|
|
170
|
-
n_features: IntegerType;
|
|
292
|
+
readonly n_features: IntegerType;
|
|
293
|
+
/** Column indices of categorical features (for prediction) */
|
|
294
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
171
295
|
}>;
|
|
172
296
|
/** XGBoost classifier model */
|
|
173
|
-
xgboost_classifier: StructType<{
|
|
297
|
+
readonly xgboost_classifier: StructType<{
|
|
174
298
|
/** Cloudpickle serialized model */
|
|
175
|
-
data: BlobType;
|
|
299
|
+
readonly data: BlobType;
|
|
176
300
|
/** Number of input features */
|
|
177
|
-
n_features: IntegerType;
|
|
301
|
+
readonly n_features: IntegerType;
|
|
178
302
|
/** Number of classes */
|
|
179
|
-
n_classes: IntegerType;
|
|
303
|
+
readonly n_classes: IntegerType;
|
|
304
|
+
/** Column indices of categorical features (for prediction) */
|
|
305
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
306
|
+
}>;
|
|
307
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
308
|
+
readonly xgboost_quantile: StructType<{
|
|
309
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
310
|
+
readonly data: BlobType;
|
|
311
|
+
/** Quantiles this model predicts */
|
|
312
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
313
|
+
/** Number of input features */
|
|
314
|
+
readonly n_features: IntegerType;
|
|
315
|
+
/** Column indices of categorical features (for prediction) */
|
|
316
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
180
317
|
}>;
|
|
181
|
-
}>,
|
|
318
|
+
}>, ArrayType<ArrayType<FloatType>>], ArrayType<FloatType>>;
|
|
182
319
|
/**
|
|
183
320
|
* Predict class labels with a trained XGBoost classifier.
|
|
184
321
|
*
|
|
@@ -188,22 +325,37 @@ export declare const xgboost_predict: import("@elaraai/east").PlatformDefinition
|
|
|
188
325
|
*/
|
|
189
326
|
export declare const xgboost_predict_class: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
190
327
|
/** XGBoost regressor model */
|
|
191
|
-
xgboost_regressor: StructType<{
|
|
328
|
+
readonly xgboost_regressor: StructType<{
|
|
192
329
|
/** Cloudpickle serialized model */
|
|
193
|
-
data: BlobType;
|
|
330
|
+
readonly data: BlobType;
|
|
194
331
|
/** Number of input features */
|
|
195
|
-
n_features: IntegerType;
|
|
332
|
+
readonly n_features: IntegerType;
|
|
333
|
+
/** Column indices of categorical features (for prediction) */
|
|
334
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
196
335
|
}>;
|
|
197
336
|
/** XGBoost classifier model */
|
|
198
|
-
xgboost_classifier: StructType<{
|
|
337
|
+
readonly xgboost_classifier: StructType<{
|
|
199
338
|
/** Cloudpickle serialized model */
|
|
200
|
-
data: BlobType;
|
|
339
|
+
readonly data: BlobType;
|
|
201
340
|
/** Number of input features */
|
|
202
|
-
n_features: IntegerType;
|
|
341
|
+
readonly n_features: IntegerType;
|
|
203
342
|
/** Number of classes */
|
|
204
|
-
n_classes: IntegerType;
|
|
343
|
+
readonly n_classes: IntegerType;
|
|
344
|
+
/** Column indices of categorical features (for prediction) */
|
|
345
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
205
346
|
}>;
|
|
206
|
-
|
|
347
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
348
|
+
readonly xgboost_quantile: StructType<{
|
|
349
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
350
|
+
readonly data: BlobType;
|
|
351
|
+
/** Quantiles this model predicts */
|
|
352
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
353
|
+
/** Number of input features */
|
|
354
|
+
readonly n_features: IntegerType;
|
|
355
|
+
/** Column indices of categorical features (for prediction) */
|
|
356
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
357
|
+
}>;
|
|
358
|
+
}>, ArrayType<ArrayType<FloatType>>], ArrayType<IntegerType>>;
|
|
207
359
|
/**
|
|
208
360
|
* Get class probabilities from a trained XGBoost classifier.
|
|
209
361
|
*
|
|
@@ -213,72 +365,276 @@ export declare const xgboost_predict_class: import("@elaraai/east").PlatformDefi
|
|
|
213
365
|
*/
|
|
214
366
|
export declare const xgboost_predict_proba: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
215
367
|
/** XGBoost regressor model */
|
|
216
|
-
xgboost_regressor: StructType<{
|
|
368
|
+
readonly xgboost_regressor: StructType<{
|
|
217
369
|
/** Cloudpickle serialized model */
|
|
218
|
-
data: BlobType;
|
|
370
|
+
readonly data: BlobType;
|
|
219
371
|
/** Number of input features */
|
|
220
|
-
n_features: IntegerType;
|
|
372
|
+
readonly n_features: IntegerType;
|
|
373
|
+
/** Column indices of categorical features (for prediction) */
|
|
374
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
221
375
|
}>;
|
|
222
376
|
/** XGBoost classifier model */
|
|
223
|
-
xgboost_classifier: StructType<{
|
|
377
|
+
readonly xgboost_classifier: StructType<{
|
|
224
378
|
/** Cloudpickle serialized model */
|
|
225
|
-
data: BlobType;
|
|
379
|
+
readonly data: BlobType;
|
|
226
380
|
/** Number of input features */
|
|
227
|
-
n_features: IntegerType;
|
|
381
|
+
readonly n_features: IntegerType;
|
|
228
382
|
/** Number of classes */
|
|
229
|
-
n_classes: IntegerType;
|
|
383
|
+
readonly n_classes: IntegerType;
|
|
384
|
+
/** Column indices of categorical features (for prediction) */
|
|
385
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
386
|
+
}>;
|
|
387
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
388
|
+
readonly xgboost_quantile: StructType<{
|
|
389
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
390
|
+
readonly data: BlobType;
|
|
391
|
+
/** Quantiles this model predicts */
|
|
392
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
393
|
+
/** Number of input features */
|
|
394
|
+
readonly n_features: IntegerType;
|
|
395
|
+
/** Column indices of categorical features (for prediction) */
|
|
396
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
230
397
|
}>;
|
|
231
|
-
}>,
|
|
398
|
+
}>, ArrayType<ArrayType<FloatType>>], ArrayType<ArrayType<FloatType>>>;
|
|
399
|
+
/**
|
|
400
|
+
* Train XGBoost quantile regression models.
|
|
401
|
+
*
|
|
402
|
+
* Trains one model per quantile using pinball loss (reg:quantileerror).
|
|
403
|
+
* This provides prediction intervals and uncertainty quantification.
|
|
404
|
+
*
|
|
405
|
+
* @param X - Feature matrix
|
|
406
|
+
* @param y - Target vector
|
|
407
|
+
* @param config - Quantile regression configuration (includes quantiles array)
|
|
408
|
+
* @returns Model blob containing trained quantile models
|
|
409
|
+
*/
|
|
410
|
+
export declare const xgboost_train_quantile: import("@elaraai/east").PlatformDefinition<[ArrayType<ArrayType<FloatType>>, ArrayType<FloatType>, StructType<{
|
|
411
|
+
/** Quantiles to predict (e.g., [0.1, 0.5, 0.9] for 80% interval + median) */
|
|
412
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
413
|
+
/** Number of boosting rounds (default 100) */
|
|
414
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
415
|
+
/** Maximum tree depth (default 6) */
|
|
416
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
417
|
+
/** Learning rate / step size shrinkage (default 0.3) */
|
|
418
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
419
|
+
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
420
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
421
|
+
/** Subsample ratio of training instances (default 1.0) */
|
|
422
|
+
readonly subsample: OptionType<FloatType>;
|
|
423
|
+
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
424
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
425
|
+
/** L1 regularization term (default 0) */
|
|
426
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
427
|
+
/** L2 regularization term (default 1) */
|
|
428
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
429
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
430
|
+
readonly gamma: OptionType<FloatType>;
|
|
431
|
+
/** Random seed for reproducibility */
|
|
432
|
+
readonly random_state: OptionType<IntegerType>;
|
|
433
|
+
/** Number of parallel threads (default -1 for all cores) */
|
|
434
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
435
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
436
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
437
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
438
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
439
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
440
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
441
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
442
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
443
|
+
}>], VariantType<{
|
|
444
|
+
/** XGBoost regressor model */
|
|
445
|
+
readonly xgboost_regressor: StructType<{
|
|
446
|
+
/** Cloudpickle serialized model */
|
|
447
|
+
readonly data: BlobType;
|
|
448
|
+
/** Number of input features */
|
|
449
|
+
readonly n_features: IntegerType;
|
|
450
|
+
/** Column indices of categorical features (for prediction) */
|
|
451
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
452
|
+
}>;
|
|
453
|
+
/** XGBoost classifier model */
|
|
454
|
+
readonly xgboost_classifier: StructType<{
|
|
455
|
+
/** Cloudpickle serialized model */
|
|
456
|
+
readonly data: BlobType;
|
|
457
|
+
/** Number of input features */
|
|
458
|
+
readonly n_features: IntegerType;
|
|
459
|
+
/** Number of classes */
|
|
460
|
+
readonly n_classes: IntegerType;
|
|
461
|
+
/** Column indices of categorical features (for prediction) */
|
|
462
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
463
|
+
}>;
|
|
464
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
465
|
+
readonly xgboost_quantile: StructType<{
|
|
466
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
467
|
+
readonly data: BlobType;
|
|
468
|
+
/** Quantiles this model predicts */
|
|
469
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
470
|
+
/** Number of input features */
|
|
471
|
+
readonly n_features: IntegerType;
|
|
472
|
+
/** Column indices of categorical features (for prediction) */
|
|
473
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
474
|
+
}>;
|
|
475
|
+
}>>;
|
|
476
|
+
/**
|
|
477
|
+
* Predict quantiles with trained XGBoost quantile regressor.
|
|
478
|
+
*
|
|
479
|
+
* @param model - Trained quantile model blob
|
|
480
|
+
* @param X - Feature matrix
|
|
481
|
+
* @returns Quantiles and predictions matrix (n_samples x n_quantiles)
|
|
482
|
+
*/
|
|
483
|
+
export declare const xgboost_predict_quantile: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
484
|
+
/** XGBoost regressor model */
|
|
485
|
+
readonly xgboost_regressor: StructType<{
|
|
486
|
+
/** Cloudpickle serialized model */
|
|
487
|
+
readonly data: BlobType;
|
|
488
|
+
/** Number of input features */
|
|
489
|
+
readonly n_features: IntegerType;
|
|
490
|
+
/** Column indices of categorical features (for prediction) */
|
|
491
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
492
|
+
}>;
|
|
493
|
+
/** XGBoost classifier model */
|
|
494
|
+
readonly xgboost_classifier: StructType<{
|
|
495
|
+
/** Cloudpickle serialized model */
|
|
496
|
+
readonly data: BlobType;
|
|
497
|
+
/** Number of input features */
|
|
498
|
+
readonly n_features: IntegerType;
|
|
499
|
+
/** Number of classes */
|
|
500
|
+
readonly n_classes: IntegerType;
|
|
501
|
+
/** Column indices of categorical features (for prediction) */
|
|
502
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
503
|
+
}>;
|
|
504
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
505
|
+
readonly xgboost_quantile: StructType<{
|
|
506
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
507
|
+
readonly data: BlobType;
|
|
508
|
+
/** Quantiles this model predicts */
|
|
509
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
510
|
+
/** Number of input features */
|
|
511
|
+
readonly n_features: IntegerType;
|
|
512
|
+
/** Column indices of categorical features (for prediction) */
|
|
513
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
514
|
+
}>;
|
|
515
|
+
}>, ArrayType<ArrayType<FloatType>>], StructType<{
|
|
516
|
+
/** Quantile values that were predicted */
|
|
517
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
518
|
+
/** Predictions matrix: (n_samples x n_quantiles) */
|
|
519
|
+
readonly predictions: ArrayType<ArrayType<FloatType>>;
|
|
520
|
+
}>>;
|
|
232
521
|
/**
|
|
233
522
|
* Type definitions for XGBoost functions.
|
|
234
523
|
*/
|
|
235
524
|
export declare const XGBoostTypes: {
|
|
236
525
|
/** Vector type (array of floats) */
|
|
237
|
-
readonly VectorType:
|
|
526
|
+
readonly VectorType: ArrayType<FloatType>;
|
|
238
527
|
/** Matrix type (2D array of floats) */
|
|
239
|
-
readonly MatrixType:
|
|
528
|
+
readonly MatrixType: ArrayType<ArrayType<FloatType>>;
|
|
240
529
|
/** Label vector type (array of integers) */
|
|
241
|
-
readonly LabelVectorType:
|
|
530
|
+
readonly LabelVectorType: ArrayType<IntegerType>;
|
|
242
531
|
/** XGBoost configuration type */
|
|
243
532
|
readonly XGBoostConfigType: StructType<{
|
|
244
533
|
/** Number of boosting rounds (default 100) */
|
|
245
|
-
n_estimators: OptionType<IntegerType>;
|
|
534
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
246
535
|
/** Maximum tree depth (default 6) */
|
|
247
|
-
max_depth: OptionType<IntegerType>;
|
|
536
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
248
537
|
/** Learning rate / step size shrinkage (default 0.3) */
|
|
249
|
-
learning_rate: OptionType<FloatType>;
|
|
538
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
250
539
|
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
251
|
-
min_child_weight: OptionType<IntegerType>;
|
|
540
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
252
541
|
/** Subsample ratio of training instances (default 1.0) */
|
|
253
|
-
subsample: OptionType<FloatType>;
|
|
542
|
+
readonly subsample: OptionType<FloatType>;
|
|
254
543
|
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
255
|
-
colsample_bytree: OptionType<FloatType>;
|
|
544
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
256
545
|
/** L1 regularization term (default 0) */
|
|
257
|
-
reg_alpha: OptionType<FloatType>;
|
|
546
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
258
547
|
/** L2 regularization term (default 1) */
|
|
259
|
-
reg_lambda: OptionType<FloatType>;
|
|
548
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
549
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
550
|
+
readonly gamma: OptionType<FloatType>;
|
|
260
551
|
/** Random seed for reproducibility */
|
|
261
|
-
random_state: OptionType<IntegerType>;
|
|
552
|
+
readonly random_state: OptionType<IntegerType>;
|
|
262
553
|
/** Number of parallel threads (default -1 for all cores) */
|
|
263
|
-
n_jobs: OptionType<IntegerType>;
|
|
554
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
555
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
556
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
557
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
558
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
559
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
560
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
561
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
562
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
563
|
+
}>;
|
|
564
|
+
/** XGBoost quantile configuration type */
|
|
565
|
+
readonly XGBoostQuantileConfigType: StructType<{
|
|
566
|
+
/** Quantiles to predict (e.g., [0.1, 0.5, 0.9] for 80% interval + median) */
|
|
567
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
568
|
+
/** Number of boosting rounds (default 100) */
|
|
569
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
570
|
+
/** Maximum tree depth (default 6) */
|
|
571
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
572
|
+
/** Learning rate / step size shrinkage (default 0.3) */
|
|
573
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
574
|
+
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
575
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
576
|
+
/** Subsample ratio of training instances (default 1.0) */
|
|
577
|
+
readonly subsample: OptionType<FloatType>;
|
|
578
|
+
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
579
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
580
|
+
/** L1 regularization term (default 0) */
|
|
581
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
582
|
+
/** L2 regularization term (default 1) */
|
|
583
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
584
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
585
|
+
readonly gamma: OptionType<FloatType>;
|
|
586
|
+
/** Random seed for reproducibility */
|
|
587
|
+
readonly random_state: OptionType<IntegerType>;
|
|
588
|
+
/** Number of parallel threads (default -1 for all cores) */
|
|
589
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
590
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
591
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
592
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
593
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
594
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
595
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
596
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
597
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
598
|
+
}>;
|
|
599
|
+
/** Quantile prediction result type */
|
|
600
|
+
readonly XGBoostQuantilePredictResultType: StructType<{
|
|
601
|
+
/** Quantile values that were predicted */
|
|
602
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
603
|
+
/** Predictions matrix: (n_samples x n_quantiles) */
|
|
604
|
+
readonly predictions: ArrayType<ArrayType<FloatType>>;
|
|
264
605
|
}>;
|
|
265
606
|
/** Model blob type for XGBoost models */
|
|
266
607
|
readonly ModelBlobType: VariantType<{
|
|
267
608
|
/** XGBoost regressor model */
|
|
268
|
-
xgboost_regressor: StructType<{
|
|
609
|
+
readonly xgboost_regressor: StructType<{
|
|
269
610
|
/** Cloudpickle serialized model */
|
|
270
|
-
data: BlobType;
|
|
611
|
+
readonly data: BlobType;
|
|
271
612
|
/** Number of input features */
|
|
272
|
-
n_features: IntegerType;
|
|
613
|
+
readonly n_features: IntegerType;
|
|
614
|
+
/** Column indices of categorical features (for prediction) */
|
|
615
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
273
616
|
}>;
|
|
274
617
|
/** XGBoost classifier model */
|
|
275
|
-
xgboost_classifier: StructType<{
|
|
618
|
+
readonly xgboost_classifier: StructType<{
|
|
276
619
|
/** Cloudpickle serialized model */
|
|
277
|
-
data: BlobType;
|
|
620
|
+
readonly data: BlobType;
|
|
278
621
|
/** Number of input features */
|
|
279
|
-
n_features: IntegerType;
|
|
622
|
+
readonly n_features: IntegerType;
|
|
280
623
|
/** Number of classes */
|
|
281
|
-
n_classes: IntegerType;
|
|
624
|
+
readonly n_classes: IntegerType;
|
|
625
|
+
/** Column indices of categorical features (for prediction) */
|
|
626
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
627
|
+
}>;
|
|
628
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
629
|
+
readonly xgboost_quantile: StructType<{
|
|
630
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
631
|
+
readonly data: BlobType;
|
|
632
|
+
/** Quantiles this model predicts */
|
|
633
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
634
|
+
/** Number of input features */
|
|
635
|
+
readonly n_features: IntegerType;
|
|
636
|
+
/** Column indices of categorical features (for prediction) */
|
|
637
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
282
638
|
}>;
|
|
283
639
|
}>;
|
|
284
640
|
};
|
|
@@ -306,6 +662,7 @@ export declare const XGBoostTypes: {
|
|
|
306
662
|
* reg_lambda: variant('none', null),
|
|
307
663
|
* random_state: variant('some', 42n),
|
|
308
664
|
* n_jobs: variant('none', null),
|
|
665
|
+
* sample_weight: variant('none', null),
|
|
309
666
|
* });
|
|
310
667
|
* return $.return(XGBoost.trainRegressor(X, y, config));
|
|
311
668
|
* });
|
|
@@ -313,190 +670,458 @@ export declare const XGBoostTypes: {
|
|
|
313
670
|
*/
|
|
314
671
|
export declare const XGBoost: {
|
|
315
672
|
/** Train XGBoost regressor */
|
|
316
|
-
readonly trainRegressor: import("@elaraai/east").PlatformDefinition<[
|
|
673
|
+
readonly trainRegressor: import("@elaraai/east").PlatformDefinition<[ArrayType<ArrayType<FloatType>>, ArrayType<FloatType>, StructType<{
|
|
317
674
|
/** Number of boosting rounds (default 100) */
|
|
318
|
-
n_estimators: OptionType<IntegerType>;
|
|
675
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
319
676
|
/** Maximum tree depth (default 6) */
|
|
320
|
-
max_depth: OptionType<IntegerType>;
|
|
677
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
321
678
|
/** Learning rate / step size shrinkage (default 0.3) */
|
|
322
|
-
learning_rate: OptionType<FloatType>;
|
|
679
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
323
680
|
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
324
|
-
min_child_weight: OptionType<IntegerType>;
|
|
681
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
325
682
|
/** Subsample ratio of training instances (default 1.0) */
|
|
326
|
-
subsample: OptionType<FloatType>;
|
|
683
|
+
readonly subsample: OptionType<FloatType>;
|
|
327
684
|
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
328
|
-
colsample_bytree: OptionType<FloatType>;
|
|
685
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
329
686
|
/** L1 regularization term (default 0) */
|
|
330
|
-
reg_alpha: OptionType<FloatType>;
|
|
687
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
331
688
|
/** L2 regularization term (default 1) */
|
|
332
|
-
reg_lambda: OptionType<FloatType>;
|
|
689
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
690
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
691
|
+
readonly gamma: OptionType<FloatType>;
|
|
333
692
|
/** Random seed for reproducibility */
|
|
334
|
-
random_state: OptionType<IntegerType>;
|
|
693
|
+
readonly random_state: OptionType<IntegerType>;
|
|
335
694
|
/** Number of parallel threads (default -1 for all cores) */
|
|
336
|
-
n_jobs: OptionType<IntegerType>;
|
|
695
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
696
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
697
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
698
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
699
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
700
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
701
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
702
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
703
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
337
704
|
}>], VariantType<{
|
|
338
705
|
/** XGBoost regressor model */
|
|
339
|
-
xgboost_regressor: StructType<{
|
|
706
|
+
readonly xgboost_regressor: StructType<{
|
|
340
707
|
/** Cloudpickle serialized model */
|
|
341
|
-
data: BlobType;
|
|
708
|
+
readonly data: BlobType;
|
|
342
709
|
/** Number of input features */
|
|
343
|
-
n_features: IntegerType;
|
|
710
|
+
readonly n_features: IntegerType;
|
|
711
|
+
/** Column indices of categorical features (for prediction) */
|
|
712
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
344
713
|
}>;
|
|
345
714
|
/** XGBoost classifier model */
|
|
346
|
-
xgboost_classifier: StructType<{
|
|
715
|
+
readonly xgboost_classifier: StructType<{
|
|
347
716
|
/** Cloudpickle serialized model */
|
|
348
|
-
data: BlobType;
|
|
717
|
+
readonly data: BlobType;
|
|
349
718
|
/** Number of input features */
|
|
350
|
-
n_features: IntegerType;
|
|
719
|
+
readonly n_features: IntegerType;
|
|
351
720
|
/** Number of classes */
|
|
352
|
-
n_classes: IntegerType;
|
|
721
|
+
readonly n_classes: IntegerType;
|
|
722
|
+
/** Column indices of categorical features (for prediction) */
|
|
723
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
724
|
+
}>;
|
|
725
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
726
|
+
readonly xgboost_quantile: StructType<{
|
|
727
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
728
|
+
readonly data: BlobType;
|
|
729
|
+
/** Quantiles this model predicts */
|
|
730
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
731
|
+
/** Number of input features */
|
|
732
|
+
readonly n_features: IntegerType;
|
|
733
|
+
/** Column indices of categorical features (for prediction) */
|
|
734
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
353
735
|
}>;
|
|
354
736
|
}>>;
|
|
355
737
|
/** Train XGBoost classifier */
|
|
356
|
-
readonly trainClassifier: import("@elaraai/east").PlatformDefinition<[
|
|
738
|
+
readonly trainClassifier: import("@elaraai/east").PlatformDefinition<[ArrayType<ArrayType<FloatType>>, ArrayType<IntegerType>, StructType<{
|
|
357
739
|
/** Number of boosting rounds (default 100) */
|
|
358
|
-
n_estimators: OptionType<IntegerType>;
|
|
740
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
359
741
|
/** Maximum tree depth (default 6) */
|
|
360
|
-
max_depth: OptionType<IntegerType>;
|
|
742
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
361
743
|
/** Learning rate / step size shrinkage (default 0.3) */
|
|
362
|
-
learning_rate: OptionType<FloatType>;
|
|
744
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
363
745
|
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
364
|
-
min_child_weight: OptionType<IntegerType>;
|
|
746
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
365
747
|
/** Subsample ratio of training instances (default 1.0) */
|
|
366
|
-
subsample: OptionType<FloatType>;
|
|
748
|
+
readonly subsample: OptionType<FloatType>;
|
|
367
749
|
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
368
|
-
colsample_bytree: OptionType<FloatType>;
|
|
750
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
369
751
|
/** L1 regularization term (default 0) */
|
|
370
|
-
reg_alpha: OptionType<FloatType>;
|
|
752
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
371
753
|
/** L2 regularization term (default 1) */
|
|
372
|
-
reg_lambda: OptionType<FloatType>;
|
|
754
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
755
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
756
|
+
readonly gamma: OptionType<FloatType>;
|
|
373
757
|
/** Random seed for reproducibility */
|
|
374
|
-
random_state: OptionType<IntegerType>;
|
|
758
|
+
readonly random_state: OptionType<IntegerType>;
|
|
375
759
|
/** Number of parallel threads (default -1 for all cores) */
|
|
376
|
-
n_jobs: OptionType<IntegerType>;
|
|
760
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
761
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
762
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
763
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
764
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
765
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
766
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
767
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
768
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
377
769
|
}>], VariantType<{
|
|
378
770
|
/** XGBoost regressor model */
|
|
379
|
-
xgboost_regressor: StructType<{
|
|
771
|
+
readonly xgboost_regressor: StructType<{
|
|
380
772
|
/** Cloudpickle serialized model */
|
|
381
|
-
data: BlobType;
|
|
773
|
+
readonly data: BlobType;
|
|
382
774
|
/** Number of input features */
|
|
383
|
-
n_features: IntegerType;
|
|
775
|
+
readonly n_features: IntegerType;
|
|
776
|
+
/** Column indices of categorical features (for prediction) */
|
|
777
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
384
778
|
}>;
|
|
385
779
|
/** XGBoost classifier model */
|
|
386
|
-
xgboost_classifier: StructType<{
|
|
780
|
+
readonly xgboost_classifier: StructType<{
|
|
387
781
|
/** Cloudpickle serialized model */
|
|
388
|
-
data: BlobType;
|
|
782
|
+
readonly data: BlobType;
|
|
389
783
|
/** Number of input features */
|
|
390
|
-
n_features: IntegerType;
|
|
784
|
+
readonly n_features: IntegerType;
|
|
391
785
|
/** Number of classes */
|
|
392
|
-
n_classes: IntegerType;
|
|
786
|
+
readonly n_classes: IntegerType;
|
|
787
|
+
/** Column indices of categorical features (for prediction) */
|
|
788
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
789
|
+
}>;
|
|
790
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
791
|
+
readonly xgboost_quantile: StructType<{
|
|
792
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
793
|
+
readonly data: BlobType;
|
|
794
|
+
/** Quantiles this model predicts */
|
|
795
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
796
|
+
/** Number of input features */
|
|
797
|
+
readonly n_features: IntegerType;
|
|
798
|
+
/** Column indices of categorical features (for prediction) */
|
|
799
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
800
|
+
}>;
|
|
801
|
+
}>>;
|
|
802
|
+
/** Train XGBoost quantile regressor */
|
|
803
|
+
readonly trainQuantile: import("@elaraai/east").PlatformDefinition<[ArrayType<ArrayType<FloatType>>, ArrayType<FloatType>, StructType<{
|
|
804
|
+
/** Quantiles to predict (e.g., [0.1, 0.5, 0.9] for 80% interval + median) */
|
|
805
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
806
|
+
/** Number of boosting rounds (default 100) */
|
|
807
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
808
|
+
/** Maximum tree depth (default 6) */
|
|
809
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
810
|
+
/** Learning rate / step size shrinkage (default 0.3) */
|
|
811
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
812
|
+
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
813
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
814
|
+
/** Subsample ratio of training instances (default 1.0) */
|
|
815
|
+
readonly subsample: OptionType<FloatType>;
|
|
816
|
+
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
817
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
818
|
+
/** L1 regularization term (default 0) */
|
|
819
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
820
|
+
/** L2 regularization term (default 1) */
|
|
821
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
822
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
823
|
+
readonly gamma: OptionType<FloatType>;
|
|
824
|
+
/** Random seed for reproducibility */
|
|
825
|
+
readonly random_state: OptionType<IntegerType>;
|
|
826
|
+
/** Number of parallel threads (default -1 for all cores) */
|
|
827
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
828
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
829
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
830
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
831
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
832
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
833
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
834
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
835
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
836
|
+
}>], VariantType<{
|
|
837
|
+
/** XGBoost regressor model */
|
|
838
|
+
readonly xgboost_regressor: StructType<{
|
|
839
|
+
/** Cloudpickle serialized model */
|
|
840
|
+
readonly data: BlobType;
|
|
841
|
+
/** Number of input features */
|
|
842
|
+
readonly n_features: IntegerType;
|
|
843
|
+
/** Column indices of categorical features (for prediction) */
|
|
844
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
845
|
+
}>;
|
|
846
|
+
/** XGBoost classifier model */
|
|
847
|
+
readonly xgboost_classifier: StructType<{
|
|
848
|
+
/** Cloudpickle serialized model */
|
|
849
|
+
readonly data: BlobType;
|
|
850
|
+
/** Number of input features */
|
|
851
|
+
readonly n_features: IntegerType;
|
|
852
|
+
/** Number of classes */
|
|
853
|
+
readonly n_classes: IntegerType;
|
|
854
|
+
/** Column indices of categorical features (for prediction) */
|
|
855
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
856
|
+
}>;
|
|
857
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
858
|
+
readonly xgboost_quantile: StructType<{
|
|
859
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
860
|
+
readonly data: BlobType;
|
|
861
|
+
/** Quantiles this model predicts */
|
|
862
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
863
|
+
/** Number of input features */
|
|
864
|
+
readonly n_features: IntegerType;
|
|
865
|
+
/** Column indices of categorical features (for prediction) */
|
|
866
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
393
867
|
}>;
|
|
394
868
|
}>>;
|
|
395
869
|
/** Make predictions with regressor */
|
|
396
870
|
readonly predict: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
397
871
|
/** XGBoost regressor model */
|
|
398
|
-
xgboost_regressor: StructType<{
|
|
872
|
+
readonly xgboost_regressor: StructType<{
|
|
399
873
|
/** Cloudpickle serialized model */
|
|
400
|
-
data: BlobType;
|
|
874
|
+
readonly data: BlobType;
|
|
401
875
|
/** Number of input features */
|
|
402
|
-
n_features: IntegerType;
|
|
876
|
+
readonly n_features: IntegerType;
|
|
877
|
+
/** Column indices of categorical features (for prediction) */
|
|
878
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
403
879
|
}>;
|
|
404
880
|
/** XGBoost classifier model */
|
|
405
|
-
xgboost_classifier: StructType<{
|
|
881
|
+
readonly xgboost_classifier: StructType<{
|
|
406
882
|
/** Cloudpickle serialized model */
|
|
407
|
-
data: BlobType;
|
|
883
|
+
readonly data: BlobType;
|
|
408
884
|
/** Number of input features */
|
|
409
|
-
n_features: IntegerType;
|
|
885
|
+
readonly n_features: IntegerType;
|
|
410
886
|
/** Number of classes */
|
|
411
|
-
n_classes: IntegerType;
|
|
887
|
+
readonly n_classes: IntegerType;
|
|
888
|
+
/** Column indices of categorical features (for prediction) */
|
|
889
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
412
890
|
}>;
|
|
413
|
-
|
|
891
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
892
|
+
readonly xgboost_quantile: StructType<{
|
|
893
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
894
|
+
readonly data: BlobType;
|
|
895
|
+
/** Quantiles this model predicts */
|
|
896
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
897
|
+
/** Number of input features */
|
|
898
|
+
readonly n_features: IntegerType;
|
|
899
|
+
/** Column indices of categorical features (for prediction) */
|
|
900
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
901
|
+
}>;
|
|
902
|
+
}>, ArrayType<ArrayType<FloatType>>], ArrayType<FloatType>>;
|
|
414
903
|
/** Predict class labels with classifier */
|
|
415
904
|
readonly predictClass: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
416
905
|
/** XGBoost regressor model */
|
|
417
|
-
xgboost_regressor: StructType<{
|
|
906
|
+
readonly xgboost_regressor: StructType<{
|
|
418
907
|
/** Cloudpickle serialized model */
|
|
419
|
-
data: BlobType;
|
|
908
|
+
readonly data: BlobType;
|
|
420
909
|
/** Number of input features */
|
|
421
|
-
n_features: IntegerType;
|
|
910
|
+
readonly n_features: IntegerType;
|
|
911
|
+
/** Column indices of categorical features (for prediction) */
|
|
912
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
422
913
|
}>;
|
|
423
914
|
/** XGBoost classifier model */
|
|
424
|
-
xgboost_classifier: StructType<{
|
|
915
|
+
readonly xgboost_classifier: StructType<{
|
|
425
916
|
/** Cloudpickle serialized model */
|
|
426
|
-
data: BlobType;
|
|
917
|
+
readonly data: BlobType;
|
|
427
918
|
/** Number of input features */
|
|
428
|
-
n_features: IntegerType;
|
|
919
|
+
readonly n_features: IntegerType;
|
|
429
920
|
/** Number of classes */
|
|
430
|
-
n_classes: IntegerType;
|
|
921
|
+
readonly n_classes: IntegerType;
|
|
922
|
+
/** Column indices of categorical features (for prediction) */
|
|
923
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
924
|
+
}>;
|
|
925
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
926
|
+
readonly xgboost_quantile: StructType<{
|
|
927
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
928
|
+
readonly data: BlobType;
|
|
929
|
+
/** Quantiles this model predicts */
|
|
930
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
931
|
+
/** Number of input features */
|
|
932
|
+
readonly n_features: IntegerType;
|
|
933
|
+
/** Column indices of categorical features (for prediction) */
|
|
934
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
431
935
|
}>;
|
|
432
|
-
}>,
|
|
936
|
+
}>, ArrayType<ArrayType<FloatType>>], ArrayType<IntegerType>>;
|
|
433
937
|
/** Get class probabilities from classifier */
|
|
434
938
|
readonly predictProba: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
435
939
|
/** XGBoost regressor model */
|
|
436
|
-
xgboost_regressor: StructType<{
|
|
940
|
+
readonly xgboost_regressor: StructType<{
|
|
941
|
+
/** Cloudpickle serialized model */
|
|
942
|
+
readonly data: BlobType;
|
|
943
|
+
/** Number of input features */
|
|
944
|
+
readonly n_features: IntegerType;
|
|
945
|
+
/** Column indices of categorical features (for prediction) */
|
|
946
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
947
|
+
}>;
|
|
948
|
+
/** XGBoost classifier model */
|
|
949
|
+
readonly xgboost_classifier: StructType<{
|
|
950
|
+
/** Cloudpickle serialized model */
|
|
951
|
+
readonly data: BlobType;
|
|
952
|
+
/** Number of input features */
|
|
953
|
+
readonly n_features: IntegerType;
|
|
954
|
+
/** Number of classes */
|
|
955
|
+
readonly n_classes: IntegerType;
|
|
956
|
+
/** Column indices of categorical features (for prediction) */
|
|
957
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
958
|
+
}>;
|
|
959
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
960
|
+
readonly xgboost_quantile: StructType<{
|
|
961
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
962
|
+
readonly data: BlobType;
|
|
963
|
+
/** Quantiles this model predicts */
|
|
964
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
965
|
+
/** Number of input features */
|
|
966
|
+
readonly n_features: IntegerType;
|
|
967
|
+
/** Column indices of categorical features (for prediction) */
|
|
968
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
969
|
+
}>;
|
|
970
|
+
}>, ArrayType<ArrayType<FloatType>>], ArrayType<ArrayType<FloatType>>>;
|
|
971
|
+
/** Predict quantiles with quantile regressor */
|
|
972
|
+
readonly predictQuantile: import("@elaraai/east").PlatformDefinition<[VariantType<{
|
|
973
|
+
/** XGBoost regressor model */
|
|
974
|
+
readonly xgboost_regressor: StructType<{
|
|
437
975
|
/** Cloudpickle serialized model */
|
|
438
|
-
data: BlobType;
|
|
976
|
+
readonly data: BlobType;
|
|
439
977
|
/** Number of input features */
|
|
440
|
-
n_features: IntegerType;
|
|
978
|
+
readonly n_features: IntegerType;
|
|
979
|
+
/** Column indices of categorical features (for prediction) */
|
|
980
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
441
981
|
}>;
|
|
442
982
|
/** XGBoost classifier model */
|
|
443
|
-
xgboost_classifier: StructType<{
|
|
983
|
+
readonly xgboost_classifier: StructType<{
|
|
444
984
|
/** Cloudpickle serialized model */
|
|
445
|
-
data: BlobType;
|
|
985
|
+
readonly data: BlobType;
|
|
446
986
|
/** Number of input features */
|
|
447
|
-
n_features: IntegerType;
|
|
987
|
+
readonly n_features: IntegerType;
|
|
448
988
|
/** Number of classes */
|
|
449
|
-
n_classes: IntegerType;
|
|
989
|
+
readonly n_classes: IntegerType;
|
|
990
|
+
/** Column indices of categorical features (for prediction) */
|
|
991
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
992
|
+
}>;
|
|
993
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
994
|
+
readonly xgboost_quantile: StructType<{
|
|
995
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
996
|
+
readonly data: BlobType;
|
|
997
|
+
/** Quantiles this model predicts */
|
|
998
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
999
|
+
/** Number of input features */
|
|
1000
|
+
readonly n_features: IntegerType;
|
|
1001
|
+
/** Column indices of categorical features (for prediction) */
|
|
1002
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
450
1003
|
}>;
|
|
451
|
-
}>,
|
|
1004
|
+
}>, ArrayType<ArrayType<FloatType>>], StructType<{
|
|
1005
|
+
/** Quantile values that were predicted */
|
|
1006
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
1007
|
+
/** Predictions matrix: (n_samples x n_quantiles) */
|
|
1008
|
+
readonly predictions: ArrayType<ArrayType<FloatType>>;
|
|
1009
|
+
}>>;
|
|
452
1010
|
/** Type definitions */
|
|
453
1011
|
readonly Types: {
|
|
454
1012
|
/** Vector type (array of floats) */
|
|
455
|
-
readonly VectorType:
|
|
1013
|
+
readonly VectorType: ArrayType<FloatType>;
|
|
456
1014
|
/** Matrix type (2D array of floats) */
|
|
457
|
-
readonly MatrixType:
|
|
1015
|
+
readonly MatrixType: ArrayType<ArrayType<FloatType>>;
|
|
458
1016
|
/** Label vector type (array of integers) */
|
|
459
|
-
readonly LabelVectorType:
|
|
1017
|
+
readonly LabelVectorType: ArrayType<IntegerType>;
|
|
460
1018
|
/** XGBoost configuration type */
|
|
461
1019
|
readonly XGBoostConfigType: StructType<{
|
|
462
1020
|
/** Number of boosting rounds (default 100) */
|
|
463
|
-
n_estimators: OptionType<IntegerType>;
|
|
1021
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
1022
|
+
/** Maximum tree depth (default 6) */
|
|
1023
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
1024
|
+
/** Learning rate / step size shrinkage (default 0.3) */
|
|
1025
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
1026
|
+
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
1027
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
1028
|
+
/** Subsample ratio of training instances (default 1.0) */
|
|
1029
|
+
readonly subsample: OptionType<FloatType>;
|
|
1030
|
+
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
1031
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
1032
|
+
/** L1 regularization term (default 0) */
|
|
1033
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
1034
|
+
/** L2 regularization term (default 1) */
|
|
1035
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
1036
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
1037
|
+
readonly gamma: OptionType<FloatType>;
|
|
1038
|
+
/** Random seed for reproducibility */
|
|
1039
|
+
readonly random_state: OptionType<IntegerType>;
|
|
1040
|
+
/** Number of parallel threads (default -1 for all cores) */
|
|
1041
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
1042
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
1043
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
1044
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
1045
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
1046
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
1047
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
1048
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
1049
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
1050
|
+
}>;
|
|
1051
|
+
/** XGBoost quantile configuration type */
|
|
1052
|
+
readonly XGBoostQuantileConfigType: StructType<{
|
|
1053
|
+
/** Quantiles to predict (e.g., [0.1, 0.5, 0.9] for 80% interval + median) */
|
|
1054
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
1055
|
+
/** Number of boosting rounds (default 100) */
|
|
1056
|
+
readonly n_estimators: OptionType<IntegerType>;
|
|
464
1057
|
/** Maximum tree depth (default 6) */
|
|
465
|
-
max_depth: OptionType<IntegerType>;
|
|
1058
|
+
readonly max_depth: OptionType<IntegerType>;
|
|
466
1059
|
/** Learning rate / step size shrinkage (default 0.3) */
|
|
467
|
-
learning_rate: OptionType<FloatType>;
|
|
1060
|
+
readonly learning_rate: OptionType<FloatType>;
|
|
468
1061
|
/** Minimum sum of instance weight needed in a child (default 1) */
|
|
469
|
-
min_child_weight: OptionType<IntegerType>;
|
|
1062
|
+
readonly min_child_weight: OptionType<IntegerType>;
|
|
470
1063
|
/** Subsample ratio of training instances (default 1.0) */
|
|
471
|
-
subsample: OptionType<FloatType>;
|
|
1064
|
+
readonly subsample: OptionType<FloatType>;
|
|
472
1065
|
/** Subsample ratio of columns when constructing trees (default 1.0) */
|
|
473
|
-
colsample_bytree: OptionType<FloatType>;
|
|
1066
|
+
readonly colsample_bytree: OptionType<FloatType>;
|
|
474
1067
|
/** L1 regularization term (default 0) */
|
|
475
|
-
reg_alpha: OptionType<FloatType>;
|
|
1068
|
+
readonly reg_alpha: OptionType<FloatType>;
|
|
476
1069
|
/** L2 regularization term (default 1) */
|
|
477
|
-
reg_lambda: OptionType<FloatType>;
|
|
1070
|
+
readonly reg_lambda: OptionType<FloatType>;
|
|
1071
|
+
/** Minimum loss reduction required to make a further partition (default 0) */
|
|
1072
|
+
readonly gamma: OptionType<FloatType>;
|
|
478
1073
|
/** Random seed for reproducibility */
|
|
479
|
-
random_state: OptionType<IntegerType>;
|
|
1074
|
+
readonly random_state: OptionType<IntegerType>;
|
|
480
1075
|
/** Number of parallel threads (default -1 for all cores) */
|
|
481
|
-
n_jobs: OptionType<IntegerType>;
|
|
1076
|
+
readonly n_jobs: OptionType<IntegerType>;
|
|
1077
|
+
/** Sample weights for training (one per sample, default uniform) */
|
|
1078
|
+
readonly sample_weight: OptionType<ArrayType<FloatType>>;
|
|
1079
|
+
/** Column indices that contain categorical features (0-indexed) */
|
|
1080
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
1081
|
+
/** Max categories for one-hot encoding (default 4). Features with more categories use partition-based splits. */
|
|
1082
|
+
readonly max_cat_to_onehot: OptionType<IntegerType>;
|
|
1083
|
+
/** Max categories considered per split for partition-based method (default 64). */
|
|
1084
|
+
readonly max_cat_threshold: OptionType<IntegerType>;
|
|
1085
|
+
}>;
|
|
1086
|
+
/** Quantile prediction result type */
|
|
1087
|
+
readonly XGBoostQuantilePredictResultType: StructType<{
|
|
1088
|
+
/** Quantile values that were predicted */
|
|
1089
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
1090
|
+
/** Predictions matrix: (n_samples x n_quantiles) */
|
|
1091
|
+
readonly predictions: ArrayType<ArrayType<FloatType>>;
|
|
482
1092
|
}>;
|
|
483
1093
|
/** Model blob type for XGBoost models */
|
|
484
1094
|
readonly ModelBlobType: VariantType<{
|
|
485
1095
|
/** XGBoost regressor model */
|
|
486
|
-
xgboost_regressor: StructType<{
|
|
1096
|
+
readonly xgboost_regressor: StructType<{
|
|
487
1097
|
/** Cloudpickle serialized model */
|
|
488
|
-
data: BlobType;
|
|
1098
|
+
readonly data: BlobType;
|
|
489
1099
|
/** Number of input features */
|
|
490
|
-
n_features: IntegerType;
|
|
1100
|
+
readonly n_features: IntegerType;
|
|
1101
|
+
/** Column indices of categorical features (for prediction) */
|
|
1102
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
491
1103
|
}>;
|
|
492
1104
|
/** XGBoost classifier model */
|
|
493
|
-
xgboost_classifier: StructType<{
|
|
1105
|
+
readonly xgboost_classifier: StructType<{
|
|
494
1106
|
/** Cloudpickle serialized model */
|
|
495
|
-
data: BlobType;
|
|
1107
|
+
readonly data: BlobType;
|
|
496
1108
|
/** Number of input features */
|
|
497
|
-
n_features: IntegerType;
|
|
1109
|
+
readonly n_features: IntegerType;
|
|
498
1110
|
/** Number of classes */
|
|
499
|
-
n_classes: IntegerType;
|
|
1111
|
+
readonly n_classes: IntegerType;
|
|
1112
|
+
/** Column indices of categorical features (for prediction) */
|
|
1113
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
1114
|
+
}>;
|
|
1115
|
+
/** XGBoost quantile regressor (multiple models, one per quantile) */
|
|
1116
|
+
readonly xgboost_quantile: StructType<{
|
|
1117
|
+
/** Cloudpickle serialized dict of {quantile: model} */
|
|
1118
|
+
readonly data: BlobType;
|
|
1119
|
+
/** Quantiles this model predicts */
|
|
1120
|
+
readonly quantiles: ArrayType<FloatType>;
|
|
1121
|
+
/** Number of input features */
|
|
1122
|
+
readonly n_features: IntegerType;
|
|
1123
|
+
/** Column indices of categorical features (for prediction) */
|
|
1124
|
+
readonly categorical_features: OptionType<ArrayType<IntegerType>>;
|
|
500
1125
|
}>;
|
|
501
1126
|
}>;
|
|
502
1127
|
};
|