Description
LSBotPro (Lean Price Action) is an automated trading robot built for cTrader/cAlgo that scans price action, qualifies trades using layered “gates,” sizes positions using structured risk rules, manages open trades with profit-protection logic, and continuously records outcomes to improve selectivity over time.
1) Core Strategy: Price-Action Pattern Trading
LSBotPro’s entries are driven by candlestick structure and controlled execution logic. It detects and scores:
- Pin Bars (wick/body ratio + close position quality)
- Engulfing patterns (body dominance + direction)
- Inside Bars (strict containment + optional breakout confirmation)
It supports two entry styles:
- Next-Open entry (enter after a confirmed closed candle pattern)
- Breakout mode (enter only when price closes beyond the Inside-Bar “mother bar” range, with optional intrabar logic)
2) Market Filters (Trade Qualification Gates)
Before any order is placed, LSBotPro applies multiple filters designed to avoid low-quality conditions:
- ATR volatility bounds (min/max ATR in pips) to avoid dead or chaotic markets
- Spread gate (blocks trades when spread exceeds the defined threshold)
- EMA confluence filter (optional): checks trend side, EMA slope, and distance from EMA with a configurable minimum score
- Multi-timeframe bias (optional): confirms direction using H4/D1 EMA or candle bias
- Session & rollover controls: avoids weekends, Friday close, Sunday open, and optionally the rollover window
- Setup freshness + one-trade-per-setup lock to reduce duplicates and overtrading
3) Risk Management & Exposure Control
LSBotPro’s risk engine is designed to control drawdowns and limit account exposure:
- Risk-percent sizing (position size derived from risk %, SL distance, pip value)
- Risk budget caps: maximum open risk % (sum of conceptual risks across positions)
- Daily loss limit + daily trade cap (hard block on new entries when exceeded)
- Concurrency limits: max positions per symbol/account, plus direction caps
- Volatility regime scaling: adjusts risk and RR dynamically using ATR / ATR-SMA50 (low-vol vs high-vol regimes)
- Equity-curve filter: tracks recent R-multiples and blocks trading if performance deteriorates beyond a configured threshold
4) Stop-Loss Safety Model (Current Build)
This build has a very specific safety posture:
- Broker stop-loss is disabled (the bot intentionally does not send SL to the broker and clears existing SLs).
- TP is still used (take-profit is placed in pips).
- If TP-Only Mode = true:
- The bot will not auto-close losing trades under any condition.
- Only manual actions can close losers; auto-flatten closes winners only.
- If TP-Only Mode = false:
- The bot can optionally manage exits locally with virtual stop / trailing concepts (still no broker SL), plus break-even/trailing/chandelier logic when enabled.
This design makes the bot heavily reliant on discipline, monitoring, and correct configuration, especially when TP-only is active.
5) Trade Management (Profit Protection & Exit Intelligence)
For open positions (when not in TP-only and while in profit), LSBotPro runs structured exit logic:
- Profit milestone alerts (sound notifications):
- first closed bar into profit
- first time price reaches ≥50% progress toward TP
- Progress-drop / giveback logic (“profit maximiser”): arms after strong progress toward TP, then exits on stall + meaningful giveback + weakness confirmation
- Cortex exit engine (“neurons”) that votes on exit using:
- Progress/giveback behaviour
- Structure breaks
- Momentum shifts
- Trend slope invalidation (veto-capable)
- Recall-based exit pressure
6) Memory / Recall (Learning From Similar Trades)
LSBotPro includes a trade memory + recall gate:
- Stores trade “snapshots” (features at entry + outcomes) and retrieves similar historical trades
- Uses historical similarity to compute:
- win-rate confidence
- expected edge (pips)
- similar trade count
- Can block trades if recall confidence/edge is weak (after warm-up), or fail-open during early learning.
- Memory can run file-based (JSONL) if file access is allowed; otherwise it runs in RAM.
7) Telemetry & Observability (UI/Monitoring Ready)
LSBotPro can publish telemetry to an external observer service (local or remote), including:
- Bot status + last decision (ALLOW/REJECT) and reasons
- Current positions snapshots (pips, money, risk pips, side, symbol)
- Trade lifecycle events (open/close)
- Learning summary metrics (e.g., best pattern, worst context, total learned trades)
8) Manual Operator Controls
The bot supports operator intervention without recompiling:
- Pause/resume entries (manual or auto-pause)
- Close newest, close one, or close all
- Hotkeys (when running with a chart)
- Shadow logs for diagnostic reasons (why trades were blocked/rejected)
Summary
Before placing trades, LSBotPro applies multiple market filters including ATR volatility bounds, spread limits, EMA confluence, multi-timeframe bias, session controls, and setup freshness to ensure trade quality. Its risk management system controls drawdowns and exposure through risk-percent position sizing, risk budget caps, daily loss limits, concurrency limits, volatility regime scaling, and an equity-curve filter.
The bot disables broker stop-loss orders, relying instead on take-profit targets and optional virtual stop-loss and trailing exit strategies. Trade management includes profit milestone alerts, progress-drop logic, and a multi-factor exit engine. LSBotPro features a trade memory system that learns from historical trades to assess win-rate confidence and expected edge, potentially blocking low-confidence trades.
Telemetry capabilities allow external monitoring of bot status, trade events, and learning metrics. Manual controls enable pausing entries, closing positions, and diagnostic logging without recompilation. The bot is tagged for Forex and EURUSD markets.
