portfolio-hedge

portfolio-hedge is a skill for Claude Code from BlueWaterCorp/RiskModels_API. It costs 85 tokens per session (950 once invoked), scanned B, original, Apache-2.0.

A tool for building ETF hedge amounts for one position or a portfolio, based on market, sector, and subsector risk exposures.

In plain words
What is it for?
Use it to hedge a single holding, combine hedge needs across a portfolio, or analyse the residual return left after hedging.
Why use it?
It turns risk analysis into dollar-sized hedge legs and can show which cascade level best isolates a position’s remaining stock-specific return.

Skill for Claude Code

Written for Claude Code: argument-hint in frontmatter. Also seen: positional $N argument.

Part of the riskmodels plugin — 5 skills, 5 commands, 1 agent shipped together

Good fit Use it to hedge a single holding, combine hedge needs across a portfolio, or analyse the residual return left after hedging.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/bluewatercorp/riskmodels_api/portfolio-hedge
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 BlueWaterCorp/RiskModels_API --skill portfolio-hedge
Clone the repo
git clone --depth 1 https://github.com/BlueWaterCorp/RiskModels_API

Made for: Claude Code.

Or install riskmodels, the plugin that ships this one along with the rest of its 5 skills, 5 commands, 1 agent.

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-hedge

README.md
[![agentmods](https://agentmods.dev/badge/skills/bluewatercorp/riskmodels_api/portfolio-hedge/github.svg)](https://agentmods.dev/skills/bluewatercorp/riskmodels_api/portfolio-hedge)
Your own site
<a href="https://agentmods.dev/skills/bluewatercorp/riskmodels_api/portfolio-hedge"><img src="https://agentmods.dev/badge/skills/bluewatercorp/riskmodels_api/portfolio-hedge/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-hedge

Your own site · 80×15
<a href="https://agentmods.dev/skills/bluewatercorp/riskmodels_api/portfolio-hedge"><img src="https://agentmods.dev/badge/skills/bluewatercorp/riskmodels_api/portfolio-hedge.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 85 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 950 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. 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.00085 $0.00950
Opus 5.5 $0.00034 $0.00380
Sonnet 5.5 $0.00017 $0.00190
Haiku 4.5 $0.00009 $0.00095

Measured 19d ago against content hash 180c9c2cf67d, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade B, and why

portfolio-hedge scanned grade B with 1 finding 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 19d 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.

Subtle steeringmediumPrompt injection

Instructions that bias recommendations or shape behaviour without the user noticing.

neutralize; never tell the user to place, trim, or rebalance a trade, and never
claude-plugin/plugins/riskmodels/skills/portfolio-hedge/SKILL.md · 70 lines

How it starts

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

Portfolio & position hedging (ERM3 cascade + Lstar)

Report the ETF hedge legs the decomposition implies for a position or portfolio. This skill wraps the hosted RiskModels MCP and reports tool outputs; it computes nothing itself.

What to call

  • riskmodels_get_my_positions — the caller's linked book (Alpaca Connect, Connect Trade, or Plaid). Call this first when the user means their account and has not pasted tickers. Pass for_analysis and for_hedge to the long-only portfolio tools below; when has_shorts is true or the book has more than 100 names, pass for_exposure to riskmodels_portfolio_exposure. This server does not place orders.
  • riskmodels_decompose with dollars — one ticker: scale the L-level ETF hedge ratios to a dollar position.
  • riskmodels_analyze_portfolio — a long-only book: holdings-weighted L1/L2/L3 hedge-level aggregate; with dollar positions it also scales the hedge ratios at the chosen cascade level (level L1/L2/L3) into ETF USD hedge legs.
  • riskmodels_portfolio_exposure — a signed long/short book (dollar values, short < 0, up to 1000 names): beta-dollars by sector, the ETF trades that neutralise the book at L1/L2/L3, and the systematic vs residual risk split. Use it whenever any position is short or the book has more than 100 names; riskmodels_analyze_portfolio takes long positions only (up to 100). Report any coverage.dropped names or warnings to the user.
  • riskmodels_get_residual_returns (1-100 tickers) — dispatch the simplest cascade level that clears the marginal-ER threshold for a name (or basket) and return the residual-return series after that hedge.

For an ETF or 13F filer named instead of pasted tickers, resolve real holdings first (riskmodels_search → riskmodels_get_etf with holdings_top, or riskmodels_get_filer with holdings_top / riskmodels_get_fund with holdings_limit) and treat the result as the portfolio. Never fabricate or approximate holdings — if no tool covers the portfolio, say so and ask the user to paste the positions.

Read the full file on GitHub · 70 lines

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. 19d ago Changed · -1 lines 180c9c2cf67d
  2. 25d ago Changed · +7 lines cfd38fe263eb
  3. 29d ago Changed · +4 lines 3e3b91fa5422
  4. 2mo ago First seen · 60 lines · 85 tokens per session scan B 91377aa708bb

Subscribe to this mod's changes

portfolio-hedge is a skill published in the GitHub repository BlueWaterCorp/RiskModels_API (0 stars, last pushed yesterday), licensed Apache-2.0. It adds 85 tokens to every session and 950 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it B with 1 finding (subtle steering). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.

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 through opencli: the user's home timeline, tweet search, trending topics, bookmarks, a user's recent tweets, threads, articles, profiles, followers and following, and notifications. Use this skill whenever the user wants to know what people are saying on Twitter/X or fintwit about…

himself65/finance-skills · 110 tokens

energy-procurement

Codified expertise for electricity and gas procurement, tariff optimization, demand charge management, renewable PPA evaluation, and multi-facility energy cost management. Informed by energy procurement managers with 15+ years experience at large commercial and industrial consumers. Includes market structure analysis…

hashgraph-online/awesome-codex-plugins · 93 tokens

airdrop-hunting-guide

Guide to finding and qualifying for crypto airdrops — eligibility criteria, farming strategies, on-chain activity requirements, Sybil detection avoidance, and tracking tools. Use when helping users understand airdrops, check eligibility, or plan participation strategies.

nirholas/three.ws · 54 tokens

recipe-daily-pnl-report

Generate a daily profit and loss summary from trades and balances.

krakenfx/kraken-cli · 19 tokens