DEV Community

Cover image for Top 5 Claude Code Skills for Algorithmic Trading
Kevin Meneses González
Kevin Meneses González

Posted on • Originally published at Medium

Top 5 Claude Code Skills for Algorithmic Trading

Most traders think the bottleneck is strategy.

It's not.

The bottleneck is the time between "I have an idea" and "this is running in production." Writing boilerplate, wiring APIs, debugging vectorbt errors at 2am. That's where most strategies die.

If you're:

  • building systematic trading systems in Python,
  • testing technical indicators before deploying real capital,
  • or trying to compress weeks of quant work into days,

This matters.

Claude Code isn't the chatbot. It's an agentic environment that runs in your terminal, reads your files, and executes code on your machine. For algorithmic trading, that changes what's possible.

The real power comes from skillsSKILL.md files that function as instruction sets, telling Claude exactly how to approach a specific task. Think of them as recipes: step-by-step workflows Claude follows automatically when the task matches. Install one, and Claude transforms into a specialist for that domain.

Here are 5 skills from public repositories that make Claude Code genuinely useful for trading — with the install commands, the recipes inside, and working Python code using EODHD for market data.


1. Backtesting Expert — Systematic Strategy Testing

Source: tradermonty/claude-trading-skills · ⭐ 16

git clone https://github.com/tradermonty/claude-trading-skills.git
cp -r claude-trading-skills/skills/backtest-expert ~/.claude/skills/
Enter fullscreen mode Exit fullscreen mode

This skill turns Claude Code into a dedicated backtesting analyst. The SKILL.md recipe instructs Claude to follow a structured workflow every time you describe a strategy:

SKILL RECIPE (backtest-expert):
1. Confirm strategy rules and parameters
2. Fetch historical OHLCV data for the specified symbol and period
3. Compute indicator(s) from scratch — no library black boxes
4. Generate entry/exit signals with explicit conditions
5. Run a vectorized backtest: returns, Sharpe, max drawdown, win rate
6. Output equity curve + summary table
7. Flag overfitting risks if in-sample window < 2 years
Enter fullscreen mode Exit fullscreen mode

In practice, you describe your idea in plain English. Claude follows the recipe.

import requests
import pandas as pd
import numpy as np

API_KEY = "YOUR_EODHD_KEY"

# Fetch EOD historical prices via EODHD REST API
url = f"https://eodhd.com/api/eod/AAPL.US"
params = {
    "api_token": API_KEY,
    "from": "2022-01-01",
    "to": "2024-12-31",
    "period": "d",
    "fmt": "json"
}
data = requests.get(url, params=params).json()
df = pd.DataFrame(data)[["date", "adjusted_close", "volume"]]
df["date"] = pd.to_datetime(df["date"])
df.set_index("date", inplace=True)
df.columns = ["close", "volume"]

# RSI from scratch
delta = df["close"].diff()
gain  = delta.clip(lower=0).rolling(14).mean()
loss  = -delta.clip(upper=0).rolling(14).mean()
df["rsi"] = 100 - (100 / (1 + gain / loss))

# Signals
df["signal"] = 0
df.loc[df["rsi"] < 30, "signal"] =  1  # buy
df.loc[df["rsi"] > 70, "signal"] = -1  # sell

# Vectorized strategy returns
df["returns"]  = df["close"].pct_change()
df["strategy"] = df["signal"].shift(1) * df["returns"]

sharpe = df["strategy"].mean() / df["strategy"].std() * np.sqrt(252)
total  = (1 + df["strategy"]).prod() - 1
print(f"Sharpe: {sharpe:.2f} | Total return: {total:.2%}")
Enter fullscreen mode Exit fullscreen mode

From here you can build: walk-forward validation loops, multi-ticker screeners, parameter sensitivity grids.

Pros

  • Structured workflow prevents skipping the overfitting check
  • Forces explicit signal logic — no implicit library assumptions

Cons

  • Requires a clear strategy description upfront; vague inputs produce generic backtests

Best for: Quants who test 5–10 strategy variants per week and need reproducible, comparable results across all of them.


2. Market Data Pipeline — EODHD Integration

Source: JoelLewis/finance_skills · trading-operations plugin

npx skills add JoelLewis/finance_skills --plugin trading-operations
Enter fullscreen mode Exit fullscreen mode

