Memory Infrastructure for AI
AI has no memory.
We're fixing that.
TradeMemory Protocol gives AI trading agents persistent, structured memory. Record every decision. Discover patterns. Evolve strategy. Open source.
The Problem
Your AI forgets everything.
Every conversation starts from zero. No memory of past trades, no learned patterns, no accumulated judgment.
SESSIONSTATUS
Jan 15 — XAUUSD breakout analysis✓ done
Jan 16 — Same setup, no memory of Jan 15✗ lost
Jan 17 — Same mistake repeated✗ lost
Jan 18 — Pattern forgotten again✗ lost
Jan 19 — Still starting from zero...✗ lost
No learning loop
AI analyzes, then forgets. It can't say "this setup failed 4 times last month."
Journals are for humans
Trading journals exist, but AI agents can't query them in real-time decisions.
No pattern evolution
Without memory, AI can't discover that London breakouts work but Asian session entries don't.
The Solution
Three layers of memory.
Inspired by how veteran traders develop expertise — from raw experience to pattern recognition to intuitive judgment.
L1 · Raw Trades
Record Everything
Every trade auto-recorded with full context — entry, exit, SL, TP, session, outcome, and AI reasoning.
record_trade(XAUUSD, LONG,
entry=2038.50, sl=2032.00,
session="london", result=WIN)
entry=2038.50, sl=2032.00,
session="london", result=WIN)
L2 · Patterns
Discover What Works
Reflection engine analyzes history, extracts patterns: which strategies win, which sessions to avoid.
london_breakout: 73% win rate
asia_entries: 52% win rate
nfp_counter: 23% → avoid
asia_entries: 52% win rate
nfp_counter: 23% → avoid
L3 · Strategy
Evolve Judgment
Patterns become real-time adjustments. Memory becomes the AI equivalent of "feel for the market."
asia_session → size × 0.8
london_breakout → full position
high_volatility → widen stops
london_breakout → full position
high_volatility → widen stops
MCP Protocol
7 tools. Any AI agent.
Built on Anthropic's Model Context Protocol. Works with Claude, GPT, open-source models. Supports MT5, Binance, Alpaca.
record_trade
— Log trades with full context
get_trade_history
— Query past trades
reflect_on_trades
— Trigger pattern discovery
get_patterns
— Retrieve discovered patterns
get_strategy_adjustments
— Real-time modifications
get_memory_stats
— Memory dashboard
search_memory
— Semantic search across layers
MIT Licensed
— Open source, forever
Get Started
Give your AI agent
a memory.
a memory.
36 tests passing. MIT licensed. 5-minute setup.