TradeMemory Protocol

v0.3.1Finance & Fintechstable

An MCP server that provides AI trading agents with persistent, outcome-weighted memory to learn from historical performance and detect behavioral biases. It enables agents to automatically adjust strategies and optimize position sizing based on conte

ai-agentsclaudecryptoevolution-engineforex
Share:
972
Stars
0
Downloads
0
Weekly
0/5

What is TradeMemory Protocol?

TradeMemory Protocol is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to mcp server that provides ai trading agents with persistent, outcome-weighted memory to learn from historical performance and detect behavioral biases. it enables agents to automatically adjust strateg...

An MCP server that provides AI trading agents with persistent, outcome-weighted memory to learn from historical performance and detect behavioral biases. It enables agents to automatically adjust strategies and optimize position sizing based on conte

This server falls under the Finance & Fintech and Knowledge & Memory categories on MCPgee, the world's largest MCP server directory with 33,000+ servers.

Features

  • An MCP server that provides AI trading agents with persisten

Use Cases

An MCP server that provides AI trading agents with persistent, outcome-weighted
mnemox-ai

Maintainer

LicenseMIT License
Languagepython
Versionv0.3.1
UpdatedMay 22, 2026
Statushealthy
Maintenanceactive

Works with

ClaudeOpenAIwindowsmacoslinux

Installation

PIP

pip install tradememory-protocol

Manual Installation

pip install tradememory-protocol

Configuration

Configuration Details

Config File

claude_desktop_config.json

Performance

Response Metrics

Response Time< 200ms
ThroughputMedium

Resource Usage

Memory UsageLow
CPU UsageLow

How to Set Up and Use TradeMemory Protocol

TradeMemory Protocol is an MCP server that gives AI trading agents a persistent, outcome-weighted memory layer so they can learn from their own historical performance rather than starting fresh every session. It stores trades with context, detects behavioral biases, runs pre-trade risk checks through a five-factor legitimacy gate, and evolves strategies by discovering patterns across past decisions. Traders and algorithmic agents use it with MetaTrader 5 (MT5), crypto, or forex workflows to build a self-improving system that adjusts position sizing and strategy selection based on what has actually worked.

Prerequisites

  • Python 3.9+ and pip (or the uv/uvx tool) installed
  • An MCP-compatible client such as Claude Desktop or Claude Code CLI
  • Optional: MetaTrader 5 account credentials for MT5 sync features
  • Optional: Docker and Docker Compose for containerized deployment
1

Install the package

Install TradeMemory Protocol from PyPI using pip. The package includes the MCP server and all dependencies including SQLite storage for the community edition.

pip install tradememory-protocol
2

Configure Claude Desktop

Add the server to claude_desktop_config.json using uvx so the server is launched automatically when Claude Desktop starts.

{
  "mcpServers": {
    "tradememory": {
      "command": "uvx",
      "args": ["tradememory-protocol"]
    }
  }
}
3

Add via Claude Code CLI (alternative)

If you use Claude Code in the terminal, register the server with a single command.

claude mcp add tradememory -- uvx tradememory-protocol
4

Run with Docker (alternative)

For a containerized setup that includes the REST API and dashboard, use Docker Compose from the cloned repository.

git clone https://github.com/mnemox-ai/tradememory-protocol.git
cd tradememory-protocol
docker compose up -d
5

Record your first trade

Once connected, ask Claude to record a trade. The server will persist it with full context including market conditions, rationale, and confidence level.

6

Run a pre-trade risk check

Before entering a position, use the check_trade_legitimacy tool to run the five-factor risk gate. Claude will surface any detected behavioral biases or rule violations.

TradeMemory Protocol Examples

Client configuration

Claude Desktop config block for TradeMemory Protocol using uvx.

{
  "mcpServers": {
    "tradememory": {
      "command": "uvx",
      "args": ["tradememory-protocol"]
    }
  }
}

Prompts to try

Example prompts for recording trades, recalling memories, and running risk checks.

- "Record my AAPL long at $195 — earnings beat, institutional buying, high confidence"
- "What happened the last time I bought AAPL in similar conditions?"
- "Run a pre-trade legitimacy check before I enter this EUR/USD position"
- "Show me my behavioral biases from the last 30 days of trades"
- "Verify my audit trail hasn't been tampered with"

Troubleshooting TradeMemory Protocol

Server fails to start with 'module not found' errors

Ensure you installed into the same Python environment that uvx uses. Try running 'uvx tradememory-protocol' directly in a terminal to see the full error. If using pip install, confirm the environment is activated before starting Claude Desktop.

Trades recorded in one session are not visible in the next

The community edition uses SQLite stored in a local data directory. Confirm the server is launching from the same working directory each time. Check the server logs for the database file path being used.

MT5 sync features are not working

MT5 integration requires Pro/Enterprise credentials and additional configuration. Check the repository for the .env.example file to find the required MT5 API endpoint and credential keys, then add them to a .env file in the server directory.

Frequently Asked Questions about TradeMemory Protocol

What is TradeMemory Protocol?

TradeMemory Protocol is a Model Context Protocol (MCP) server that mcp server that provides ai trading agents with persistent, outcome-weighted memory to learn from historical performance and detect behavioral biases. it enables agents to automatically adjust strategies and optimize position sizing based on conte It connects AI assistants to external tools and data sources through a standardized interface.

How do I install TradeMemory Protocol?

Install via pip with: pip install tradememory-protocol. Then configure your AI client to connect to this MCP server.

Which AI clients work with TradeMemory Protocol?

TradeMemory Protocol works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.

Is TradeMemory Protocol free to use?

Yes, TradeMemory Protocol is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.

Browse More Finance & Fintech MCP Servers

Explore all finance & fintech servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.

Quick Config Preview

{ "mcpServers": { "tradememory-protocol": { "command": "pip", "args": ["install", "tradememory-protocol"] } } }

Add this to your claude_desktop_config.json or .cursor/mcp.json

Read the full setup guide →

Ready to use TradeMemory Protocol?

Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.

33,000+ ServersFree & Open SourceStep-by-Step Guides