Skip to content
Back to skills

Time Series Library

ASecurity

"Use Time-Series-Library (TSLib) to configure, run, debug, and

  • 247 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 9, 2026
researchpythonshellbashdebugging

Works with

  • cli

Security analysis

A100/100

Pro scans all 20 files and shows the line behind each finding

Scanned September 9, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill time-series-library --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Time Series Library?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Time Series Library
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-time-series-library/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-time-series-library)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: time-series-library
description: "Use Time-Series-Library (TSLib) to configure, run, debug, and
  adapt deep time-series forecasting, imputation, anomaly detection,
  classification, zero-shot, and model-customization workflows."
disable-model-invocation: true
metadata:
  disco-role: operating
license: MIT
---

# Time-Series-Library (TSLib)

Use this skill when the task names Time-Series-Library, TSLib, `run.py`, TimesNet, TimeXer, iTransformer, PatchTST, DLinear, M4, ETT, UEA, PSM/MSL/SMAP/SMD/SWAT, long-term forecasting, short-term forecasting, time-series imputation, anomaly detection, classification, zero-shot forecasting, or adapting a model/script inside a TSLib-style checkout.

## Start Here

1. Confirm the environment and source layout before running training-scale work. From this skill directory, pass the user's TSLib checkout as `--repo-root`:
   ```bash
   python scripts/check_tslib_environment.py --repo-root /path/to/Time-Series-Library --check-torch --check-core-imports
   ```
2. For command/data debugging, create a tiny local `custom` CSV in the user's checkout instead of downloading benchmark data:
   ```bash
   python scripts/create_tiny_tslib_dataset.py --output /path/to/Time-Series-Library/dataset/tiny-custom/tiny.csv
   ```
3. Use the route map below. TSLib has one unified CLI (`python run.py ...`), but each task has different data layouts, output files, metrics, and failure modes.
4. Prefer `--no_use_gpu`, tiny custom data, `--train_epochs 1`, and `--num_workers 0` for smoke checks. Treat upstream benchmark scripts as templates, not as safe default commands.

## Route by Task

- **Data layout, CLI flags, outputs, and preflight checks**: use `sub-skills/data-and-cli/SKILL.md` for `run.py` arguments, dataset names, local-vs-Hugging Face fallback behavior, GPU flags, result/checkpoint folders, and safe data validation.
- **Forecasting workflows**: use `sub-skills/forecasting/SKILL.md` for long-term forecasting, short-term/M4 forecasting, exogenous/TimeXer recipes, zero-shot forecast routing, metrics, M4 summary behavior, and forecast command construction.
- **Imputation, anomaly detection, and classification**: use `sub-skills/imputation-anomaly-classification/SKILL.md` for masked reconstruction, reconstruction-threshold anomaly detection, UEA classification, task metrics, and dataset-specific troubleshooting.
- **Model catalog, optional dependencies, and customization**: use `sub-skills/foundation-models-and-customization/SKILL.md` for dynamic model discovery, Mamba and large time-series model dependencies, augmentation flags, custom `models/<Name>.py` files, and contribution-style script additions.

## Core Mental Model

TSLib is a source-tree benchmark framework rather than a packaged library with console entry points. The normal flow is:

```text
choose a task and bash/script template -> run python run.py with explicit flags ->
run.py dispatches to exp/Exp_* -> data_provider builds datasets/loaders ->
models/<Name>.py is lazy-imported -> train/test writes checkpoints, metrics, and result files
```

Important consequences:

- `--task_name` selects the experiment class, not just reporting labels.
- `--data` selects a loader family; `--root_path` and `--data_path` must match that family.
- `--model` must match a Python file under `models/`; `Exp_Basic` scans that directory dynamically.
- Many upstream shell scripts export `CUDA_VISIBLE_DEVICES` and run full benchmark settings. Remove or change those exports for your machine and use smoke settings first.
- Several optional model families need extra packages or model downloads; do not assume a basic TSLib environment can import every file in `models/`.

## References

- `references/installation-and-environment.md` explains public installation choices, optional dependencies, and safe smoke checks.
- `references/cli-arguments.md` summarizes the unified `run.py` argument families and task dispatch.
- `references/data-formats.md` documents CSV, M4, anomaly, and UEA layouts plus local-vs-Hub behavior.
- `references/model-catalog.md` lists model families, dynamic discovery, and optional dependency surfaces.
- `references/troubleshooting.md` covers cross-cutting install/import, data, CLI, GPU, output, and source-tree issues.
- `references/repo-provenance.md` records the source revision and evidence baseline.

## Helpers

- `scripts/check_tslib_environment.py` checks Python imports, selected models, `run.py --help`, and optional torch CUDA status without training; pass `--repo-root` for the user's TSLib checkout.
- `scripts/create_tiny_tslib_dataset.py` creates a small local `custom` CSV with a `date` column and target column for smoke commands.

## Operating Rules

- Do not run benchmark-scale scripts or download large datasets/model weights unless the user explicitly wants that cost.
- Do not recommend a raw upstream `scripts/.../*.sh` command without checking its `CUDA_VISIBLE_DEVICES`, dataset path, epochs, model dependencies, and output folders.
- Use local tiny fixtures for CLI/data validation; use real benchmark data only for final experiment work.
- Treat Mamba/MambaSL and large time-series model files as optional dependency routes. First decide whether the user's task requires them; otherwise choose a core model such as DLinear, TimesNet, TimeXer, PatchTST, or Transformer for smoke checks.
- Keep generated commands generic and portable across TSLib checkouts; never rely on a particular local checkout path.

Files in this skill

  • SKILL.md5.4 KB
  • references/cli-arguments.md3.9 KB
  • references/data-formats.md3.2 KB
  • references/installation-and-environment.md4.6 KB
  • references/model-catalog.md3.6 KB
  • references/repo-provenance.md1.4 KB
  • references/repo-routing-metadata.json513 B
  • references/troubleshooting.md4 KB
  • scripts/check_tslib_environment.py4.8 KB
  • scripts/create_tiny_tslib_dataset.py1.9 KB
  • sub-skills/data-and-cli/SKILL.md4.1 KB
  • sub-skills/data-and-cli/references/cli-and-outputs.md2.9 KB
  • sub-skills/data-and-cli/references/data-layouts.md2.6 KB
  • sub-skills/data-and-cli/references/troubleshooting.md2.1 KB
  • sub-skills/data-and-cli/scripts/validate_tslib_data.py3.7 KB
  • sub-skills/forecasting/SKILL.md3.5 KB
  • sub-skills/forecasting/references/forecasting-workflows.md2.7 KB
  • sub-skills/forecasting/references/metrics-and-results.md1.6 KB
  • sub-skills/forecasting/references/troubleshooting.md2.2 KB
  • sub-skills/forecasting/scripts/build_tslib_command.py6.4 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.