fatfingererr avatar

Monitor Etf Holdings Drawdown Risk

This monitors physical ETFs like SLV and GLD for a specific divergence pattern: when commodity prices climb but ETF holdings drop, which might signal physical supply stress or just redemption flows. It calculates a 0-100 stress score by comparing price returns against inventory drawdowns over configurable windows (default 180 days), checks if holdings hit decade lows, and crucially presents two competing hypotheses rather than assuming one narrative. The Python scripts scrape ETF holdings via Selenium, pull prices from Yahoo Finance, and generate JSON plus visual reports. You'd run this if you're tracking precious metals markets and want systematic alerts when price and inventory move opposite directions, though you still need to interpret which hypothesis fits the broader data.

skills.sh installs
125
GitHub stars
3
last updated
Aug 21, 2026

Install

$ npx -y skills add fatfingererr/macro-skills --skill monitor-etf-holdings-drawdown-risk --agent claude-code

Installs into .claude/skills of the current project.

Files

<essential_principles>

**背離訊號核心邏輯**

背離事件定義:

  • 價格上漲:price_return >= min_price_return_pct(如 +15%)
  • 庫存下滑:inventory_change <= -min_inventory_drawdown_pct(如 -10%)
  • 同時發生:在相同視窗期(如 180 天)內同時滿足

當價格與庫存同向時(同漲同跌)為正常;逆向時(價漲庫跌)才需要警覺。

**雙重假設驗證**

不能直接把「庫存下降」解讀為「實物被搶」,需要交叉驗證:

假設支持條件反駁條件
實物緊張COMEX/LBMA 下降、backwardation、lease rates 上升、零售溢價擴大其他庫存穩定、contango、溢價平穩
資金流/贖回ETF 流出但交易所庫存穩定、期貨結構不緊多重庫存同步下降

輸出兩種解釋,讓用戶判斷哪個更符合當前數據。

**資料取得方式**

本 skill 優先使用:

  • ETF 官網庫存:Selenium 模擬人類瀏覽器行為抓取(避免 API 限制)
  • Yahoo Finance:yfinance 套件取得現貨/期貨價格
  • 交叉驗證:COMEX 庫存、期貨結構等公開數據

腳本位於 scripts/ 目錄,遵循 references/data-sources.md 的反偵測策略。

**壓力分數計算**
stress_score = 100 × min(1.0,
    0.6 × divergence_severity +      # 背離嚴重度
    0.2 × decade_low_bonus +         # 十年低點加成
    0.2 × ratio_extreme_bonus        # 比值極端加成
)

Sponsors

Details

Repository
github.com/fatfingererr/macro-skills
Category
DevOps & CI/CD
First seen
Jun 3, 2026

More from fatfingererr/macro-skills

All 2
1khazp avatarvibe-buildkhazp/vibe-coding-prompt-templateBuild your MVP following the AGENTS.md plan. Use when the user wants to start building, implement features, or says "build my MVP", "start coding", or "implemen124skills.sh installs
2skillcreatorai avatarvercel-deployskillcreatorai/ai-agent-skillsvercel deploy120skills.sh installs
3erichowens avatardata-pipeline-engineererichowens/some_claude_skillsdata pipeline engineer119skills.sh installs
4ClickHouse avatarbuildClickHouse/ClickHouseBuild ClickHouse with various configurations (Release, Debug, ASAN, TSAN, etc.). Use when the user wants to compile ClickHouse.0skills.sh installs
5elastic avatarobservability-llm-obselastic/agent-skills>0skills.sh installs
6elitan avatarmonitorelitan/frostMonitor a PR until CI is 100% green, fixing any failures0skills.sh installs