# Timesfm Forecasting

Zero-shot time series forecasting with Google's TimesFM foundation model.

- Repository: https://github.com/zLanqing/codex-claude-academic-skills (5550 stars)
- Category: Business
- License: Apache-2.0 license
- Last updated: 2026-05-14
- Runs scripts: yes, review before use

## Install

Claude Code: `npx skills add zLanqing/codex-claude-academic-skills --skill timesfm-forecasting -g -a claude-code -y`
Codex: `npx skills add zLanqing/codex-claude-academic-skills --skill timesfm-forecasting -g -a codex -y`
Cursor: `npx skills add zLanqing/codex-claude-academic-skills --skill timesfm-forecasting -g -a cursor -y`
Gemini CLI: `npx skills add zLanqing/codex-claude-academic-skills --skill timesfm-forecasting -g -a gemini-cli -y`

## Description

Zero-shot time series forecasting with Google's TimesFM foundation model. Use for any univariate time series (sales, sensors, energy, vitals, weather) without training a custom model. Supports CSV/DataFrame/array inputs with point forecasts and prediction intervals. Includes a preflight system checker script to verify RAM/GPU before first use.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# TimesFM Forecasting

## Overview

TimesFM (Time Series Foundation Model) is a pretrained decoder-only foundation model
developed by Google Research for time-series forecasting. It works **zero-shot**, feed it
any univariate time series and it returns point forecasts with calibrated quantile
prediction intervals, no training required.

This skill wraps TimesFM for safe, agent-friendly local inference. It includes a
**mandatory preflight system checker** that verifies RAM, GPU memory, and disk space
before the model is ever loaded so the agent never crashes a user's machine.

> **Key numbers**: TimesFM 2.5 uses 200M parameters (~800 MB on disk, ~1.5 GB in RAM on
> CPU, ~1 GB VRAM on GPU). The archived v1/v2 500M-parameter model needs ~32 GB RAM.
> Always run the system checker first.

## When to Use This Skill

Use this skill when:

- Forecasting **any univariate time series** (sales, demand, sensor, vitals, price, weather)
- You need **zero-shot forecasting** without training a custom model
- You want **probabilistic forecasts** with calibrated prediction intervals (quantiles)
- You have time series of **any length** (the model handles 1, 16,384 context points)
- You need to **batch-forecast** hundreds or thousands of series efficiently
- You want a **foundation model** approach instead of hand-tuning ARIMA/ETS parameters

Do **not** use this skill when:

- You need classical statistical models with coefficient interpretation → use `statsmodels`
- You need time series classification or clustering → use `aeon`
- You need multivariate vector autoregression or Granger causality → use `statsmodels`
- Your data is tabular (not temporal) → use `scikit-learn`

> **Note on Anomaly Detection**: TimesFM does not have built-in anomaly detection, but you can
> use the **quantile forecasts as prediction intervals**, values outside the 90% CI (q10, q90)
> are statistically unusual. See the `examples/anomaly-detection/` directory for a full example.

The rest: https://github.com/zLanqing/codex-claude-academic-skills/blob/HEAD/scientific-toolkit-skill/references/scientific-skills/timesfm-forecasting/SKILL.md
