From tradermonty-claude-trading-skills
Calculates risk-based position sizes for long stock trades using fixed fractional, ATR-based, or Kelly criterion methods. Supports stop-loss distances, volatility scaling, and sector concentration checks.
npx claudepluginhub joshuarweaver/cascade-business-ops --plugin tradermonty-claude-trading-skillsThis skill uses the workspace's default tool permissions.
Calculate the optimal number of shares to buy for a long stock trade based on risk management principles. Supports three sizing methods:
Generates design tokens/docs from CSS/Tailwind/styled-components codebases, audits visual consistency across 10 dimensions, detects AI slop in UI.
Records polished WebM UI demo videos of web apps using Playwright with cursor overlay, natural pacing, and three-phase scripting. Activates for demo, walkthrough, screen recording, or tutorial requests.
Delivers idiomatic Kotlin patterns for null safety, immutability, sealed classes, coroutines, Flows, extensions, DSL builders, and Gradle DSL. Use when writing, reviewing, refactoring, or designing Kotlin code.
Calculate the optimal number of shares to buy for a long stock trade based on risk management principles. Supports three sizing methods:
All methods apply portfolio constraints (max position %, max sector %) and output a final recommended share count with full risk breakdown.
Collect from the user:
If the user provides a stock ticker but not specific prices, use available tools to look up the current price and suggest entry/stop levels based on technical analysis.
Run the position sizing calculation:
# Fixed Fractional (most common)
python3 skills/position-sizer/scripts/position_sizer.py \
--account-size 100000 \
--entry 155 \
--stop 148.50 \
--risk-pct 1.0 \
--output-dir reports/
# ATR-Based
python3 skills/position-sizer/scripts/position_sizer.py \
--account-size 100000 \
--entry 155 \
--atr 3.20 \
--atr-multiplier 2.0 \
--risk-pct 1.0 \
--output-dir reports/
# Kelly Criterion (budget mode - no entry)
python3 skills/position-sizer/scripts/position_sizer.py \
--account-size 100000 \
--win-rate 0.55 \
--avg-win 2.5 \
--avg-loss 1.0 \
--output-dir reports/
# Kelly Criterion (shares mode - with entry/stop)
python3 skills/position-sizer/scripts/position_sizer.py \
--account-size 100000 \
--entry 155 \
--stop 148.50 \
--win-rate 0.55 \
--avg-win 2.5 \
--avg-loss 1.0 \
--output-dir reports/
Read references/sizing_methodologies.md to provide context on the chosen method, risk guidelines, and portfolio constraint best practices.
If the user has not specified a single method, run multiple scenarios for comparison:
Add constraints if the user has portfolio context:
python3 skills/position-sizer/scripts/position_sizer.py \
--account-size 100000 \
--entry 155 \
--stop 148.50 \
--risk-pct 1.0 \
--max-position-pct 10 \
--max-sector-pct 30 \
--current-sector-exposure 22 \
--output-dir reports/
Explain which constraint is binding and why it limits the position.
Present the final recommendation including:
{
"schema_version": "1.0",
"mode": "shares",
"parameters": {
"entry_price": 155.0,
"account_size": 100000,
"stop_price": 148.50,
"risk_pct": 1.0
},
"calculations": {
"fixed_fractional": {
"method": "fixed_fractional",
"shares": 153,
"risk_per_share": 6.50,
"dollar_risk": 1000.0,
"stop_price": 148.50
},
"atr_based": null,
"kelly": null
},
"constraints_applied": [],
"final_recommended_shares": 153,
"final_position_value": 23715.0,
"final_risk_dollars": 994.50,
"final_risk_pct": 0.99,
"binding_constraint": null
}
Generated automatically alongside the JSON report. Contains:
Reports are saved to reports/ with filenames position_sizer_YYYY-MM-DD_HHMMSS.json and .md.
references/sizing_methodologies.md: Comprehensive guide to Fixed Fractional, ATR-based, and Kelly Criterion methods with examples, comparison table, and risk management principlesscripts/position_sizer.py: Main calculation script (CLI interface)