This skill handles the full data ingestion layer. Its recipe standardizes how Claude fetches and structures market data — EOD prices, intraday bars, fundamentals, and real-time quotes — from a single provider.

SKILL RECIPE (market-data-pipeline):
1. Identify data type needed: EOD / intraday / fundamentals / real-time
2. Select the correct EODHD endpoint for that data type
3. Build the request with proper params (symbol format, date range, interval)
4. Normalize response to a DataFrame with standard column names
5. Apply corporate-action adjustments for historical price analysis
6. Cache the result to avoid redundant API calls in the same session
7. Return the DataFrame ready for indicator computation
Enter fullscreen mode Exit fullscreen mode

Bad data is the silent killer of backtests. Survivorship bias, unadjusted prices, missing corporate actions — these don't throw errors. They just make your strategy look better than it is.

import requests
import pandas as pd

API_KEY = "YOUR_EODHD_KEY"

def fetch_eod(symbol: str, start: str, end: str) -> pd.DataFrame:
    r = requests.get(
        f"https://eodhd.com/api/eod/{symbol}",
        params={"api_token": API_KEY, "from": start, "to": end, "period": "d", "fmt": "json"}
    )
    df = pd.DataFrame(r.json())
    df["date"] = pd.to_datetime(df["date"])
    return df.set_index("date")[["open", "high", "low", "close", "adjusted_close", "volume"]]

def fetch_intraday(symbol: str, interval: str = "1m") -> pd.DataFrame:
    r = requests.get(
        f"https://eodhd.com/api/intraday/{symbol}",
        params={"api_token": API_KEY, "interval": interval, "fmt": "json"}
    )
    df = pd.DataFrame(r.json())
    df["datetime"] = pd.to_datetime(df["datetime"])
    return df.set_index("datetime")[["open", "high", "low", "close", "volume"]]

def fetch_fundamentals(symbol: str) -> dict:
    r = requests.get(
        f"https://eodhd.com/api/fundamentals/{symbol}",
        params={"api_token": API_KEY, "fmt": "json"}
    )
    return r.json()

# Usage
aapl     = fetch_eod("AAPL.US", "2023-01-01", "2024-12-31")
fund     = fetch_fundamentals("AAPL.US")
eps      = fund["Highlights"]["EPS"]
print(f"EPS: {eps} | Latest adjusted close: ${aapl['adjusted_close'].iloc[-1]:.2f}")
Enter fullscreen mode Exit fullscreen mode

EODHD covers 70+ exchanges worldwide — US equities, ETFs, forex, crypto — with corporate-action-adjusted prices and a free tier for prototyping.

👉 Get started with EODHD and get 10% off any paid plan: eodhd.com

Pros

  • Adjusted EOD + intraday (1-minute) + fundamentals + real-time from a single API
  • Free tier available; paid plans from €19.99/mo

Cons

  • Real-time non-delayed quotes require a paid plan

Best for: Anyone building a serious backtesting or live system who needs institutional-quality data at indie-developer prices.


3. Signal Generator — Strategy Logic to Executable Code

Source: ScientiaCapital/skills · active/signal-generation

git clone https://github.com/scientiacapital/skills.git
cp -r skills/active/signal-generation ~/.claude/skills/
Enter fullscreen mode Exit fullscreen mode

You have a strategy. It lives in your head, in a research note, or in a TradingView Pine Script. You need it as clean, vectorized Python. This skill handles the translation.

SKILL RECIPE (signal-generation):
1. Parse strategy rules from natural language into explicit conditions
2. Map each condition to a pandas/numpy operation
3. Compute indicators using vectorized operations (no row-by-row loops)
4. Build entry and exit Series separately
5. Apply time-of-day or session filters if specified
6. Output DataFrame: [close, *indicators, signal, position]
7. Verify: no lookahead bias (all indicators shifted before signal comparison)
Enter fullscreen mode Exit fullscreen mode
import requests
import pandas as pd
import numpy as np

API_KEY = "YOUR_EODHD_KEY"

r = requests.get(
    "https://eodhd.com/api/eod/TSLA.US",
    params={"api_token": API_KEY, "from": "2023-01-01", "to": "2024-12-31", "period": "d", "fmt": "json"}
)
df = pd.DataFrame(r.json())
df["date"] = pd.to_datetime(df["date"])
df = df.set_index("date")[["high", "low", "adjusted_close"]].rename(columns={"adjusted_close": "close"})

