DeltaTrace: Deterministic Replayable Latency & Compliance Tracing for Live Market-Execution Pipelines
Go to file
agent-deee027bb02fa06e 3d3103132b build(agent): r2d2#deee02 iteration 2026-04-30 09:52:54 +02:00
deltatrace build(agent): r2d2#deee02 iteration 2026-04-25 21:32:32 +02:00
tests build(agent): r2d2#deee02 iteration 2026-04-30 09:52:54 +02:00
.gitignore build(agent): c3po#b883b4 iteration 2026-04-25 21:03:06 +02:00
AGENTS.md build(agent): c3po#b883b4 iteration 2026-04-25 21:03:06 +02:00
README.md build(agent): c3po#b883b4 iteration 2026-04-25 21:03:06 +02:00
pyproject.toml build(agent): c3po#b883b4 iteration 2026-04-25 21:03:06 +02:00
requirements.txt feat: implement DeltaTrace core - event graph, replay engine, audit log, adapters 2026-04-24 20:44:00 +02:00
test.sh build(agent): c3po#b883b4 iteration 2026-04-25 21:03:06 +02:00

README.md

DeltaTrace

Deterministic replay, latency accounting, and compliance tracing for live market-execution pipelines.

DeltaTrace provides a small, production-oriented Python package for capturing market events as a causal graph, replaying them deterministically, and writing a tamper-evident audit trail for governance review.

What It Does

  • Models market-data ticks, signals, plan deltas, orders, fills, and risk checks as graph nodes.
  • Links nodes with causal edges and latency measurements.
  • Replays captured traces in deterministic order for incident analysis.
  • Signs audit entries with Ed25519 and chains them with SHA-256 hashes.
  • Includes two starter adapters:
    • FIX feed adapter for FIX-like market data messages.
    • Sandbox exchange adapter for order/fill simulation.

Package Layout

  • deltatrace.event_graph: event and DAG primitives.
  • deltatrace.replay_engine: deterministic replay runner.
  • deltatrace.audit_log: signed audit log with hash chaining.
  • deltatrace.adapters: FIX and sandbox adapters.
  • deltatrace.demo: end-to-end example pipeline.

Install

pip install -e .

Run the Demo

python -m deltatrace.demo

Test And Build

./test.sh

This script installs dependencies, verifies python -m build, runs the test suite, and executes the demo.

Publishing Notes

  • Project metadata lives in pyproject.toml.
  • The package README is wired as the long description for distribution builds.
  • The build backend is setuptools and supports standard wheel/sdist creation.

License

MIT