Trader Risk logo

Trader Risk

Community
Jakeschincariol
trader-risk

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.

Overview

PublisherJakeschincariol
Repositorytrader-skill
Skill nametrader-risk
Stars
406
Forks
67
Bundled files
1
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • 1 bundled files

    Scripts, templates, and references the model can read while it works. Files are read-only and never executed.

  • Open source

    Published by Jakeschincariol on GitHub. Read the source before you install it.

Installation

Install the Trader Risk AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/Jakeschincariol/trader-skill/tree/main/trader-risk
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Jakeschincariol/trader-skill.git /tmp/trader-skill
mkdir -p .claude/skills
cp -r /tmp/trader-skill/trader-risk .claude/skills/trader-risk
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Trader Risk in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Trader Risk on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Trader Risk is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

trader-risk

The Risk Manager is the gate between a proposal and the broker. Every order written by trader-budget, trader-rebalance or trader-tax passes through it. A BLOCK is final for that order: it does not go to the user for a yes, and it does not go to the broker.

${CLAUDE_SKILL_DIR} below is this skill's folder (where this SKILL.md lives).

bash
python3 "${CLAUDE_SKILL_DIR}/check.py"             # trader/ files; writes trader/state/risk.json
python3 "${CLAUDE_SKILL_DIR}/check.py" --json
python3 "${CLAUDE_SKILL_DIR}/check.py" --no-write  # look without recording

What it reads and writes

filewhat
trader/orders.jsonthe proposed orders
trader/config.jsonthe limits (trader-budget ships config.example.json)
trader/portfolio.jsoncash and holdings; if missing, a fresh account funded with the budget
trader/prices.jsonneeded to size share-count orders and value holdings
trader/state/broker.jsonwhat was placed today, for duplicates and the daily limit
trader/state/risk.jsonthe verdicts it writes, with a fingerprint of each exact order

The checks

Orders are checked in file order, as if each passed order had filled, so a batch that is fine order by order but breaks a rule together is caught.

checkblocks when
formatno symbol, side not buy or sell, both or neither of qty and notional, a notional order that is not market + day (Alpaca's rule), a limit order with no limit price
assetan option symbol while allow_options is false; crypto or anything that is not a US stock or ETF ticker
blockedthe ticker is on the blocked list
sizeunder min_order_usd or over max_order_usd
positionthe stock would be over max_position_pct of the account after the fill
cashthe buy would leave less than the cash buffer, or need margin (allow_margin false)
shorta sell of more than you hold (allow_short false)
duplicatethe same symbol and side twice in one batch, or already placed today
daily limitmore than max_orders_per_day placed today

Warnings do not block, but say them to the user: a LIVE account, a number sent as a number instead of a string, an advanced (bracket) order.

Steps

  1. Make sure trader/prices.json is fresh if any order is a share count or any holding needs a value (trader-alerts: alerts.py quote --holdings --write).
  2. Run check.py. Exit code 0 means every order passed, 1 means at least one was blocked.
  3. Tell the user the result in plain words, order by order. For a BLOCK, give the reason and the fix (a smaller amount, a different stock, or a rule the user may decide to change). Never change a limit yourself.
  4. If the orders change in any way, run the check again. trader-broker matches each order to its verdict by fingerprint, so an edited order is not ready until it passes again, and a verdict from yesterday does not count today.

Example: the reel

The five buys from trader-budget (AAPL $1,250, AXP $1,119, GOOGL $823, KO $708, BAC $600) on a fresh $5,000 paper account with the example config:

PASS  #1 buy AAPL $1,250
PASS  #2 buy AXP $1,119
PASS  #3 buy GOOGL $823
PASS  #4 buy KO $708
PASS  #5 buy BAC $600
5 passed, 0 blocked. Cash after the passed orders: $500 (paper account).

AAPL lands exactly on the 25% cap ($1,250 of $5,000), which is allowed. A sixth order, another $100 of AAPL, is blocked three ways: it would dip into the $500 cash buffer, put AAPL over its 25% cap, and repeat AAPL in the same batch.

What it never does

It never places an order, never edits an order to make it pass, never loosens a limit, and never treats a PASS as the user's yes. A PASS only means the order is allowed to be shown to the user.

Safety

  • Education and tooling, not financial advice. A PASS is a rules check, not a recommendation.
  • Paper trading by default ("paper": true). Going live is the user's own decision, in their own config.
  • Nothing in this pack places an order except trader-broker, and only when all three hold: trader-risk passed that exact order today, the user typed an explicit yes for that one order in the chat, and the user clicked Allow once on Claude's own card because the order tool is set to "Needs approval" (Customize > Connectors > tool permissions). Never set an order tool to "Always allow".
  • No options, margin, short selling or leverage unless the config allows it and the user confirms.
  • Broker keys live in environment variables or the Claude Desktop config, never in the chat.

Bundled files

The model reads these on demand while the skill is loaded. They are exposed as readable files and are never executed.

Frequently asked questions

What does the Trader Risk AI skill do?

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 befor...

Why use Trader Risk on TypingMind?

Because you install it once and use it with any model. Trader Risk is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Trader Risk in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/Jakeschincariol/trader-skill/tree/main/trader-risk. TypingMind reads its SKILL.md and bundles its files and installs it as a skill you can enable per chat.

Which AI models can use Trader Risk?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Trader Risk?

As many as you like. As long as a model supports skills, you can use Trader Risk with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Trader Risk AI skill free?

Yes. It is published on GitHub by Jakeschincariol under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