jflow-core
Shared types, configuration, and application state for the JANUS trading engine.
Published to crates.io as
jflow-core(thejanus-corename is owned by an unrelated project). The library is imported asjflow_core.
This is the foundational crate the rest of the JANUS workspace builds on. It deliberately depends on no other workspace crate, so it can be reused standalone.
What's here
Config— unified TOML + environment configuration with a Redis overlay.JanusState— shared application state (signal/market-data buses, service lifecycle, runtime log-level control, regime/threat snapshots, and a pluggable affinity recorder).- Signals —
Signal,SignalBus,SignalType. - Market data —
MarketDataEventand friends (TradeEvent,KlineEvent,OrderBookEvent, …) plus theMarketDataBus. - Position guidance —
PositionEvent,PositionClose,compute_guidance,PositionTracker(stateful trailing/give-back + sticky-exit), andPositionOutcomefor closed-trade feedback. - Optimized params —
OptimizedParams/ParamManagerfor hot-reloadable, per-asset strategy parameters. - Supervisor, metrics, session metrics, and shared
Error/Result.
Features
redis(default) — enables the Redis-backed config overlay and param-update subscription. Disable with--no-default-featuresfor a build with no Redis dependency.
Usage
[]
= "0.1"
use ;
# async
License
MIT