FM Consulting
Margin Trader
An AI-powered margin trading system for Kraken Pro — Claude analyzes markets on a five-minute cycle and proposes risk-checked trade signals, guarded by a five-layer safety system before any of them touch real money.
Case study
The problem
Systematic crypto margin trading is unforgiving of exactly the mistakes people make under pressure: emotional overrides, inconsistent position sizing, skipped stop-losses, and decisions nobody can reconstruct afterward. Off-the-shelf trading bots either hide their logic in a black box or hard-code a single rigid strategy with no reasoning trail — neither is enough confidence to risk real leveraged capital on autopilot.
The solution
Margin Trader turns Claude into the trading brain: every five minutes it analyzes OHLCV data and technical indicators (RSI, EMA, MACD, Bollinger Bands) for each active pair and returns a structured signal — action, confidence, leverage, position size, stop-loss, take-profit, and its reasoning in plain language. Every signal then passes through a seven-check risk engine (daily loss limits, confidence thresholds, leverage caps, position limits, per-trade risk sizing) before it can become a trade, sitting behind a five-layer safety system — paper-trading defaults, database-level trading flags, the risk engine itself, an optional manual-confirmation gate, and a one-click kill switch — between any signal and real money. Every trade, signal, and piece of AI reasoning is logged permanently, and Claude also writes a plain-language performance review every 7 days — what worked, what didn't, and concrete parameter suggestions — for a human to act on or ignore.
How it was built
Built as a FastAPI/SQLAlchemy backend paired with a Next.js/TypeScript dashboard, with the risk engine deliberately isolated from the AI engine so no prompt or model response can ever bypass a hard limit — Claude proposes, the risk engine disposes. The system always starts in paper-trading mode with auto-trading off, enforced independently at both the environment-variable layer and the database layer, so a misconfigured deploy still can't place a live order. Kraken API calls run through a synchronous client library offloaded to a thread pool so they never block the async event loop, and the production deployment sits behind real single-admin authentication — a bcrypt-hashed password, a signed HttpOnly session cookie, and rate-limited login attempts — replacing an earlier shared-secret-in-localStorage approach.
More projects

- Platform
- AI
Delivery Crew
A cross-functional AI delivery crew — PO, Architect, Frontend, Backend, Security, QA, and DevOps agents — turning a rough feature request into a real, reviewable delivery plan through a dependency-ordered pipeline with a genuine human revision loop.

- AI
- Platform
Scopecraft
AI-assisted proposal drafting for consultants — turns a rough client brief into a client-ready statement of work in minutes, then tracks it from draft to signed decision.

- AI
- Customer Experience
AI Support Workflow Optimization
A platform-agnostic AI triage layer for support teams — connects to Zendesk, Salesforce, or any ticketing system, classifying tickets and drafting ready-to-send responses with a human review step before anything goes out.