System Overview¶
Full architecture of the ICT Edge Fund platform -- from TradingView Desktop through to the live dashboard and public domains.
Platform Architecture¶
graph TB
subgraph TradingView["TradingView Desktop"]
TV_APP["Electron App<br/>localhost:9222"]
TV_PINE["Pine Script Indicators<br/>Bias AI | Session Hunt AI | OB AI | SMT AI"]
TV_APP --- TV_PINE
end
subgraph ICTMCP["ictedge-mcp"]
FOCUS["focus-window tool"]
LAUNCH["Launch scripts<br/>launch_tv_debug.bat/.vbs/.sh"]
FOCUS --- LAUNCH
end
subgraph MCP["tradingview-mcp"]
MCP_CDP["CDP Client<br/>chrome-remote-interface"]
MCP_TOOLS["78 Tools<br/>12 categories, Zod schemas"]
MCP_CDP --> MCP_TOOLS
end
subgraph Strategy["tradingview-strategy"]
READERS["Readers<br/>bias | session | ob | smt | price"]
INTERP["Interpreters<br/>5 typed signals"]
ENGINE["Engine<br/>confluence + no-trade filters"]
FLAGS["StrategyFlags JSON"]
READERS --> INTERP --> ENGINE --> FLAGS
end
subgraph Dashboard["Dashboard"]
SERVER["server.js<br/>localhost:8000"]
API["/api/data<br/>/api/settings<br/>/api/screenshot"]
WEB["Web UI<br/>signals + charts + settings"]
SERVER --- API --- WEB
end
subgraph Docker["Docker Stack"]
NGINX["nginx proxy<br/>ports 80/443"]
DOCS["MkDocs container"]
CERT["certbot SSL"]
NGINX --- CERT
end
subgraph Domains["Public Access"]
D1["ictedgefund.com<br/>dashboard"]
D2["docs.ictedgefund.com<br/>wiki"]
end
ICTMCP -. "launches with CDP" .-> TV_APP
TV_APP -- "CDP / WebSocket" --> MCP_CDP
MCP_TOOLS -- "direct import" --> READERS
FLAGS --> SERVER
NGINX --> SERVER
NGINX --> DOCS
DOCS --> D2
SERVER --> D1
Layer Responsibilities¶
ictedge-mcp (Launcher)¶
Window focus utility that ensures TradingView Desktop is running with CDP enabled. Provides the focus-window tool and platform-specific launch scripts that start TradingView with --remote-debugging-port=9222. Without this, no CDP connection is possible.
TradingView Desktop (Runtime)¶
The charting environment. Runs as an Electron app with remote debugging on port 9222. Four Pine Script indicators execute inside the charting engine and render output as graphics objects: labels, lines, boxes, and tables. The platform treats TradingView as a read-only data source.
tradingview-mcp (Interface)¶
A standalone MCP server with 78 tools and exactly 2 runtime dependencies (chrome-remote-interface, @modelcontextprotocol/sdk). Connects to TradingView via CDP and exposes every chart interaction as a typed, Zod-validated tool. The strategy layer imports core modules directly for lower latency.
tradingview-strategy (Brain)¶
Three internal layers with strict dependency direction:
| Layer | Responsibility | Depends On |
|---|---|---|
| Readers | Call MCP tools with study_filter, normalize raw responses |
tradingview-mcp |
| Interpreters | Apply indicator contract rules, produce typed signals | Readers |
| Engine | Score confluence, apply no-trade filters, build flags | Interpreters |
Dependency flows downward only. The engine never calls MCP tools directly.
Dashboard (UI)¶
dashboard/server.js inside tradingview-strategy serves the live web interface at localhost:8000. Exposes /api/data (current StrategyFlags), /api/settings (indicator configuration), and /api/screenshot (chart capture). The web UI auto-refreshes to show real-time signal state.
Docker Stack (Infrastructure)¶
nginx reverse proxy handles routing and SSL termination:
| Domain | Backend |
|---|---|
ictedgefund.com |
Dashboard at localhost:8000 |
docs.ictedgefund.com |
MkDocs container |
certbot manages Let's Encrypt certificates automatically.
StrategyFlags (Output)¶
A single JSON object capturing the complete market assessment: directional bias, session context, order block proximity, SMT divergence, confluence score, and trade readiness. Consumed by the dashboard and designed to feed a future execution engine.
Design Principles¶
Documentation-First¶
Every indicator contract, color mapping, and signal schema is documented before code is written. Documentation serves as specification.
Modular by Indicator¶
Each indicator has its own reader and interpreter. Adding a fifth indicator means adding two files and a schema update. No existing code changes required.
No Indicator Modifications¶
The strategy layer adapts to indicator output as-is. Pine Script sources are never modified to accommodate the platform.
Pine Graphics Only¶
All data flows through labels, lines, boxes, and tables. No plot scraping, no overlay text parsing, no pixel reading.
Deterministic Output¶
Given identical chart state, the engine always produces identical StrategyFlags. No randomness, no hidden state.
Read-Only Platform¶
The platform observes TradingView -- it never modifies chart state, indicator settings, or drawing objects during normal operation.