v1.0.0 —
First Stable Release
Released: 2025
V2 Architecture
Introduced
BaseAttentiveSpecandBaseAttentiveComponentSpecfrozen dataclasses for backend-neutral model configuration; replaces ad-hoc dicts with a typed, validated schema.New
ComponentRegistryandModelRegistryclasses for pluggable component and model registration keyed by(name, backend).New
BaseAttentiveV2Assemblyresolver/assembly pattern for constructing models from specs; enables full backend portability.Registered
projection.densekey in the generic V2 component registry (fallback for all backends).
New BaseAttentive Parameters
mode— operational mode shortcut:'tft','tft_like','pihal','pihal_like', orNone.attention_levels— declarative attention stack control; accepts string, list, int (1=cross, 2=hierarchical, 3=memory), orNone.scales— explicit multi-scale LSTM strides, e.g.[1, 2, 4]or'auto'.multi_scale_agg— how to merge multi-scale outputs:'last','average','flatten','sum','concat'.final_agg— final sequence aggregation:'last','average','flatten'.num_encoder_layers— configurable encoder depth (default: 2).vsn_units— override VSN projection size independently ofembed_dim.max_window_size— maximum dynamic time window size (default: 10).memory_size— memory bank size for memory-augmented attention (default: 100).apply_dtw— toggle Dynamic Time Warping alignment (default: True).
New Backend Utilities
normalize_backend_name(name)— normalises aliases (e.g."tf"→"tensorflow").detect_available_backends()— returns availability and version info for all installed backends.select_best_backend(require_supported)— selects best available backend automatically.ensure_default_backend(auto_install)— guarantees a backend is ready.check_tensorflow_compatibility()— returns(bool, msg).check_torch_compatibility()— returns(bool, msg).get_backend_version(name)— returns installed version string.version_at_least(version_str, minimum)— version comparison.TorchDeviceManagerclass — CUDA / MPS / CPU device management with lazy selection, cache clearing, and device info reporting.
New Components
TransformerEncoderBlock/TransformerDecoderBlock— stacked transformer encoder/decoder blocks with configurablenum_layers.PointForecastHead(output_dim, forecast_horizon)— dense point forecast output head.QuantileHead(quantiles, output_dim, forecast_horizon)— separate projection per quantile level.GaussianHead(output_dim)— outputs mean and log-variance for a Gaussian predictive distribution.MixtureDensityHead(num_components, output_dim)— Gaussian Mixture Model forecast head.TSPositionalEncoding(max_position, embed_dim)— time-series positional encoding with explicit position and embedding dimensions.AdaptiveQuantileLoss(quantiles)— adaptive quantile regression loss.MultiObjectiveLoss()— combines multiple loss terms.CRPSLoss()— Continuous Ranked Probability Score.AnomalyLoss()— loss for anomaly-aware training.Gate(units)— GLU-style gating layer.LayerScale(init_value)— per-channel learnable scaling (ViT-style).SqueezeExcite1D(ratio)— squeeze-and-excite for 1D sequences.StochasticDepth(drop_rate)— stochastic depth / drop-path.
Component Utilities
resolve_attn_levels(att_levels)— canonical attention list from any supported input form.configure_architecture(objective, use_vsn, attention_levels, architecture_config)— merges defaults with user arguments into a final architecture config dict.resolve_fusion_mode(fusion_mode)— returns'integrated'or'disjoint'.
Bug Fixes
Fixed relative import depth in
components/utils.py(3-level...utils→ 2-level..utils), resolvingImportErroron direct module import.Registered
"projection.dense"in the generic V2 component registry, fixingKeyError: "Unknown component key: 'projection.dense'"on backend fallback.
Documentation
Full documentation site rewrite for v2 API: all 14 RST pages updated with correct constructor signatures, new parameters, new architecture sections (registry / resolver / assembly), and backend utilities.
Custom Sphinx CSS theme with brand colors (primary
#92278f, secondary#ee2a7b).HTML README header with centered logo and badges.
Dependencies
Keras >= 3.0.0 required; TensorFlow, JAX, and PyTorch supported as backends via Keras 3 multi-backend.
NumPy >= 1.23, scikit-learn >= 1.2 required.
Python 3.10+ required (3.9 no longer supported).
Internal
Comprehensive test suite covering components, backend utilities, compatibility layer, registry, validation, and implementations modules.
Test coverage improved significantly with 6 new test files.
from __future__ import annotationsadded throughout for forward-reference compatibility.