Struxis is evolving into a high-performance quantitative trading system.
It provides a full pipeline:
- market data ingestion (
SBar/CBar) - structure analysis (
Swing/Trend/KeyZone) - supply-demand scoring (
SD, 3-layer 9-factor model) - analysis snapshot output for strategy-layer consumption
- Rust toolchain (edition 2024 compatible)
- Cargo
Run tests:
cargo test -qRun checks:
cargo checkCheck full workspace:
cargo check --workspaceCheck a single package:
cargo check -p struxisRun an app:
cargo run -p liveRun apps with runtime mode switch (ctp | binance):
STRUXIS_MODE=ctp cargo run -p live
STRUXIS_MODE=binance cargo run -p sim
STRUXIS_MODE=binance cargo run -p researchRun with multi-symbol subscription (binance mode):
STRUXIS_MODE=binance STRUXIS_SYMBOLS=I2601,ETHUSDT cargo run -p live
STRUXIS_MODE=binance STRUXIS_SYMBOLS=I2601,ETHUSDT cargo run -p sim
STRUXIS_MODE=binance STRUXIS_SYMBOLS=I2601,ETHUSDT cargo run -p researchTune market feed queue and overload policy:
STRUXIS_MARKET_CHANNEL_CAPACITY=8192 \
STRUXIS_MARKET_INGRESS_CAPACITY=16384 \
STRUXIS_MARKET_OVERLOAD=drop_oldest \
STRUXIS_MODE=binance cargo run -p liveSTRUXIS_MARKET_OVERLOAD supports: drop_oldest (default), drop_newest.
struxis/src/constant.rs,struxis/src/events.rs,struxis/src/logging.rs,struxis/src/utils.rs: foundational modulesstruxis/src/bar.rs,struxis/src/tick.rs,struxis/src/receiver.rs,struxis/src/symbol.rs,struxis/src/indicator.rs: market data and symbol/indicator modulesstruxis/src/mtc.rs,struxis/src/swing.rs,struxis/src/trend.rs,struxis/src/keyzone.rs,struxis/src/keyzone_builder.rs,struxis/src/keyzone_factory.rs,struxis/src/sd.rs,struxis/src/engine.rs: analysis modulesstrategy/src/*: decision and strategy modules (consumestruxisoutputs)
Module layout convention:
- Prefer flat source layout under
struxis/src. - Do not add a
market/directory back unless there is a clear and reused sub-boundary. - Do not add an
analysis/directory back unless there is a clear and reused sub-boundary.
Single timeframe config example:
config/sd.default.yaml
Profile config (symbol + timeframe overlays):
config/sd.profile.yaml
Supported overlay precedence:
defaulttimeframe(e.g.5m)symbol(e.g.I2601)symbol_timeframewildcard (e.g.*.5m,I2601.*)symbol_timeframeexact (e.g.I2601.5m)
struxisonly providesinfra + market + analysiscapabilities.strategyownsDecisionEngineand trade decision orchestration.runtime/appscompose market feeds, analysis outputs, and strategy decisions.
- Project-wide rule: prioritize professional trader visual semantics over threshold/parameter tuning.
- Prefer structural relations, state transitions, and sequence constraints; use thresholds only as documented exceptions.
- This principle applies to all modules, not only
struxis.
docs/rust-migration.mddocs/CONTRIBUTING-struxis.mddocs/trading-system-thinking.mddocs/project-understanding.mddocs/naming.mddocs/rust-coding-standard.mddocs/workspace-projects.mddocs/workspace-layout.mddocs/market-readiness-v1.md