# EMA crossover + ADX filter — no TA-Lib
def ema(s, n):
    return s.ewm(span=n, adjust=False).mean()

def compute_adx(df, n=14):
    tr = pd.concat([
        df["high"] - df["low"],
        (df["high"] - df["close"].shift()).abs(),
        (df["low"]  - df["close"].shift()).abs()
    ], axis=1).max(axis=1)
    dm_pos = (df["high"] - df["high"].shift()).clip(lower=0)
    dm_neg = (df["low"].shift() - df["low"]).clip(lower=0)
    atr    = tr.ewm(span=n, adjust=False).mean()
    di_pos = 100 * dm_pos.ewm(span=n, adjust=False).mean() / atr
    di_neg = 100 * dm_neg.ewm(span=n, adjust=False).mean() / atr
    dx     = (100 * (di_pos - di_neg).abs() / (di_pos + di_neg))
    return dx.ewm(span=n, adjust=False).mean()

df["ema20"] = ema(df["close"], 20)
df["ema50"] = ema(df["close"], 50)
df["adx"]   = compute_adx(df)

cross_up     = (df["ema20"] > df["ema50"]) & (df["ema20"].shift() <= df["ema50"].shift())
adx_confirmed = df["adx"] > 25
df["signal"] = (cross_up & adx_confirmed).astype(int)

print(df[df["signal"] == 1][["close", "ema20", "ema50", "adx"]].tail())
Enter fullscreen mode Exit fullscreen mode

Pros

  • Lookahead-bias check is baked into the recipe — Claude flags it before delivering code
  • Produces vectorized pandas operations: production-ready, not tutorial code

Cons

  • Always validate signal logic manually before connecting to live capital

Best for: Traders who think in strategy rules and want Claude to handle the Python translation.


4. Risk Manager — Position Sizing and Exposure Control

Source: JoelLewis/finance_skills · wealth-management plugin (risk-measurement skill)

npx skills add JoelLewis/finance_skills --plugin wealth-management
Enter fullscreen mode Exit fullscreen mode

Strategy without risk management is speculation with extra steps. This skill gives Claude a structured decision framework for every sizing and exposure calculation.

SKILL RECIPE (risk-management):
1. Calculate ATR-based stop distance for the current setup
2. Apply fixed-fractional sizing (default: 1% account risk per trade)
3. Check portfolio heat: flag if total exposure > 5% of equity
4. Compute Historical VaR (95% confidence) on the current portfolio
5. Output: entry, stop, shares, dollar risk, R-multiple target
6. Define kill-switch threshold: halt new entries if drawdown > X%
Enter fullscreen mode Exit fullscreen mode
import requests
import pandas as pd
import numpy as np

API_KEY = "YOUR_EODHD_KEY"

r = requests.get(
    "https://eodhd.com/api/eod/AAPL.US",
    params={"api_token": API_KEY, "from": "2024-10-01", "to": "2024-12-31", "period": "d", "fmt": "json"}
)
df = pd.DataFrame(r.json())
df["date"] = pd.to_datetime(df["date"])
df = df.set_index("date")[["high", "low", "adjusted_close"]].rename(columns={"adjusted_close": "close"})

# ATR (14-period)
tr  = pd.concat([
    df["high"] - df["low"],
    (df["high"] - df["close"].shift()).abs(),
    (df["low"]  - df["close"].shift()).abs()
], axis=1).max(axis=1)
atr = tr.ewm(span=14, adjust=False).mean().iloc[-1]

def size_position(equity, risk_pct, entry, stop):
    risk_per_share = abs(entry - stop)
    if risk_per_share == 0:
        return 0
    return int((equity * risk_pct / 100) / risk_per_share)

equity      = 10_000
entry_price = df["close"].iloc[-1]
stop_price  = entry_price - (2 * atr)
shares      = size_position(equity, 1.0, entry_price, stop_price)

print(f"Entry:         ${entry_price:.2f}")
print(f"Stop (2×ATR):  ${stop_price:.2f}  |  ATR: ${atr:.2f}")
print(f"Position size: {shares} shares")
print(f"Dollar risk:   ${shares * abs(entry_price - stop_price):.2f}")
Enter fullscreen mode Exit fullscreen mode

