risk-sizing

risk-sizing is a skill for Claude Code from Miha21222/tradingview-mcp. It costs 81 tokens per session (632 once invoked), scanned A, original, MIT.

A calculator for foreign-exchange position size and risk figures, including pip values, stop distances, account-currency conversion, and R-multiples. A pip is a small standard price movement in a currency pair, and R measures profit or loss against the initial risk.

In plain words
What is it for?
Use it to calculate lot or unit size, pip value, currency conversion, stop-loss risk, and trade results in R.
Why use it?
It shows how much money a trade risks before entry and avoids sizing mistakes caused by different pip rules, JPY pairs, metals, or account currencies.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the tradingview-mcp plugin — 10 skills, 1 MCP server shipped together

Good fit Use it to calculate lot or unit size, pip value, currency conversion, stop-loss risk, and trade results in R.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/miha21222/tradingview-mcp/risk-sizing
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 Miha21222/tradingview-mcp --skill risk-sizing
Clone the repo
git clone --depth 1 https://github.com/Miha21222/tradingview-mcp

Made for: Claude Code.

Or install tradingview-mcp, the plugin that ships this one along with the rest of its 10 skills, 1 MCP server.

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 risk-sizing

README.md
[![agentmods](https://agentmods.dev/badge/skills/miha21222/tradingview-mcp/risk-sizing/github.svg)](https://agentmods.dev/skills/miha21222/tradingview-mcp/risk-sizing)
Your own site
<a href="https://agentmods.dev/skills/miha21222/tradingview-mcp/risk-sizing"><img src="https://agentmods.dev/badge/skills/miha21222/tradingview-mcp/risk-sizing/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 risk-sizing

Your own site · 80×15
<a href="https://agentmods.dev/skills/miha21222/tradingview-mcp/risk-sizing"><img src="https://agentmods.dev/badge/skills/miha21222/tradingview-mcp/risk-sizing.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 81 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 632 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.00081 $0.00632
Opus 5 $0.00041 $0.00316
Sonnet 5 $0.00016 $0.00126
Haiku 4.5 $0.00008 $0.00063

Measured 9d ago against content hash 724532ca38a1, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade A, and why

risk-sizing 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 9d 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.

skills/risk-sizing/SKILL.md · 54 lines

What it actually says

Risk sizing (pure judgment)

Position size is the single variable that decides survival. Compute it before touching a chart or backtest. Zero tools — this is arithmetic you verify yourself; the numbers below match what the backtest engine uses.

Pip size and pip value

  • FX pip: 0.0001 normally; JPY-quoted pairs 0.01 (USDJPY, EURJPY, ...).
  • Metals: XAU 0.1, XAG 0.01.
  • Contract per standard lot: 100 000 units (FX), 100 oz (XAU), 5000 oz (XAG).
  • Pip value per lot (in quote currency) = pip size × contract size (EURUSD ≈ $10/pip/lot; USDJPY ≈ 1000 JPY/pip/lot).

Account-currency conversion

When the quote currency differs from your account currency, convert explicitly (e.g. USD account on USDJPY: USD per pip per lot = 1000 JPY ÷ USDJPY). Never assume the quote equals the account.

Risk-based position size

size (units) = risk_amount / stop_distance_in_price

A full stop-loss move costs exactly risk_amount account units. In pips: size = risk_amount / (stop_pips × pip_size). This is independent of the quote→account rate when size is treated in the backtest engine's convention.

R-multiple

R = profit / initial_risk. A stop-hit ≈ −1R. Judge expectancy in R, not dollars (account size is arbitrary). A setup with WR=30% can still be strongly profitable if winners average >3R.

Risk budget template

item rule of thumb
risk per trade 0.5–1% of account (owner framework: a hard number, not a mood)
risk per day ≤ 2× per-trade risk
max trades / day fixed; stop trading after a loss series or the daily cap
move to break-even after 1R in your favor, by rule, not by feel
partial close / exit predefined conditions (e.g. 2R target, structure break)

Cross-check with the backtest engine

risk_size(symbol, risk_amount, stop_pips) in src/tvmcp/backtest/forex.py is the same math this skill uses — verify your hand calculation against it once if unsure, then trust the numbers.

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. 9d ago First seen · 54 lines · 81 tokens per session scan A 724532ca38a1

Subscribe to this mod's changes

risk-sizing is a skill published in the GitHub repository Miha21222/tradingview-mcp (0 stars, last pushed 13d ago), licensed MIT. It adds 81 tokens to every session and 632 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-31.

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

trading-risk-gate

Unified pre-trade safety gate: Ruin check (Law #1), ergodicity audit, and win-rate dominance validation. Absorbs: ergodicity-check, law-of-ruin, win-rate-dominance.

winstonkoh87/Athena-Public · 53 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