TradeLab-MCP
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| MT5_DATA | No | Path to MetaTrader 5 data directory (optional, defaults to standard location) | |
| MT5_INSTALL | Yes | Path to MetaTrader 5 installation directory (e.g., C:\Program Files\MetaTrader 5) | |
| TRADE_LAB_ROOT | Yes | Root directory for TradeLab research runs | |
| MT5_TERMINAL_HASH | No | Hash identifier for the MetaTrader 5 terminal (optional) |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": false
} |
| prompts | {
"listChanged": false
} |
| resources | {
"subscribe": false,
"listChanged": false
} |
| experimental | {} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| healthA | Verify MT5 install, MetaEditor, terminal, data dir, Experts, Tester, and build. |
| list_terminalsA | Enumerate MetaTrader terminal data folders under %APPDATA%\MetaQuotes\Terminal. |
| compileB | Compile a .mq5/.mq4 source via MetaEditor and publish it to Experts/TradeLab MCP. |
| run_backtestC | Run one official MT5 Strategy Tester backtest and store it under a unique run_id. |
| run_batchB | Run the same strategy sequentially on each symbol. Each asset gets its own run_id. |
| get_runA | Load manifest, config, metrics, files, and errors for an existing run_id. |
| get_tradesB | Return normalized trades for a run_id. |
| compare_runsA | Diff stored metrics of two or more runs. Never looks up the latest HTML report. |
| walk_forwardC | Walk-forward as a sequence of official tester runs (IS/OOS windows). |
| smoke_testC | Compile, deploy, run a short official tester pass, and scan the journal. |
| validate_tester_iniC | Sanity-check a tester.ini against official MT5 formats (including Leverage=1:100). |
| ea_capabilitiesA | Show TradeLab EA capabilities, defaults, and the mandatory pre-generation workflow. |
| ea_registryB | Query the compact EA catalog without loading every .mq5 source into the AI context. |
| refresh_ea_registryA | Rebuild experts/registry.json and REGISTRY.md after an EA source changes. |
| validate_ea_standardC | Check that an EA uses the guarded TradeLab stop, sizing, metadata, and bar helpers. |
| plan_ea_creationC | Mandatory registry lookup and decision record before generating or modifying an EA. |
| select_terminalC | Switch the active terminal data folder for this session. |
| kill_terminalA | Force-kill terminal processes for the configured edition. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
| livelog_resource | |
| journal_resource | |
| tester_log_resource |
TDQS
Scored across 18 tools
Each tool targets a distinct resource and action: terminal management, compilation, single/batch/walk-forward backtests, result retrieval/comparison, and EA registry operations. The run-related tools are differentiated by scope and description, so an agent is unlikely to confuse them.
Most tools follow a clear verb_noun pattern such as list_terminals, run_backtest, get_trades, and refresh_ea_registry. A few exceptions like health, compile, ea_capabilities, and walk_forward are readable but break the otherwise consistent convention.
At 18 tools, this is slightly above the typical 3-15 tool sweet spot, but the count is justified by the distinct environment, backtest, results, and EA-registry concerns. Each tool has a clear role and none feel redundant.
Core workflows are well covered: environment health, compilation, backtests, walk-forward, smoke tests, and result inspection/comparison. However, there is no run listing/deletion tool and no direct EA generation/modification tool, which leaves notable gaps in lifecycle management.