Pros

  • Generates reusable, parameterized modules — not hardcoded values per trade
  • Recipe includes portfolio heat check alongside per-trade sizing

Cons

  • Sizing models require human review — Claude won't know your personal drawdown tolerance

Best for: Systematic traders running multiple strategies simultaneously who need a consistent, auditable risk framework.


5. Live Signal Monitor — Real-Time Alerts

Source: roman-rr/trading-skills · trading-signals skill

git clone https://github.com/roman-rr/trading-skills.git
cp -r trading-skills/trading-signals ~/.claude/skills/
Enter fullscreen mode Exit fullscreen mode

The final skill closes the loop from research to live monitoring. Instead of running backtests, you're watching for signals in real time and triggering alerts when conditions are met.

SKILL RECIPE (live-signal-monitor):
1. Fetch real-time quote and recent EOD bars via EODHD REST API
2. Maintain a rolling window of bars in memory
3. Recompute indicator(s) on each new bar
4. Evaluate signal conditions — entry, exit, or hold
5. On signal trigger: log timestamp, symbol, price, indicator values
6. Send alert (print / Telegram / email)
7. Never execute orders directly — output signal only
Enter fullscreen mode Exit fullscreen mode
import requests
import pandas as pd
import numpy as np
import time
from datetime import datetime

API_KEY = "YOUR_EODHD_KEY"

def fetch_live_quote(symbol: str) -> float:
    r = requests.get(
        f"https://eodhd.com/api/real-time/{symbol}",
        params={"api_token": API_KEY, "fmt": "json"}
    )
    return r.json().get("close", None)

def fetch_recent_eod(symbol: str, n: int = 30) -> pd.Series:
    r = requests.get(
        f"https://eodhd.com/api/eod/{symbol}",
        params={"api_token": API_KEY, "period": "d", "fmt": "json"}
    )
    df = pd.DataFrame(r.json()).tail(n)
    df["date"] = pd.to_datetime(df["date"])
    return df.set_index("date")["adjusted_close"].rename("close")

def compute_rsi(series, n=14):
    delta = series.diff()
    gain  = delta.clip(lower=0).rolling(n).mean()
    loss  = -delta.clip(upper=0).rolling(n).mean()
    return 100 - (100 / (1 + gain / loss))

symbol = "AAPL.US"
print(f"Monitoring {symbol} | {datetime.now():%Y-%m-%d %H:%M}")

while True:
    close_series = fetch_recent_eod(symbol, n=30)
    live_price   = fetch_live_quote(symbol) or close_series.iloc[-1]

    # Append live price as today's bar
    today = pd.Timestamp.now().normalize()
    close_series[today] = live_price

    rsi    = compute_rsi(close_series).iloc[-1]
    status = "OVERSOLD → BUY WATCH" if rsi < 30 else "OVERBOUGHT → SELL WATCH" if rsi > 70 else "NEUTRAL"

    print(f"[{datetime.now():%H:%M:%S}] {symbol} | ${live_price:.2f} | RSI: {rsi:.1f} | {status}")

    if rsi < 30:
        print(f"  🔔 ALERT: RSI oversold at {rsi:.1f} — review entry")

    time.sleep(60)
Enter fullscreen mode Exit fullscreen mode

Pair this with a Telegram bot and you have automated signal detection running 24/7 — no manual chart watching.

👉 Get started with EODHD and unlock 10% off any paid plan: eodhd.com

Pros

  • Polling approach works with the free EODHD tier — no WebSocket subscription required
  • Skill enforces the signal/execution separation — no accidental live orders

Cons

  • 60-second polling isn't suitable for sub-minute strategies (use EODHD's WebSocket feed for those)

Best for: Swing and intraday traders who want automated signal detection without building a full execution system.


The shift

Claude Code skills aren't magic. They're structured recipes that eliminate the "figure it out from scratch" tax on every new project.

Five skills. One reliable data layer. The bottleneck shifts from implementation to what it should always have been: deciding which strategies are worth testing.

Most quants don't lack ideas. They lack the bandwidth to implement fast enough to find the ones that actually work.

That's what changes.


Looking for technical content for your company? I can help — LinkedIn · kevinmenesesgonzalez@gmail.com

Top comments (0)