Expand description
af-backtest — deterministic historical replay for product adapters.
This crate owns the reusable mechanics only: ordered historical ingress, state transitions, decision traces, value curves, metrics, and bounded report projection. Domain event types, accounting, execution semantics, data providers, and concrete strategies stay in product/extension crates.
Structs§
- Backtest
Config - Replay limits.
- Backtest
Definition - Tenant-owned deterministic replay definition.
- Backtest
Projection - A transport/chat-safe projection of a potentially large full report.
- Backtest
Report - Full replay output.
- Backtest
Run - Durable replay record; computation resumes from these snapshots, never a mutable definition.
- Backtest
Summary - Aggregate metrics for a replay.
- Projection
Policy - Caps for projecting a report to chat or API consumers.
- Replay
Step - Captured decision trace for one event.
- Value
Point - Value after one event.
Enums§
- Backtest
Error - Failure while validating input or replaying.
- Backtest
RunStatus - Durable replay lifecycle.
- Backtest
Store Error - Failure owned by the durable replay store.
Traits§
- Backtest
Model - Product-supplied deterministic replay behavior.
- Backtest
Store - Durable persistence port for definitions, snapshots, runs and bounded reports.
Functions§
- run_
backtest - Execute a deterministic replay. Events with the same timestamp are allowed and preserve input order; decreasing timestamps fail closed.
- run_
backtest_ with_ control - Execute a deterministic replay while observing cancellation and deadline between input events.