Sinapsis SKTime
Module for handling time series data and forecasting using sktime.
🐍 Installation • 🚀 Features • 📚 Usage Example • 📙 Documentation • 🔍 License
Sinapsis SKTime provides a powerful and flexible implementation for time series forecasting using the sktime library.
🐍 Installation
Install using your package manager of choice. We encourage the use of uv
Example with uv:
uv pip install sinapsis-sktime --extra-index-url https://pypi.sinapsis.tech
or with raw pip:
pip install sinapsis-sktime --extra-index-url https://pypi.sinapsis.tech
🚀 Features
Templates Supported
The Sinapsis SKTime provides a powerful and flexible implementation for time series forecasting using the sktime library.
ThetaForecaster
The following attributes apply to ThetaForecaster template:
generic_field_key_data(str, required): The key of the generic field containing the time series data.
This template loads time series data from the specified generic field key and creates a TimeSeriesPacket which is then added to the DataContainer.
SKTime Forecasters
The following attributes apply to all SKTime forecasting templates:
generic_field_for_data(str, optional): The key of the generic field where datasets are stored. Defaults to "SKTimeDatasets".model_save_path(str, required): Path where the trained model will be saved.n_steps_ahead(int, optional): Number of steps ahead to forecast. Defaults to 37.
The package provides access to a wide range of forecasting models from sktime, including:
- ARCH
- StatsForecastARCH
- StatsForecastGARCH
- ARIMA
- AutoARIMA
- ExponentialSmoothing
- StatsModelsARIMA
- NaiveForecaster
- NaiveVariance
- ThetaForecaster
- ThetaModularForecaster
- TrendForecaster
- PolynomialTrendForecaster
[!TIP] Use CLI command
sinapsis info --all-template-namesto show a list with all the available Template names installed with Sinapsis SKTime.
[!TIP] Use CLI command
sinapsis info --example-template-config TEMPLATE_NAMEto produce an example Agent config for the Template specified in TEMPLATE_NAME.
For example, for ThetaForecaster use sinapsis info --example-template-config ThetaForecasterSKTimeWrapper to produce the following example config:
agent:
name: my_test_agent
templates:
- template_name: InputTemplate
class_name: InputTemplate
attributes: {}
- template_name: ThetaForecasterSKTimeWrapper
class_name: ThetaForecasterSKTimeWrapper
template_input: InputTemplate
attributes:
root_dir: '`replace_me:<class ''str''>`'
model_save_path: '`replace_me:<class ''str''>`'
n_steps_ahead: 37
thetaforecaster_init:
initial_level: null
deseasonalize: true
sp: 1
deseasonalize_model: multiplicative
📚 Usage Example
Below is an example configuration for **Sinapsis SKTime** using a Theta forecasting model. This setup loads time series data into a TimeSeriesPacket and applies the Theta model for forecasting.Example config
agent:
name: ThetaForecasterAgent
description: 'Agent for time series forecasting using Theta'
templates:
- template_name: InputTemplate
class_name: InputTemplate
attributes: {}
- template_name: load_airlineWrapper
class_name: load_airlineWrapper
template_input: InputTemplate
attributes:
split_dataset: true
train_size: 0.8
store_as_time_series: True
load_airline:
{}
- template_name: ThetaForecasterSKTimeWrapper
class_name: ThetaForecasterSKTimeWrapper
template_input: load_airlineWrapper
attributes:
generic_field_key: load_airlineWrapper
n_steps_ahead: 12
forecast_horizon_in_fit: true
model_save_path: "artifacts/theta_forecaster.pkl"
task_type: "forecasting"
thetaforecaster_init:
sp: 12
This configuration defines an agent and a sequence of templates to handle the data and perform predictions.
To run the config, use the CLI:
sinapsis run name_of_config.yml
📙 Documentation
Documentation for this and other sinapsis packages is available on the sinapsis website
Tutorials for different projects within sinapsis are available at sinapsis tutorials page
🔍 License
This project is licensed under the AGPLv3 license, which encourages open collaboration and sharing. For more details, please refer to the LICENSE file.
For commercial use, please refer to our official Sinapsis website for information on obtaining a commercial license.
Metadata
Release files for sinapsis-sktime 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| sinapsis_sktime-0.1.0.tar.gz | 45.4 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| sinapsis_sktime-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 67.1 kB
Release files / sinapsis_sktime-0.1.0.tar.gz
| Download URL | sinapsis_sktime-0.1.0.tar.gz |
|---|---|
| Size | 45.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d4e8723018e86d6928cab1e6a45b90889203eb944936833007a4c20d09529cd6
|
|
BLAKE2b-256 checksum How to use checksums |
5fa1c452c3df1f39450688a996b98fcd68d5094f2f5a23a5e7cbac404cbe122e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.5.16
|
Release files / sinapsis_sktime-0.1.0-py3-none-any.whl
| Download URL | sinapsis_sktime-0.1.0-py3-none-any.whl |
|---|---|
| Size | 21.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
04c57491a4509cdbdfb597b66a06eb00dfbcd3f531c5c8df7fbe50c20c074eb0
|
|
BLAKE2b-256 checksum How to use checksums |
9178b1b70a7387eebd8ec6c7d3a3eca91db61db52c64d891a1f8fec0ade39633
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.5.16
|