Archon is a demo-first Forex scalping research bot. The first milestone is deliberately small: deterministic signals, hard risk limits, reproducible paper trading, and complete decision logs. Live trading and self-modifying production code are out of scope.
- Demo or offline paper trading only.
- No martingale, averaging down, or live self-modification.
- Every proposed order passes through a central risk gate.
- Strategy candidates must be tested on unseen data and include spread/slippage costs.
- Broker credentials must never be committed to this repository.
python -m venv .venv
.venv\Scripts\Activate.ps1
python -m pip install -e ".[dev]"
pytest
python -m archon --helpThe domain and simulation layers do not import MetaTrader 5. A future adapter will translate between MT5 data/orders and these stable interfaces, which also leaves room for a frontend.
The feature branch includes:
- validated OHLC bar, signal, and order models;
- a moving-average crossover baseline (a testable benchmark, not a profit claim);
- position sizing plus per-trade, spread, daily-loss, drawdown, and exposure limits;
- conservative paper fills with slippage and commission;
- a read-only MT5 completed-candle adapter; and
- a CSV paper-trading CLI that emits JSON events suitable for a future frontend.
CSV input requires symbol,timestamp,open,high,low,close columns and accepts an optional
spread column. Timestamps must include a UTC offset, for example 2026-08-09T12:00:00Z.
python -m archon backtest .\data\bars.csv --config .\config.example.tomlAdd --train-fraction 0.7 to produce separate chronological train and out-of-sample test
reports. Results are written as JSON metrics/equity data and CSV trade ledgers under
artifacts/backtest by default. Never tune a strategy using the test-period result.
Until broker history is available, exercise the pipeline with deterministic synthetic data:
python -m archon generate-sample .\data\synthetic.csv
python -m archon backtest .\data\synthetic.csv --train-fraction 0.7Synthetic data validates software behavior only. Its performance results are not trading evidence.
MT5 order execution is intentionally not implemented yet. Connecting the demo account comes after the broker, terminal installation, symbol names, and contract sizing have been confirmed.