from spotforecast2.manager.multitask import LazyTask
task = LazyTask(data_frame_name="demo10", predict_size=24)
print(f"Task: {task.TASK}")
print(f"Predict size: {task.config.predict_size}")Task: lazy
Predict size: 24
manager.multitask.LazyTask(
dataframe=None,
data_test=None,
data_frame_name='default',
cache_home=None,
agg_weights=None,
index_name='DateTime',
number_folds=10,
predict_size=24,
bounds=None,
contamination=0.03,
imputation_method='weighted',
use_exogenous_features=True,
n_trials_optuna=15,
n_trials_spotoptim=10,
n_initial_spotoptim=5,
auto_save_models=True,
train_days=365 * 2,
val_days=7 * 2,
log_level=logging.INFO,
verbose=False,
**config_overrides,
)Task 1 — Lazy Fitting with default LightGBM parameters.
Creates an unfitted forecaster per target and fits with default hyperparameters. No cross-validation or tuning is performed.
When cached tuning results are available (saved by OptunaTask or SpotOptimTask), they are loaded and applied automatically so that the lazy task benefits from prior tuning without re-running the search.
| Name | Description |
|---|---|
| run | Run lazy fitting for all targets. |
Run lazy fitting for all targets.
| Name | Type | Description | Default |
|---|---|---|---|
| show | bool | If True, display prediction figures. |
True |
| use_tuned_params | bool | If True, load and apply cached tuning results for each target. |
True |
| max_age_days | Optional[float] | Maximum age in days for cached tuning results. None accepts any age. |
None |
| Name | Type | Description |
|---|---|---|
| Dict[str, Any] | Aggregated prediction package. Per-target packages are stored | |
| Dict[str, Any] | on self.results["lazy"]. |