~/shahin-kiassat
← all posts

#trading

2 posts

9 min

Designing a deterministic kernel

Event-driven systems rot into callback soup where no two runs behave alike. Here's the cure I used in a trading engine: one queue, one pure reducer, one journal, one effect executor — and the discipline that makes two replays byte-identical.

4 min

A trading engine as a pure function

Most backtesters are a second implementation of the strategy — so they prove nothing about the code that actually trades. Build the engine as a pure reducer and the backtest, the live path, and the debugger become the same thing.