Agent skill

Garch Method

by milesdeutscher in milesdeutscher/garchmethod

Volatility forecasting and position sizing via walk-forward GARCH(1,1).

MITAuto-check passedData & Analytics

Install Garch Method

skills CLI
$ npx skills add milesdeutscher/garchmethod --skill garch-method -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install milesdeutscher/garchmethod garch-method --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/milesdeutscher/garchmethod.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/garch .claude/skills/garch-method && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
garch-method
GitHub stars
191
Token cost
~1k tokens
SKILL.md length
431 words
Files
1
Skills in repo
1
Repo updated
First seen
Licence
MIT

At a glance

Volatility forecasting and position sizing via walk-forward GARCH(1,1).

  • Works in 3 steps: garch_forecast.py — the forecast → vol_target.py — the size → compare.py — the honest test
  • The user asks about volatility forecasts
  • SKILL.md covers The three tools, JSON contract, Three composition patterns and Defaults & conventions, plus 1 more section
  • Calls uv

What it does

Garch Method is an agent skill from milesdeutscher/garchmethod. Volatility forecasting and position sizing via walk-forward GARCH(1,1). Use whenever the user asks about volatility forecasts, position sizing, "how much should I put on", vol targeting, risk throttling, storm/calm regimes, or wants to test whether vol-targeted sizing improves an existing strategy. Works on any ticker (yfinance) or any CSV with date + close columns. Answers "how much" — never "which way".

Its SKILL.md is about 1k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Data & Analytics, covering Forecasting and time series, Stock and market analysis and CSV and tabular files. It works with yfinance. The licence is MIT.

When your agent uses it

  • The user asks about volatility forecasts
  • Position sizing
  • How much should I put on
  • Risk throttling

Example prompts

  • “how much should I put on”
  • “how much”
  • “which way”
  • “/garch-method”

Workflow steps

3 steps, taken from the step headings in SKILL.md.

  1. garch_forecast.py — the forecast
  2. vol_target.py — the size
  3. compare.py — the honest test

What it can do on your machine

Read from SKILL.md and the folder at commit e1e93d9. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • uv

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md. Its commands use uv, which can reach the network depending on how they are called.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Garch Method loads about 1k tokens when it runs. Until then it costs about 105 tokens; SKILL.md has 431 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~105
When it runs · the whole SKILL.md, loaded when a task matches
~1k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from milesdeutscher/garchmethod at commit e1e93d9, republished under its MIT licence (© milesdeutscher). 431 words, ~1,031 tokens.

