Agent skill

A Share Volatility

by aifinlab in aifinlab/FinClaw

A股波动率分析/GARCH建模。当用户说"波动率"、"volatility"、"GARCH"、"波动率锥"、"历史波动率"、"隐含波动率"、"HV"、"IV"、"波动率分位"、"XX波动率多少"、"波动率高吗"时触发。分析个股/指数的历史波动率、波动率锥、GARCH预测、隐含波动率对比,辅助判断当前波动率水平和未来波动率趋势。支持研报风格(formal)和快速查看风格(brief)。

Apache-2.0Auto-check passed

Install A Share Volatility

skills CLI
$ npx skills add aifinlab/FinClaw --skill a-share-volatility -a claude-code

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

GitHub CLI
$ gh skill install aifinlab/FinClaw a-share-volatility --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/aifinlab/FinClaw.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/a-share-volatility .claude/skills/a-share-volatility && 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
a-share-volatility
GitHub stars
254
Token cost
~781 tokens
SKILL.md length
241 words
Files
3 (incl. scripts, references)
Skills in repo
74
Repo updated
First seen
Licence
Apache-2.0

At a glance

A股波动率分析/GARCH建模。当用户说"波动率"、"volatility"、"GARCH"、"波动率锥"、"历史波动率"、"隐含波动率"、"HV"、"IV"、"波动率分位"、"XX波动率多少"、"波动率高吗"时触发。分析个股/指数的历史波动率、波动率锥、GARCH预测、隐含波动率对比,辅助判断当前波动率水平和未来波动率趋势。支持研报风格(formal)和快速查看风格(brief)。

  • Works in 4 steps: 获取近 2 年日线 K 线数据(OHLCV) → 计算对数收益率:r_t = ln(Close_t / Close_{t-1}) → 获取实时行情确认最新价格 → …
  • Runs Python scripts from its folder; calls python

What it does

A Share Volatility is an agent skill from aifinlab/FinClaw. A股波动率分析/GARCH建模。当用户说"波动率"、"volatility"、"GARCH"、"波动率锥"、"历史波动率"、"隐含波动率"、"HV"、"IV"、"波动率分位"、"XX波动率多少"、"波动率高吗"时触发。分析个股/指数的历史波动率、波动率锥、GARCH预测、隐含波动率对比,辅助判断当前波动率水平和未来波动率趋势。支持研报风格(formal)和快速查看风格(brief)。

Its SKILL.md is about 780 tokens, which your agent loads only when the skill is triggered. The skill folder holds 4 other files, including scripts and reference files (for example `references/volatility-guide.md` and `scripts/volatility_analyzer.py`).

The licence is Apache-2.0.

Example prompts

  • “volatility”
  • “XX波动率多少”
  • “/a-share-volatility”

Requirements

  • Python 3

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. 获取近 2 年日线 K 线数据(OHLCV)
  2. 计算对数收益率:r_t = ln(Close_t / Close_{t-1})
  3. 获取实时行情确认最新价格
  4. 运行 volatility_analyzer.py 获取完整波动率分析结果

What it can do on your machine

Read from SKILL.md and the folder at commit 9e62862. 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

    Ships 1 file in scripts/ (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python

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

  • Network

    No URLs in SKILL.md.

    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

A Share Volatility loads about 781 tokens when it runs, and up to ~2.5k if it reads all its reference files. Until then it costs about 53 tokens; SKILL.md has 241 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~53
When it runs · the whole SKILL.md, loaded when a task matches
~781
With references · SKILL.md plus every file in references/, read only if the agent opens them
~2.5k

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); the scripts in this folder are not scanned.

SKILL.md

The full file from aifinlab/FinClaw at commit 9e62862, republished under its Apache-2.0 licence (© aifinlab). 241 words, ~781 tokens.

