Tooluck logoTooluck
SKILL.md

trader-risk

Agent skill fromJakeschincariol/trader-skill

Risk Manager. Checks every proposed order against your limits before it can reach the broker and blocks anything over them: blocked tickers, max order size, minimum order, max position percent after the fill, the cash buffer, margin, short sales, options and crypto (off unless allowed), malformed orders, duplicates and a daily order limit. Prints PASS or BLOCK with the reason for each order and records the verdicts so trader-broker only shows an order that passed. Use when the user says "check my orders", "is this safe", "risk check", "does this break my rules", "can I place this", or before /trader-broker, always.

How to install trader-risk

install trader-risk
# install the trader-skill pack with the skills CLI
npx skills add Jakeschincariol/trader-skill

# or add only this skill to Claude Code: copy the folder

trader-risk/

# into

~/.claude/skills/trader-risk/ (all projects)

.claude/skills/trader-risk/ (one project)

trader-risk/SKILL.md

MITFull file
1# trader-risk
2
3The Risk Manager is the gate between a proposal and the broker. Every order
4written by trader-budget, trader-rebalance or trader-tax passes through it.
5A BLOCK is final for that order: it does not go to the user for a yes, and
6it does not go to the broker.
7
8`${CLAUDE_SKILL_DIR}` below is this skill's folder (where this SKILL.md lives).
9
10```bash
11python3 "${CLAUDE_SKILL_DIR}/check.py" # trader/ files; writes trader/state/risk.json
12python3 "${CLAUDE_SKILL_DIR}/check.py" --json
13python3 "${CLAUDE_SKILL_DIR}/check.py" --no-write # look without recording
14```
15
16## What it reads and writes
17
18| file | what |
19| --- | --- |
20| `trader/orders.json` | the proposed orders |
21| `trader/config.json` | the limits (trader-budget ships `config.example.json`) |
22| `trader/portfolio.json` | cash and holdings; if missing, a fresh account funded with the budget |
23| `trader/prices.json` | needed to size share-count orders and value holdings |
24| `trader/state/broker.json` | what was placed today, for duplicates and the daily limit |
25| `trader/state/risk.json` | the verdicts it writes, with a fingerprint of each exact order |
26
27## The checks
28
29Orders are checked in file order, as if each passed order had filled, so a
30batch that is fine order by order but breaks a rule together is caught.
31
32| check | blocks when |
33| --- | --- |
34…

Excerpt shown under the repository's MIT license.

More skills in trader-skill

Newsletter

Join the Community

Subscribe to our newsletter for the latest news and updates