portfolio-health-check

portfolio-health-check is a skill for Claude Code, Codex from Geeksfino/finskills. It costs 71 tokens per session (1,876 once invoked), scanned A, original, Apache-2.0.

A framework for reviewing an existing investment portfolio, meaning a group of investments held together, for concentration, correlation, factor exposure, liquidity, and stress risks.

In plain words
What is it for?
It is for importing holdings, measuring their portfolio weights, checking concentration and correlations, comparing factor exposure with a benchmark, and stress-testing weaknesses.
Why use it?
It reveals risks that may be hidden when many holdings move together or are overly exposed to one market, sector, style, or asset type.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It is for importing holdings, measuring their portfolio weights, checking concentration and correlations, comparing factor exposure with a benchmark, and stress-testing weaknesses.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/geeksfino/finskills/portfolio-health-check
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Geeksfino/finskills --skill portfolio-health-check
Clone the repo
git clone --depth 1 https://github.com/Geeksfino/finskills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for portfolio-health-check

README.md
[![agentmods](https://agentmods.dev/badge/skills/geeksfino/finskills/portfolio-health-check/github.svg)](https://agentmods.dev/skills/geeksfino/finskills/portfolio-health-check)
Your own site
<a href="https://agentmods.dev/skills/geeksfino/finskills/portfolio-health-check"><img src="https://agentmods.dev/badge/skills/geeksfino/finskills/portfolio-health-check/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for portfolio-health-check

Your own site · 80×15
<a href="https://agentmods.dev/skills/geeksfino/finskills/portfolio-health-check"><img src="https://agentmods.dev/badge/skills/geeksfino/finskills/portfolio-health-check.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 71 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,876 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00071 $0.01876
Opus 5 $0.00036 $0.00938
Sonnet 5 $0.00014 $0.00375
Haiku 4.5 $0.00007 $0.00188

Measured 12d ago against content hash 535d5f136b39, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

portfolio-health-check scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

China-market/portfolio-health-check/SKILL.md · 131 lines

How it starts

The opening of the file, as written. The whole thing — 131 lines — stays where its author put it; the contents beside it link to each section on GitHub.

组合健康诊断

扮演投资组合风险诊断师。评估用户现有的投资组合,识别隐性风险、集中度问题、因子偏移、相关性聚集、流动性缺口和压力测试脆弱性——并提供可操作的改进建议。

工作流程

第一步:导入组合

收集用户当前持仓信息:

输入 必需 格式
持仓清单 代码 + 股数/金额 或 百分比
现金仓位 金额或百分比
账户类型 普通证券账户 / 含个人养老金 / 两融账户
基准 默认:沪深300(000300)
风险偏好 保守 / 稳健 / 积极
投资期限 年数

如用户提供的数据不完整,请追问确认。将所有仓位统一换算为组合总值的百分比。

第二步:集中度分析

从多个维度评估集中度。详细阈值参见 references/diagnostic-framework.md

维度 检查内容 红灯阈值
单只个股 任何仓位占比 > 10% > 15% 为严重
前5大集中度 前5大持仓合计权重 > 50% 偏高
行业 申万一级行业权重 vs 基准 单行业 > 30%
市场 沪市/深市/北交所/港股通分布 > 90% 单一市场
市值 大盘/中盘/小盘/微盘 > 85% 单一区间
资产类别 权益/固收/另类/现金 > 90% 单一类别
风格 成长 vs 价值偏移 > 75% 单一风格

第三步:相关性聚集检测

识别走势趋同的持仓群组:

  1. 估算所有权益持仓之间的两两相关系数
  2. 识别相关性聚集——3只及以上持仓平均两两相关系数 > 0.7
  3. 计算有效分散比率——组合包含多少真正独立的投注
  4. 标记表面看似分散但实际高度相关的持仓(如多只白酒股、新能源产业链上下游)

第四步:因子暴露分析

将组合分解为因子暴露:

因子 指标 基准中性
市场Beta 组合Beta vs 沪深300 1.0
价值 加权平均PE、PB 基准平均值
成长 加权平均营收/盈利增速 基准平均值
规模 加权平均市值 基准中位数
动量 加权平均12-1月收益率 基准平均值
质量 加权平均ROE、资产负债率 基准平均值
波动率 加权平均已实现波动率 基准平均值
股息率 加权平均股息率 基准平均值

标记任何偏离基准超过1个标准差的因子暴露。

第五步:风险指标

计算组合层面的风险指标:

指标 说明
组合波动率 年化标准差
Beta 相对基准的敏感度
跟踪误差 相对基准的主动收益波动率
主动份额 组合与基准的差异比例
风险价值(95%) 1年期95%置信度下的最大损失
条件风险价值(CVaR) 超过VaR的平均损失
最大回撤估计 基于历史配置分析
夏普比率估计 超额收益 / 波动率
索提诺比率估计 超额收益 / 下行偏差

第六步:压力测试

在历史压力情景下检验组合。详细情景参见 references/diagnostic-framework.md

情景 时期 关键特征
2015年股灾 2015年6–8月 杠杆牛崩盘,上证从5178跌至2850
2018年贸易摩擦 2018年 中美贸易战,沪深300跌-25%
2020年疫情冲击 2020年1–3月 快速下跌后V形反弹
2022年市场调整 2022年 地产危机+疫情封控,成长股大幅回调
2008年金融危机 2007–2008 A股从6124跌至1664,跌幅-73%

第七步:流动性评估

评估组合流动性:

指标 检查内容
变现天数 以日均成交量20%计算,每个仓位完全退出需多少天
低流动性仓位 完全退出需要 > 5个交易日的持仓
涨跌停风险 A股10%/20%(创业板/科创板)涨跌停限制对流动性的影响
小盘股占比 日均成交额低于5000万元的个股占组合比例

Read the full file on GitHub · 131 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 131 lines · 71 tokens per session scan A 535d5f136b39

Subscribe to this mod's changes

portfolio-health-check is a skill published in the GitHub repository Geeksfino/finskills (279 stars, last pushed 6mo ago), licensed Apache-2.0. It adds 71 tokens to every session and 1,876 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

sector-rotation

An analysis framework for comparing industries in the Chinese A-share stock market, using business conditions, price momentum, valuation, and money flows. It produces rankings and higher- or lower-allocation suggestions.

HKUDS/Vibe-Trading · 39 tokens

strategy-pivot-designer

Detect backtest iteration stagnation and generate structurally different strategy pivot proposals when parameter tuning reaches a local optimum.

tradermonty/claude-trading-skills · 28 tokens

twitter-reader

Read Twitter/X for financial research using opencli (read-only). Use this skill whenever the user wants to read their Twitter feed, search for financial tweets, view bookmarks, look up user profiles, or gather market sentiment from Twitter/X. Triggers include: "check my feed", "search Twitter for", "show my…

himself65/finance-skills · 161 tokens

chenhao-limit-up

A framework for judging Chinese A-share stocks that have reached the daily price-rise limit, using market mood, sector leadership, and trading momentum.

questflowai/investorskills · 44 tokens

furusato

A Japanese hometown-tax donation manager for furusato nozei, a system where donations to municipalities can qualify for an income-tax or local-tax deduction. It reads donation receipts, stores donation records, and calculates deduction limits.

kazukinagata/shinkoku · 102 tokens

reading-receipt

An image-reading workflow for extracting structured information from receipts, invoices, and hometown-tax donation certificates. It can first extract text from PDFs and otherwise read their images.

kazukinagata/shinkoku · 64 tokens