Download SKILL.mdSave it as .claude/skills/a-share-volatility/SKILL.md (or your agent's skills folder). This skill also uses 2 other files; get the full folder from GitHub.
name
a-share-volatility
description
A股波动率分析/GARCH建模。当用户说"波动率"、"volatility"、"GARCH"、"波动率锥"、"历史波动率"、"隐含波动率"、"HV"、"IV"、"波动率分位"、"XX波动率多少"、"波动率高吗"时触发。分析个股/指数的历史波动率、波动率锥、GARCH预测、隐含波动率对比,辅助判断当前波动率水平和未来波动率趋势。支持研报风格(formal)和快速查看风格(brief)。
数据源
bash
SCRIPTS="$SKILLS_ROOT/cn-stock-data/scripts"
VOL_SCRIPTS="$SKILLS_ROOT/a-share-volatility/scripts"

# 日线 K 线(近 2 年,用于波动率锥和 GARCH 拟合)
python "$SCRIPTS/cn_stock_data.py" kline --code [CODE] --freq daily --start [2年前日期]

# 实时行情
python "$SCRIPTS/cn_stock_data.py" quote --code [CODE]

# 波动率一键分析(HV多窗口 + 波动率锥 + GARCH预测 + EWMA)
python "$VOL_SCRIPTS/volatility_analyzer.py" --code [CODE] --start [2年前日期]

# 期权隐含波动率(仅限有期权的标的:50ETF/300ETF/个股期权)
# 通过 akshare 获取期权数据
python -c "import akshare as ak; df=ak.option_sse_greeks_sina(symbol='510050'); print(df[['IV']].describe())"
Workflow (5 steps):

Step 1: 数据获取与预处理

  1. 获取近 2 年日线 K 线数据(OHLCV)
  2. 计算对数收益率:r_t = ln(Close_t / Close_{t-1})
  3. 获取实时行情确认最新价格
  4. 运行 volatility_analyzer.py 获取完整波动率分析结果

Step 2: 历史波动率计算(多窗口) 计算 5 个滚动窗口的年化历史波动率:

窗口用途说明
HV5超短期波动反映近一周波动
HV10短期波动反映近两周波动
HV20月度波动最常用,对应期权月到期
HV60季度波动中期波动水平
HV120半年波动长期波动基准

计算方法(Close-to-Close):

  • HV_N = std(r_t, window=N) * sqrt(252) * 100(百分比形式)

补充方法(如果有高开低收数据):

  • Parkinson 波动率:利用最高价/最低价,HV_park = sqrt(1/(4N*ln2) * sum(ln(H/L)^2)) * sqrt(252)
  • Yang-Zhang 波动率:综合开盘跳空 + 日内波动,更准确

Step 3: 波动率锥构建 对每个窗口,计算历史上所有滚动 HV 值的分位数分布:

分位数含义
P95极高波动(历史 95% 分位)
P75偏高波动
P50中位数(典型水平)
P25偏低波动
P05极低波动(历史 5% 分位)

当前 HV 在锥中的位置:

  • 高于 P75 → 波动率偏高,可能回归
  • P25-P75 → 正常区间
  • 低于 P25 → 波动率偏低,可能扩张

波动率锥呈现方式:以窗口为横轴、波动率为纵轴,各分位线形成"锥形",当前值标注在对应位置。

Step 4: GARCH(1,1) 拟合与预测 使用 arch 库拟合 GARCH(1,1) 模型(不可用时 fallback 到 EWMA):

GARCH(1,1) 模型:

  • sigma_t^2 = omega + alpha * r_{t-1}^2 + beta * sigma_{t-1}^2
  • 长期方差 = omega / (1 - alpha - beta)
  • alpha:短期冲击敏感度(越大越受近期波动影响)
  • beta:波动率持续性(越大波动聚集越强)
  • alpha + beta → 1:波动率持续性极强

GARCH 预测输出:

  • 未来 5/10/20 日波动率预测值
  • 向长期均值收敛的速度
  • 参数解读(alpha/beta/omega)

EWMA 备选(lambda=0.94, RiskMetrics 标准):

  • sigma_t^2 = lambda * sigma_{t-1}^2 + (1-lambda) * r_{t-1}^2

Step 5: HV vs IV 对比(如有期权数据) 仅限有期权的标的(50ETF/300ETF 等):

  • 如果 IV > HV:期权定价偏贵,适合卖方策略
  • 如果 IV < HV:期权定价偏低,适合买方策略
  • IV-HV 差值的历史分位数
风格说明
维度formal(波动率研究报告)brief(快速波动率查看)
篇幅2-4 页半页
HV 多窗口5 个窗口全部列出 + 趋势判断HV20 + HV60 两个关键窗口
波动率锥完整分位数表 + 文字描述锥形当前 HV20 所处分位
GARCH完整参数 + 预测 + 模型诊断一句话预测方向
IV 对比详细 HV-IV 分析 + 策略建议IV vs HV 一句话
波动率特征聚集性/均值回归/非对称性分析省略
结论多维度总结 + 波动率交易建议高/正常/低 + 趋势
免责声明需要不需要
关键规则
  1. 年化处理:所有波动率统一年化(*sqrt(252)),以百分比形式呈现
  2. 波动率锥判断:核心输出是"当前波动率在历史中的位置",必须给出分位数
  3. 均值回归:波动率具有均值回归特性,极端值倾向回归到长期均值
  4. 波动率聚集:高波动之后往往跟随高波动,低波动之后往往跟随低波动
  5. GARCH 可选:如果 arch 库未安装,使用 EWMA 替代,结果标注为"EWMA 估计"
  6. IV 数据有限:仅部分 ETF 和个股有期权,无期权标的跳过 IV 对比环节
  7. A 股特色:注意涨跌停板对波动率计算的影响(涨跌停日波动率被低估),T+1 交易制度,新股上市初期波动率异常
  8. 数据量要求:GARCH 拟合建议至少 250 个交易日数据,波动率锥建议 2 年以上数据

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

Files

SKILL.md and 2 other files (scripts, references) in skills/a-share-volatility of aifinlab/FinClaw.

  • SKILL.md
  • references/volatility-guide.md
  • scripts/volatility_analyzer.py

Open the folder on GitHubat commit 9e62862

Compare with similar skills

A Share Volatility 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.

A Share Volatility compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
A Share Volatility this skillaifinlab/FinClaw254—~781Automated safety check: PassApache-2.0
ShareClickHouse/ClickHouse50k—~558Automated safety check: NotesApache-2.0
Volatility Percentile StrategyHKUDS/Vibe-Trading35k—~528Automated safety check: PassMIT
SharingBuilderIO/agent-native7.1k—~3.4kAutomated safety check: PassNone
Deslop Shared Libsgarrytan/gstack136k—~3.3kAutomated safety check: NotesMIT
Skill Sharedavila7/claude-code-templates32k10 repos~729Automated safety check: PassMIT

Similar skills

  • Share

    ClickHouse/ClickHouse

    Share a Claude Code session to pastila.nl and return a viewer link.

    50k GitHub stars~558 tokensUpdated today
    DatabasesAuto-check: notes
  • Mean-reversion signal engine that ranks historical volatility against its own recent history, going long in quiet regimes and exiting or shorting when volatility is high.

    35k GitHub stars~528 tokensUpdated yesterday
    Business, Finance & HRAuto-check passed
  • Sharing

    BuilderIO/agent-native

    Framework-level sharing and privacy for user-authored resources (dashboards, documents, forms, decks, etc.).

    7.1k GitHub stars~3.4k tokensUpdated today
    Auto-check passed
  • Deslop Shared Libs

    garrytan/gstack

    Find worthwhile shared-code extractions in recent work. An agent skill from garrytan/gstack.

    136k GitHub stars~3.3k tokensUpdated today
    Writing & ContentAuto-check: notes
  • Skill Share

    davila7/claude-code-templates

    A skill that creates new Claude skills and automatically shares them on Slack using Rube for seamless team collaboration and skill discovery.

    32k GitHub starsUsed in 10 repos~729 tokens
    Agent WorkflowsAuto-check passed
  • Moves logic out of Astro frontmatter into tested helper modules under shared/lib, with rules for naming, typing, deterministic demo data and sibling test files.

    42k GitHub stars~1.2k tokensUpdated yesterday
    DevelopmentAuto-check passed

More from aifinlab/FinClaw

All 74 skills in this repo
  • Bank Corporate Credit Dd

    aifinlab/FinClaw

    A skill your agent uses when the user asks for help with corporate credit due diligence, enterprise credit investigation, pre-loan review, borrower analysis, document collection, management…

    254 GitHub stars~952 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate-risk monitoring assistant for enterprise litigation/penalty/enforcement scanning (处罚/诉讼/被执行/失信等).

    254 GitHub stars~751 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate client operating-volatility monitoring assistant (经营监测/指标波动/预警解释).

    254 GitHub stars~605 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank post-loan visit follow-up assistant to turn visit notes/materials into a structured memo (摘要/关键更新/风险观察/用途核验/行动项).

    254 GitHub stars~544 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate credit issue-list assistant (问题清单/补件清单/催办台账).

    254 GitHub stars~487 tokensUpdated 4 mo ago
    Auto-check passed
  • A skill your agent uses when you need a bank corporate credit approval-opinion drafting assistant (审批意见/条款建议/有条件同意).

    254 GitHub stars~549 tokensUpdated 4 mo ago
    Auto-check passed

Questions about A Share Volatility

What does A Share Volatility do?

A股波动率分析/GARCH建模。当用户说"波动率"、"volatility"、"GARCH"、"波动率锥"、"历史波动率"、"隐含波动率"、"HV"、"IV"、"波动率分位"、"XX波动率多少"、"波动率高吗"时触发。分析个股/指数的历史波动率、波动率锥、GARCH预测、隐含波动率对比,辅助判断当前波动率水平和未来波动率趋势。支持研报风格(formal)和快速查看风格(brief)。. A Share Volatility is an agent skill from aifinlab/FinClaw.

How do I install A Share Volatility in Claude Code?

Run `npx skills add aifinlab/FinClaw --skill a-share-volatility -a claude-code`. Or copy the skill folder (skills/a-share-volatility in aifinlab/FinClaw) into .claude/skills/a-share-volatility in your project. Claude Code loads it when a task matches its description.

How do I install A Share Volatility in Codex?

Run `npx skills add aifinlab/FinClaw --skill a-share-volatility -a codex`. Or copy the skill folder (skills/a-share-volatility in aifinlab/FinClaw) into .agents/skills/a-share-volatility in your project. Codex loads it when a task matches its description.

Can I use A Share Volatility 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 aifinlab/FinClaw --skill a-share-volatility -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/a-share-volatility, .gemini/skills/a-share-volatility, .github/skills/a-share-volatility and .opencode/skills/a-share-volatility in your project.

What does A Share Volatility need to run?

Going by SKILL.md and its folder, A Share Volatility needs Python for the scripts in its folder and the command-line tools its instructions call (python). Our summary lists: Python 3.

Does A Share Volatility access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is A Share Volatility 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. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does A Share Volatility use?

A Share Volatility is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does A Share Volatility use?

About 781 tokens (SKILL.md is roughly 3.1k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1.7k tokens, read only when the agent opens those files.

What are the alternatives to A Share Volatility?

Skills that share tags, products or a category with A Share Volatility: Share (ClickHouse/ClickHouse, 50k stars), Volatility Percentile Strategy (HKUDS/Vibe-Trading, 35k stars), Sharing (BuilderIO/agent-native, 7.1k stars) and Deslop Shared Libs (garrytan/gstack, 136k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains A Share Volatility?

aifinlab (a GitHub user) maintains it in aifinlab/FinClaw, which has 254 GitHub stars. The repository holds 74 skills in this directory. The repository was last updated on May 13, 2026.

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