Skip to content

v0.1.9

Latest

Choose a tag to compare

@ryuta-yoshimatsu ryuta-yoshimatsu released this 07 Nov 19:02
1b922b0

What's Changed

New Features & Enhancements

  • 19 foundation models through foundationforecast (#212): new framework: FoundationForecast models (FF*) that use the existing foundation flow (evaluate, register to Unity Catalog, score). They are installed with a new foundationforecast extra, which must not be installed alongside the foundation extra because the two pin different torch / transformers versions.

    • Models: FFChronos2, FFChronos2Small, FFTimesFM_2_5_200m, FFTimesFM_3_0, FFTiRex2, FFToto, FFToto2_22m / _313m / _1B, FFFlowState, FFPatchTSTFM_R1 / _R2, FFTafsutBase, FFT0Beta, FFT0Gamma and FFTimestral_5M / _28M / _123M / _209M.
    • Licenses: FFTimesFM_3_0 and FFPatchTSTFM_R1 are non-commercial, and the Timestral checkpoints use Mistral's Modified MIT license; each logs a warning when instantiated. See FoundationForecast models.
    • Compute: a single GPU on a classic DBR 18 ML cluster or on serverless GPU (A10, AI v6). Prediction runs on the driver's GPU.
    • PyTorch CUDA 12.8 build: install the extra with --extra-index-url https://download.pytorch.org/whl/cu128. PyPI's torch==2.11.0 targets CUDA 13 and fails on drivers that only support CUDA 12.8. Registered models pin torch==2.11.0+cu128 / torchvision==0.26.0+cu128.
    • GPU memory: the previous checkpoint is released when switching models, which lowered peak GPU memory from 10.7 to 7.8 GB on classic and to 4.6 GB on serverless for 14 models in one process.
    • Input checks: missing target values and, for freq: M, non-month-end dates raise DataPreparationError instead of producing wrong forecasts.
  • Known-future covariates for foundationforecast models (#229): dynamic_future_numerical / dynamic_future_categorical are passed to the models in backtesting and scoring, and models registered in Unity Catalog accept them at inference time.

    • Models that use them: FFChronos2, FFChronos2Small, FFTimesFM_3_0, FFTiRex2, FFT0Beta, FFT0Gamma and the four Timestral models. The others warn once and forecast univariate.
    • Static and historical-only covariates are still ignored, with a warning. Only Chronos-2 accepts string categoricals; the other models need numeric or label-encoded values.
    • On 1,000 synthetic monthly series, FFTimesFM_3_0 sMAPE improved from 0.0804 without covariates to 0.0582 with them.
  • Foundationforecast example notebooks on M5 with covariates (#212, #231): daily, weekly and monthly notebooks on the top 500 M5 (Walmart) items, with sell_price, snap_days and event_days as known-future covariates. Each runs all 19 models, optionally compares the covariate models with and without covariates, and scores a registered FFChronos2 model from Unity Catalog.

  • MMF Agent: foundationforecast models and serverless GPU (#233):

    • Foundationforecast as a fifth model class in Skills 1–5, with its own job (its torch build can't share an environment with [foundation]).
    • Serverless GPU (one A10, AI v6) for global DL, foundation and foundationforecast. Skill 3 recommends it, and recommends classic for GCP, multi-GPU NeuralForecast, or regions with persistent A10 shortages.
    • New templates: mmf_gpu_serverless_notebook_template.ipynb (one notebook per GPU class, looping over its models) and serverless_gpu_ai_v6_environment.yml for workspaces that reject workspace-base-environments/databricks_ai_v6.
    • Reproducible data prep: mmf_prep_notebook_template.ipynb now replays all of Skill 1: covariates, the scoring table and its NULL rules, label encoding, per-series imputation, IQR capping, removal of orphan scoring series and the cleaning report. Verified row for row against the interactive Skill 1 output.
    • Moirai is no longer mentioned in the skills.

Bug Fixes & Improvements

  • Skills fixes from an end-to-end run of Skills 1–5 on AWS and Azure (#233):
    • Skill 1: SQL that is valid on Databricks (LAST_VALUE(x) IGNORE NULLS, MERGE instead of UPDATE … FROM, CTAS instead of ALTER COLUMN TYPE for casts Delta rejects), and fixed step references.
    • Skill 2: each non-forecastable strategy writes its own scoring tables (_scoring_data_forecastable / _non_forecastable).
    • Skill 3: an explicit instance-availability block for every classic cluster (on-demand driver; optional spot with fallback for multi-node CPU workers), since the AWS default puts the driver on spot. Steps renumbered.
    • Skill 4:
      • Non-forecastable notebooks and jobs are generated with the others.
      • Every job name ends in _{username}.
      • Single-node jobs get the right Spark settings.
      • New Step 5d pre-creates the output tables, because concurrent jobs creating the same table fail one model with TABLE_OR_VIEW_ALREADY_EXISTS.
      • Step 6 counts a job as passed only if every model wrote rows.
    • Skill 5 and the post-process template: Step 2 uses each model's latest run and computes WAPE, the summary column is named after the metric, and non-forecastable results are merged per strategy.
    • install.py now installs every skill file, including the global ML template, Skill 6 and the reconciliation template.
  • Serverless examples moved from the Standard v5 to the AI v6 environment (#233).
  • Removed the unused skills/.test harness and fixed the Skills CI (#227), so Dependabot no longer opens PRs for it.

Dependency Updates

  • New foundationforecast extra and requirements-foundationforecast.txt (#212): foundationforecast==0.1.15, torch==2.11.0 (+cu128 in the requirements file), transformers==5.12.1, tfc-t0[torch]==0.6.0, timecopilot-timestral==0.1.0 and the other TimeCopilot model packages, with datasets>=4,<5 and pyarrow<24 to keep pip from backtracking for over 30 minutes.
  • skills/.test (dependabot, before the harness was removed): gitpython 3.1.62 → 3.2.1 (#222), opentelemetry-api 1.39.1 → 1.45.1 (#223), graphql-core 3.2.7 → 3.2.12 (#224), setuptools 83.0.0 → 84.1.0 (#225), mlflow 3.16.0 → 3.17.2 (#226).

Upgrade Notes

  • To use the foundationforecast models, install the extra in its own environment (not with [foundation]), with the CUDA 12.8 PyTorch index:
    pip install "mmf_sa[foundationforecast] @ git+https://github.com/databricks-industry-solutions/many-model-forecasting.git@v0.1.9" --extra-index-url https://download.pytorch.org/whl/cu128
  • Check the licenses of FFTimesFM_3_0, FFPatchTSTFM_R1 and the Timestral models before commercial use.
  • Re-install MMF Agent (install.py) to get the updated skills and the new templates.
  • No breaking changes to run_forecast or to the existing model classes.
    pip install "mmf_sa[foundation] @ git+https://github.com/databricks-industry-solutions/many-model-forecasting.git@v0.1.9"

Full Changelog: v0.1.8...v0.1.9