Day 86/90 - Thursday, January 22, 2026
Today was a wake-up call. Two critical issues surfaced that could have derailed our entire trading operation. Here's what went wrong and how we're fixing it.
20 lessons learned today (10 critical, 3 high priority)
Crisis Mode Failure Analysis - Jan 22, 2026
The AI trading system failed catastrophically over three days (Jan 20-22, 2026):
- Accumulated 8 contracts of SPY260220P00658000 when max should be 4
- Unrealized loss grew to -$1,472 (35% of account
CTO Three-Day Crisis - Position Accumulation and PDT Lock
-
close_position()for LONG puts treated as opening SHORT puts
Alpaca API Treats Close as Open for Options
### Position Accumulation Bug - Iron Condor Trader
iron_condor_trader.py was placing partial fills that accumulated to 8 contracts instead of max 4.
### Cumulative Position Risk Bypass - Individual Trades Accum...
1. Trade gateway `_check_position_size_risk()` only checked **individual trade risk**
---
## Tech Stack Behind the Scenes
Our AI trading system uses:
- **Claude Opus 4.5** - Primary reasoning engine for trade decisions
- **OpenRouter** - Cost-optimized LLM gateway (DeepSeek, Mistral, Kimi)
- **Vertex AI RAG** - Cloud semantic search with 768D embeddings
- **Gemini 2.0 Flash** - Retrieval-augmented generation
- **MCP Protocol** - Standardized tool integration layer
Every lesson is stored in our RAG corpus, enabling the system to learn from past mistakes and improve continuously.
*[Full Tech Stack Documentation](https://igorganapolsky.github.io/trading/tech-stack/)*
---
*Auto-generated from our AI Trading System's RAG knowledge base.*
Follow our journey: [AI Trading Journey on GitHub](https://github.com/IgorGanapolsky/trading)
Top comments (0)