Download SKILL.mdSave it as .claude/skills/garch-method/SKILL.md (or your agent's skills folder).
name
garch-method
description
Volatility forecasting and position sizing via walk-forward GARCH(1,1). Use whenever the user asks about volatility forecasts, position sizing, "how much should I put on", vol targeting, risk throttling, storm/calm regimes, or wants to test whether vol-targeted sizing improves an existing strategy. Works on any ticker (yfinance) or any CSV with date + close columns. Answers "how much" — never "which way".

GARCH Method — volatility forecasting + position sizing

This skill answers the question retail never asks and every fund asks daily: how much?

It does NOT predict direction. GARCH forecasts the magnitude of moves — how violent tomorrow is likely to be, not which way it goes. Say this to the user whenever presenting results.

The three tools

All scripts live in scripts/ and run with uv run (dependencies resolve automatically via inline metadata — nothing to pip-install).

1. garch_forecast.py — the forecast

Walk-forward GARCH(1,1), zero lookahead (params re-estimated every 21 days on an expanding window; the recursion rolls forward between refits using only past data).

uv run scripts/garch_forecast.py --csv prices.csv --json
uv run scripts/garch_forecast.py --ticker BTC-USD --json

Output: 1-day-ahead vol forecast (daily + annualized), vol percentile vs trailing year, regime (calm / normal / storm).

2. vol_target.py — the size

The entire idea: size = target_vol / forecast_vol, capped at [0.25x, 2.0x].

uv run scripts/vol_target.py --csv prices.csv --target-vol 15 --json

Output: position size multiplier. "Run 0.6x your baseline" — that's the answer.

3. compare.py — the honest test

Runs the same signals twice — fixed size vs vol-targeted — and shows both equity curves plus stats side by side. Ships with an EMA 9/21 crossover demo; accepts any strategy via --signals mine.csv (columns: date, signal in {-1,0,1}).

uv run scripts/compare.py --csv prices.csv --target-vol 58 --chart equity.png --json
uv run scripts/compare.py --csv prices.csv --signals mine.csv

Output: CAGR, ann vol, Sharpe, max drawdown, worst month, final equity — both versions — plus the equity-curve chart with storm regimes shaded.

JSON contract

Every script supports --json. Core output shape:

json
{
  "as_of": "2026-05-23",
  "forecast_vol_annualized_pct": 41.2,
  "vol_percentile_1y": 78.0,
  "regime": "storm",
  "position_size_multiplier": 0.6,
  "note": "GARCH forecasts magnitude (volatility), not direction."
}
Show full SKILL.md (218 more words)Show less

Three composition patterns

A. Sizing layer — bolt onto any existing strategy. Your strategy decides if; this skill decides how much. Take the strategy's signal, multiply by position_size_multiplier, done.

B. Risk throttle — standalone kill-switch. If regime == "storm", cut all exposure to the multiplier regardless of what your signals say. Works with any agent that manages positions.

C. Comparison harness — before trusting any strategy, run it through compare.py and check whether vol targeting improves its Sharpe / drawdown. If sizing doesn't help, the strategy's edge may be too weak to survive real conditions.

Composes cleanly with regime-direction skills (e.g. Markov-style bull/bear classifiers): their output answers which way, this answers how much. Multiply the two.

Defaults & conventions

  • Crypto: --periods-per-year 365 (default). Stocks: --periods-per-year 252.
  • Target vol: 15% is a sane conservative default. For a risk-matched comparison against an unlevered strategy, set target approximately equal to the strategy's own realized vol.
  • Data: yfinance ticker (needs internet) or any CSV with date + close columns — drops into whatever pipeline the user already runs.
  • Minimum history: ~510 daily observations before the first forecast.

Honesty rules (non-negotiable)

  1. Never present GARCH output as a direction call.
  2. Never hide the drawdown or worst-month numbers when reporting a comparison.
  3. If vol targeting does NOT improve the user's strategy, say so plainly — that result is just as valuable.

© milesdeutscher, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/garch of milesdeutscher/garchmethod.

Open the folder on GitHubat commit e1e93d9

Compare with similar skills

Garch Method next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Garch Method compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Garch Method this skillmilesdeutscher/garchmethod191—~1kAutomated safety check: PassMIT
Regimejackson-video-resources/markov-hedge-fund-method483—~1.6kAutomated safety check: PassCustom licence
Exploring Dataoaustegard/claude-skills150—~1.7kAutomated safety check: PassMIT
Hedgefundmonitormajiayu000/claude-skill-registry6663 repos~1.7kAutomated safety check: PassMIT
Visual Skillsnpc-live/clawfirm156—~7.4kAutomated safety check: PassNone
Informer2020VectorSpaceLab/AREX-Skill328—~1.1kAutomated safety check: PassApache-2.0

Similar skills

  • Regime

    jackson-video-resources/markov-hedge-fund-method

    Detect the market regime (Bull / Bear / Sideways) for ANY asset and turn it into a tradeable signal or a risk filter.

    483 GitHub stars~1.6k tokensUpdated 4 mo ago
    Business, Finance & HRAuto-check passed
  • Exploring Data

    oaustegard/claude-skills

    Exploratory data analysis. An agent skill from oaustegard/claude-skills.

    150 GitHub stars~1.7k tokensUpdated today
    Data & AnalyticsAuto-check passed
  • Hedgefundmonitor

    majiayu000/claude-skill-registry

    Query the OFR (Office of Financial Research) Hedge Fund Monitor API for hedge fund data including SEC Form PF aggregated statistics, CFTC Traders in Financial Futures, FICC Sponsored Repo volumes…

    666 GitHub starsUsed in 3 repos~1.7k tokens
    Data & AnalyticsAuto-check passed
  • Visual Skills

    npc-live/clawfirm

    A skill your agent uses whenever the user provides data (CSV, JSON, table, pasted numbers, or any structured dataset) and expects a visual output — even if they don't say 'chart' or 'visualize'.

    156 GitHub stars~7.4k tokensUpdated 3 mo ago
    Data & AnalyticsAuto-check passed
  • Informer2020

    VectorSpaceLab/AREX-Skill

    A skill your agent uses for Informer2020 long-sequence time-series forecasting training, evaluation, custom CSV preparation, and prediction workflows.

    328 GitHub stars~1.1k tokensUpdated 1 mo ago
    Data & AnalyticsAuto-check passed
  • Financial Research

    firecrawl/web-agent

    Pulls a public company's latest 10-K or 10-Q figures and analyst consensus from SEC EDGAR and Yahoo Finance, then cross-checks the two sources.

    1.2k GitHub stars~1.1k tokensUpdated 5 mo ago
    Business, Finance & HRAuto-check passed

Works with

Questions about Garch Method

What does Garch Method do?

Volatility forecasting and position sizing via walk-forward GARCH(1,1). Garch Method is an agent skill from milesdeutscher/garchmethod. Volatility forecasting and position sizing via walk-forward GARCH(1,1).

When should I use Garch Method?

Garch Method fits situations like: the user asks about volatility forecasts; position sizing; how much should I put on; risk throttling.

How do I install Garch Method in Claude Code?

Run `npx skills add milesdeutscher/garchmethod --skill garch-method -a claude-code`. Or copy the skill folder (skills/garch in milesdeutscher/garchmethod) into .claude/skills/garch-method in your project. Claude Code loads it when a task matches its description.

How do I install Garch Method in Codex?

Run `npx skills add milesdeutscher/garchmethod --skill garch-method -a codex`. Or copy the skill folder (skills/garch in milesdeutscher/garchmethod) into .agents/skills/garch-method in your project. Codex loads it when a task matches its description.

Can I use Garch Method in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add milesdeutscher/garchmethod --skill garch-method -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/garch-method, .gemini/skills/garch-method, .github/skills/garch-method and .opencode/skills/garch-method in your project.

What does Garch Method need to run?

Going by SKILL.md and its folder, Garch Method needs the command-line tools its instructions call (uv).

Does Garch Method access the network?

SKILL.md contains no URLs. Its commands use uv, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Garch Method safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Garch Method use?

Garch Method is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Garch Method use?

About 1k tokens (SKILL.md is roughly 4.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Garch Method?

Skills that share tags, products or a category with Garch Method: Regime (jackson-video-resources/markov-hedge-fund-method, 483 stars), Exploring Data (oaustegard/claude-skills, 150 stars), Hedgefundmonitor (majiayu000/claude-skill-registry, 666 stars) and Visual Skills (npc-live/clawfirm, 156 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Garch Method?

milesdeutscher (a GitHub user) maintains it in milesdeutscher/garchmethod, which has 191 GitHub stars. The repository was last updated on July 8, 2026.

Source: milesdeutscher/garchmethod on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.