quant-system
A Rust workspace for deterministic historical replay and real-time market-data infrastructure.
quant-system is intended for Rust developers and quantitative researchers who want to import historical market data, replay normalized trading actions, embed trading-domain and backtest libraries, or operate a local CTrader quote service. The workspace is under active 0.2.x development.
It is not a complete automated trading platform. It does not currently execute live broker orders, provide restart-safe live strategy orchestration, or implement general cryptocurrency economics.
Choose a workflow
| Goal | Start here | Readiness |
|---|---|---|
| Run a deterministic signal backtest | Five-minute quick start | Available; a synthetic fixture is included |
| Import and manage historical data | qs-data-preprocess guide |
Available for supported tick and bar exports |
| Embed the pure trade engine | quant-system-core |
Library-only |
| Build an in-process strategy simulation | qs-backtest |
Library-only |
| Parse Telegram message exports | Signal ingestion guide | Provider-specific adapter |
| Operate a CTrader quote service | Market-data guide | Requires CTrader FIX credentials |
Five-minute backtest
Prerequisites
- Rust 1.88 or newer;
- Linux shared memory (
/dev/shm) for the providedshm://example; - two terminals after the data import finishes.
Import the repository-owned EURUSD fixture:
Start the backtest server:
In another terminal, submit the matching signal stream:
The fixture opens a EURUSD long position and closes it one minute later. See the getting-started guide for expected results, endpoint alternatives, and troubleshooting.
Architecture at a glance
historical tick/bar export -> qs-data-preprocess -> partitioned Parquet
|
external producer or qs-signal-parser -> RawSignal -----+
v
Backtest Service
|
v
deterministic replay
|
v
result or artifact
CTrader FIX -> Market Data Service -> snapshots, subscriptions, and alerts
RawSignal is the compatibility boundary between signal producers and replay. See Architecture for crate ownership and service boundaries.
Current boundaries
- Bars are replayed as close-only, zero-spread quotes, so exact intrabar execution is not simulated.
- Source-neutral event and stateless normalization contracts are available as library APIs; durable ingestion state, hosted generic runners, and non-Telegram online adapters are not implemented.
- Live order execution, restart-safe strategy state, and broker order adapters are not included.
- Registered cryptocurrency symbols are metadata-only for replay; spot, derivative, fee, funding, margin, and liquidation models are not implemented.
- Internal service TCP endpoints have no built-in authentication or TLS and are restricted to loopback by default.
- Historical import accepts the documented MetaTrader-style tab-delimited tick and bar formats, not arbitrary CSV layouts.
Documentation
- Documentation index
- Getting started
- Backtesting
- Signal ingestion
- Market data
- Architecture
- Roadmap
- RawSignal reference
Development
License
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT License (LICENSE-MIT or http://opensource.org/licenses/MIT)