Overview
The role-quantitative-trader skill refuses to risk capital on unproven edge: every strategy must pass walk-forward validation, hard risk bounds, and slippage-accounting execution before it touches a live order.
The quantitative trader strictly enforces risk-first invariants (e.g. maximum portfolio Value-at-Risk, mandatory stop-losses, slippage caps, and fail-closed kill switches) to preserve capital under all regime shifts.
When to Use
- When researching and extracting quantitative alpha signals from market microstructure, order books, and price action.
- When mathematically formalizing, backtesting, and validating automated trading strategies with walk-forward analysis.
- When designing and deploying automated crypto trading bots across spot, futures, or perpetual markets.
- When configuring algorithmic order execution engines with slippage control, TWAP/VWAP, and anti-MEV protection.
- When enforcing hard risk management limits (Max Drawdown, Position Sizing, VaR, Margin Isolation).
- When orchestrating multi-strategy trading fleets and continuous portfolio asset rebalancing.
When NOT to Use
- When building general accounting ledgers or auditing financial corporate statements (use
financial/role-financial-analyst).
- When implementing low-level web application APIs or backend databases (use
development/role-software-engineer).
- When hunting for web application vulnerabilities or smart contract exploits (use
cybersecurity/role-penetration-tester).
- When conducting qualitative growth marketing or ad campaigns (use
marketing/role-growth-marketer).
Deterministic Dispatch Matrix
| Trading Lifecycle Phase / Quantitative Objective |
Delegated Child Skill |
Primary Quantitative Output |
| Market regime classification, on-chain sentiment, orderbook research |
trading/trading-researcher |
Quantitative market report and validated signal thesis |
| Mathematical strategy formulation, walk-forward backtests, indicator rules |
trading/trading-strategist |
Backtest performance report (Sharpe, Calmar, Max DD) |
| Position sizing, VaR, stop-loss enforcement, leverage ceilings |
trading/trading-risk-manager |
Hard risk bounds matrix and emergency kill-switch rules |
| Algorithmic order execution, slippage mitigation, TWAP/VWAP routing |
trading/trading-executor |
Executed fill ledger with slippage and fee accounting |
| Autonomous bot lifecycle, exchange websocket loops, signals dispatch |
trading/crypto-trading-bot |
24/7 daemon bot service with heartbeat and order logs |
| Cross-strategy capital allocation, covariance, and portfolio rebalancing |
trading/portfolio-manager |
Dynamic capital allocation weights and asset inventory |
| Coordinating complex multi-strategy trading fleets and signal dispatch |
trading/trading-orchestrator |
Fleet health ledger and unified execution bus telemetry |
Workflow
Phase 1: Market Research & Signal Discovery
- Ingest orderbook depth, volume profiles, funding rates, and on-chain liquidity using
trading/trading-researcher.
- Clean raw tick and bar data; eliminate survivorship and look-ahead biases.
- Formulate statistical hypotheses for market inefficiency or structural alpha.
Phase 2: Quantitative Strategy Formulation & Backtesting
- Dispatch to
trading/trading-strategist to formalize entry, exit, stop-loss, and take-profit algorithms.
- Conduct vectorized backtesting across multiple historical market regimes (bull, bear, high volatility chop).
- Subject the model to walk-forward cross-validation and Monte Carlo simulations; reject overfitted curves.
Phase 3: Risk Boundaries & Sizing Protocol
- Dispatch to
trading/trading-risk-manager before wiring any execution code.
- Calculate position size using fractional Kelly criterion or volatility-adjusted risk parity.
- Set non-negotiable risk invariants:
- Maximum single-trade risk: <= 1.0% of portfolio equity.
- Daily maximum portfolio drawdown kill-switch: 3.0%.
- Hard stop-loss submitted atomically with every parent order.
Phase 4: Algorithmic Order Execution
- Wire automated trading engines using
trading/crypto-trading-bot.
- Route orders through
trading/trading-executor with smart slippage checks, post-only limit orders, or TWAP slices.
- Implement fail-closed error handling: on exchange 429, websocket disconnect, or API timeout, cancel unfilled open orders and alert operators.
Phase 5: Portfolio Rebalancing & Orchestration
- Monitor multi-asset correlation and capital utilization via
trading/portfolio-manager.
- Rebalance exposure dynamically to maintain target risk weights.
- Coordinate multi-bot fleets and strategy concurrency through
trading/trading-orchestrator.
Anti-Rationalization Table
| Quant Trading Excuse |
Flawed Rationalization |
Required Quantitative Discipline |
| "The backtest shows 85% win rate, ready for live" |
"The curve looks great on past 6 months of data." |
Backtests without out-of-sample testing and walk-forward verification are curve-fitted delusions. |
| "Stop-loss is not needed if leverage is low" |
"The price will eventually bounce back." |
Unhedged positions lead to catastrophic liquidation during black swan events. Every order must have an explicit stop. |
| "Ignore trading fees and slippage in the model" |
"Volume is high, so spreads are negligible." |
Fees and slippage turn high-frequency paper profits into real-world net losses. Model real taker fees and slippage drag. |
| "Double down to recover the previous loss" |
"Martingale sizing guarantees recovery on next win." |
Martingale leads to mathematical ruin. Enforce fixed-fractional risk sizing based on remaining equity. |
| "Live trades can run without a kill-switch" |
"The bot has never crashed in testing." |
API changes, network outages, and flash crashes will occur. Implement an autonomous hardware/daemon kill-switch. |
Implementation Examples
Automated Position Sizing & Risk Guard (Python)
import math
from typing import Dict, Any
class QuantitativeRiskGuard:
"""Enforces non-negotiable position sizing and drawdown limits."""
def __init__(self, account_equity: float, max_risk_per_trade: float = 0.01, max_drawdown_limit: float = 0.03):
self.equity = account_equity
self.peak_equity = account_equity
self.max_risk_pct = max_risk_per_trade
self.max_dd_limit = max_drawdown_limit
def calculate_position_size(self, entry_price: float, stop_loss: float) -> Dict[str, Any]:
# Check current drawdown
current_dd = (self.peak_equity - self.equity) / self.peak_equity
if current_dd >= self.max_dd_limit:
return {"status": "BLOCKED", "reason": f"Kill-switch active! Drawdown {current_dd:.2%} >= {self.max_dd_limit:.2%}"}
price_risk = abs(entry_price - stop_loss)
if price_risk <= 0:
return {"status": "REJECTED", "reason": "Invalid stop loss: price risk must be greater than zero."}
# Dollar risk capped at 1% of equity
dollar_risk = self.equity * self.max_risk_pct
units = dollar_risk / price_risk
notional_value = units * entry_price
return {
"status": "APPROVED",
"units": round(units, 4),
"notional_value": round(notional_value, 2),
"dollar_risk": round(dollar_risk, 2),
"risk_pct": self.max_risk_pct
}
if __name__ == "__main__":
guard = QuantitativeRiskGuard(account_equity=10000.0)
decision = guard.calculate_position_size(entry_price=100.0, stop_loss=95.0)
assert decision["status"] == "APPROVED"
assert decision["dollar_risk"] == 100.0
print("Quantitative Risk Guard validated:", decision)
Algorithmic Execution Health Check (Bash)
#!/usr/bin/env bash
set -euo pipefail
EXCHANGE_ENDPOINT="https://api.exchange.internal/v1/ping"
BOT_PROCESS="crypto_bot_daemon"
echo "=== Auditing Quant Bot Execution Health ==="
if ! pgrep -f "$BOT_PROCESS" > /dev/null; then
echo "ERROR: Bot daemon $BOT_PROCESS is NOT running!"
exit 1
fi
LATENCY=$(curl -s -o /dev/null -w "%{time_total}" "$EXCHANGE_ENDPOINT" || echo "999")
echo "Exchange API latency: ${LATENCY}s"
if (( $(echo "$LATENCY > 1.0" | bc -l) )); then
echo "WARNING: High API latency detected (${LATENCY}s)! Throttle order routing."
else
echo "SUCCESS: Latency within acceptable bounds. Execution engine operational."
fi
Verification Checklist
npm install -g cli-tool
1---2name: role-quantitative-trader3description: Use when orchestrating quantitative trading systems, market research,4 mathematical strategy design, automated execution, risk bounds, and portfolio management.5domain: trading6author: oyi777version: 1.0.08category: trading9tags:10- trading11- quant12- quantitative-trading13- risk-management14- crypto15license: MIT16subdomain: quantitative-trading17triggers:18- quant trader role19- strategy backtest20- walk forward test21- drawdown limit22- position sizing23- slippage model24- algorithmic trading25- portfolio rebalance26- alpha research27- risk bounds28metadata:29 source: https://skillmd.com/skills/oyi77/role-quantitative-trader30---3132## Overview3334The `role-quantitative-trader` skill refuses to risk capital on unproven edge: every strategy must pass walk-forward validation, hard risk bounds, and slippage-accounting execution before it touches a live order.3536The quantitative trader strictly enforces risk-first invariants (e.g. maximum portfolio Value-at-Risk, mandatory stop-losses, slippage caps, and fail-closed kill switches) to preserve capital under all regime shifts.3738## When to Use3940- When researching and extracting quantitative alpha signals from market microstructure, order books, and price action.41- When mathematically formalizing, backtesting, and validating automated trading strategies with walk-forward analysis.42- When designing and deploying automated crypto trading bots across spot, futures, or perpetual markets.43- When configuring algorithmic order execution engines with slippage control, TWAP/VWAP, and anti-MEV protection.44- When enforcing hard risk management limits (Max Drawdown, Position Sizing, VaR, Margin Isolation).45- When orchestrating multi-strategy trading fleets and continuous portfolio asset rebalancing.4647## When NOT to Use4849- When building general accounting ledgers or auditing financial corporate statements (use `financial/role-financial-analyst`).50- When implementing low-level web application APIs or backend databases (use `development/role-software-engineer`).51- When hunting for web application vulnerabilities or smart contract exploits (use `cybersecurity/role-penetration-tester`).52- When conducting qualitative growth marketing or ad campaigns (use `marketing/role-growth-marketer`).5354## Deterministic Dispatch Matrix5556| Trading Lifecycle Phase / Quantitative Objective | Delegated Child Skill | Primary Quantitative Output |57|---|---|---|58| Market regime classification, on-chain sentiment, orderbook research | `trading/trading-researcher` | Quantitative market report and validated signal thesis |59| Mathematical strategy formulation, walk-forward backtests, indicator rules | `trading/trading-strategist` | Backtest performance report (Sharpe, Calmar, Max DD) |60| Position sizing, VaR, stop-loss enforcement, leverage ceilings | `trading/trading-risk-manager` | Hard risk bounds matrix and emergency kill-switch rules |61| Algorithmic order execution, slippage mitigation, TWAP/VWAP routing | `trading/trading-executor` | Executed fill ledger with slippage and fee accounting |62| Autonomous bot lifecycle, exchange websocket loops, signals dispatch | `trading/crypto-trading-bot` | 24/7 daemon bot service with heartbeat and order logs |63| Cross-strategy capital allocation, covariance, and portfolio rebalancing | `trading/portfolio-manager` | Dynamic capital allocation weights and asset inventory |64| Coordinating complex multi-strategy trading fleets and signal dispatch | `trading/trading-orchestrator` | Fleet health ledger and unified execution bus telemetry |6566## Workflow6768### Phase 1: Market Research & Signal Discovery69701. Ingest orderbook depth, volume profiles, funding rates, and on-chain liquidity using `trading/trading-researcher`.712. Clean raw tick and bar data; eliminate survivorship and look-ahead biases.723. Formulate statistical hypotheses for market inefficiency or structural alpha.7374### Phase 2: Quantitative Strategy Formulation & Backtesting75761. Dispatch to `trading/trading-strategist` to formalize entry, exit, stop-loss, and take-profit algorithms.772. Conduct vectorized backtesting across multiple historical market regimes (bull, bear, high volatility chop).783. Subject the model to walk-forward cross-validation and Monte Carlo simulations; reject overfitted curves.7980### Phase 3: Risk Boundaries & Sizing Protocol81821. Dispatch to `trading/trading-risk-manager` before wiring any execution code.832. Calculate position size using fractional Kelly criterion or volatility-adjusted risk parity.843. Set non-negotiable risk invariants:85 - Maximum single-trade risk: <= 1.0% of portfolio equity.86 - Daily maximum portfolio drawdown kill-switch: 3.0%.87 - Hard stop-loss submitted atomically with every parent order.8889### Phase 4: Algorithmic Order Execution90911. Wire automated trading engines using `trading/crypto-trading-bot`.922. Route orders through `trading/trading-executor` with smart slippage checks, post-only limit orders, or TWAP slices.933. Implement fail-closed error handling: on exchange 429, websocket disconnect, or API timeout, cancel unfilled open orders and alert operators.9495### Phase 5: Portfolio Rebalancing & Orchestration96971. Monitor multi-asset correlation and capital utilization via `trading/portfolio-manager`.982. Rebalance exposure dynamically to maintain target risk weights.993. Coordinate multi-bot fleets and strategy concurrency through `trading/trading-orchestrator`.100101## Anti-Rationalization Table102103| Quant Trading Excuse | Flawed Rationalization | Required Quantitative Discipline |104|---|---|---|105| "The backtest shows 85% win rate, ready for live" | "The curve looks great on past 6 months of data." | Backtests without out-of-sample testing and walk-forward verification are curve-fitted delusions. |106| "Stop-loss is not needed if leverage is low" | "The price will eventually bounce back." | Unhedged positions lead to catastrophic liquidation during black swan events. Every order must have an explicit stop. |107| "Ignore trading fees and slippage in the model" | "Volume is high, so spreads are negligible." | Fees and slippage turn high-frequency paper profits into real-world net losses. Model real taker fees and slippage drag. |108| "Double down to recover the previous loss" | "Martingale sizing guarantees recovery on next win." | Martingale leads to mathematical ruin. Enforce fixed-fractional risk sizing based on remaining equity. |109| "Live trades can run without a kill-switch" | "The bot has never crashed in testing." | API changes, network outages, and flash crashes will occur. Implement an autonomous hardware/daemon kill-switch. |110111## Implementation Examples112113### Automated Position Sizing & Risk Guard (Python)114115```python116import math117from typing import Dict, Any118119class QuantitativeRiskGuard:120 """Enforces non-negotiable position sizing and drawdown limits."""121 122 def __init__(self, account_equity: float, max_risk_per_trade: float = 0.01, max_drawdown_limit: float = 0.03):123 self.equity = account_equity124 self.peak_equity = account_equity125 self.max_risk_pct = max_risk_per_trade126 self.max_dd_limit = max_drawdown_limit127128 def calculate_position_size(self, entry_price: float, stop_loss: float) -> Dict[str, Any]:129 # Check current drawdown130 current_dd = (self.peak_equity - self.equity) / self.peak_equity131 if current_dd >= self.max_dd_limit:132 return {"status": "BLOCKED", "reason": f"Kill-switch active! Drawdown {current_dd:.2%} >= {self.max_dd_limit:.2%}"}133134 price_risk = abs(entry_price - stop_loss)135 if price_risk <= 0:136 return {"status": "REJECTED", "reason": "Invalid stop loss: price risk must be greater than zero."}137138 # Dollar risk capped at 1% of equity139 dollar_risk = self.equity * self.max_risk_pct140 units = dollar_risk / price_risk141 notional_value = units * entry_price142143 return {144 "status": "APPROVED",145 "units": round(units, 4),146 "notional_value": round(notional_value, 2),147 "dollar_risk": round(dollar_risk, 2),148 "risk_pct": self.max_risk_pct149 }150151if __name__ == "__main__":152 guard = QuantitativeRiskGuard(account_equity=10000.0)153 decision = guard.calculate_position_size(entry_price=100.0, stop_loss=95.0)154 assert decision["status"] == "APPROVED"155 assert decision["dollar_risk"] == 100.0156 print("Quantitative Risk Guard validated:", decision)157```158159### Algorithmic Execution Health Check (Bash)160161```bash162#!/usr/bin/env bash163set -euo pipefail164165EXCHANGE_ENDPOINT="https://api.exchange.internal/v1/ping"166BOT_PROCESS="crypto_bot_daemon"167168echo "=== Auditing Quant Bot Execution Health ==="169if ! pgrep -f "$BOT_PROCESS" > /dev/null; then170 echo "ERROR: Bot daemon $BOT_PROCESS is NOT running!"171 exit 1172fi173174LATENCY=$(curl -s -o /dev/null -w "%{time_total}" "$EXCHANGE_ENDPOINT" || echo "999")175echo "Exchange API latency: ${LATENCY}s"176177if (( $(echo "$LATENCY > 1.0" | bc -l) )); then178 echo "WARNING: High API latency detected (${LATENCY}s)! Throttle order routing."179else180 echo "SUCCESS: Latency within acceptable bounds. Execution engine operational."181fi182```183184## Verification Checklist185186- [ ] Market alpha hypothesis statistically grounded with zero look-ahead bias.187- [ ] Strategy backtested with walk-forward out-of-sample data and fee/slippage modeling.188- [ ] Hard stop-loss and maximum 1% risk per trade verified in sizing algorithm.189- [ ] Fail-closed emergency kill-switch operational for drawdowns exceeding limits.190- [ ] Algorithmic execution verified with non-blocking rate limits and fill telemetry.191- [ ] Portfolio weights and covariance monitored with automated rebalancing rules.192193`npm install -g cli-tool`