tracebook-conformance 0.6.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (220) hide show
  1. tracebook_conformance-0.6.0/CHANGELOG.md +296 -0
  2. tracebook_conformance-0.6.0/CITATION.cff +24 -0
  3. tracebook_conformance-0.6.0/CODE_OF_CONDUCT.md +22 -0
  4. tracebook_conformance-0.6.0/CONTRIBUTING.md +115 -0
  5. tracebook_conformance-0.6.0/LICENSE +21 -0
  6. tracebook_conformance-0.6.0/MANIFEST.in +47 -0
  7. tracebook_conformance-0.6.0/PKG-INFO +427 -0
  8. tracebook_conformance-0.6.0/PROJECT_PLAN.md +180 -0
  9. tracebook_conformance-0.6.0/QUICKSTART.md +179 -0
  10. tracebook_conformance-0.6.0/README.md +381 -0
  11. tracebook_conformance-0.6.0/SECURITY.md +31 -0
  12. tracebook_conformance-0.6.0/SUPPORT.md +33 -0
  13. tracebook_conformance-0.6.0/docs/api-stability.md +58 -0
  14. tracebook_conformance-0.6.0/docs/architecture.md +206 -0
  15. tracebook_conformance-0.6.0/docs/assets/failure-proof.png +0 -0
  16. tracebook_conformance-0.6.0/docs/assets/failure-proof.svg +39 -0
  17. tracebook_conformance-0.6.0/docs/assets/social-preview.png +0 -0
  18. tracebook_conformance-0.6.0/docs/assets/social-preview.svg +31 -0
  19. tracebook_conformance-0.6.0/docs/case-studies/orderbook-rs-issue-88.md +205 -0
  20. tracebook_conformance-0.6.0/docs/ci.md +95 -0
  21. tracebook_conformance-0.6.0/docs/coinbase-l3.md +156 -0
  22. tracebook_conformance-0.6.0/docs/commands.md +332 -0
  23. tracebook_conformance-0.6.0/docs/conformance.md +531 -0
  24. tracebook_conformance-0.6.0/docs/corpora.md +241 -0
  25. tracebook_conformance-0.6.0/docs/event-replay.md +103 -0
  26. tracebook_conformance-0.6.0/docs/field-notes/001-failure-forensics.md +128 -0
  27. tracebook_conformance-0.6.0/docs/logo.png +0 -0
  28. tracebook_conformance-0.6.0/docs/performance.md +160 -0
  29. tracebook_conformance-0.6.0/docs/positioning.md +63 -0
  30. tracebook_conformance-0.6.0/docs/qualification-design-partners.md +189 -0
  31. tracebook_conformance-0.6.0/docs/release.md +167 -0
  32. tracebook_conformance-0.6.0/docs/releases/0.3.0.md +88 -0
  33. tracebook_conformance-0.6.0/docs/releases/0.4.0.md +84 -0
  34. tracebook_conformance-0.6.0/docs/releases/0.4.1.md +72 -0
  35. tracebook_conformance-0.6.0/docs/releases/0.5.0.md +59 -0
  36. tracebook_conformance-0.6.0/docs/releases/0.6.0.md +100 -0
  37. tracebook_conformance-0.6.0/docs/research-roadmap.md +138 -0
  38. tracebook_conformance-0.6.0/examples/advanced_profiling_check.py +298 -0
  39. tracebook_conformance-0.6.0/examples/conformance_adapter.py +17 -0
  40. tracebook_conformance-0.6.0/examples/data/coinbase_btcusd_full.jsonl +10 -0
  41. tracebook_conformance-0.6.0/examples/data/coinbase_btcusd_l3_snapshot.json +12 -0
  42. tracebook_conformance-0.6.0/examples/data/sample_events.jsonl +5 -0
  43. tracebook_conformance-0.6.0/examples/full_simulation_demo.py +355 -0
  44. tracebook_conformance-0.6.0/examples/github-actions/conformance.yml +48 -0
  45. tracebook_conformance-0.6.0/examples/magic_trace_integration_demo.py +298 -0
  46. tracebook_conformance-0.6.0/experiments/__init__.py +1 -0
  47. tracebook_conformance-0.6.0/experiments/guided_diversity.py +494 -0
  48. tracebook_conformance-0.6.0/experiments/results/guided-diversity-v1.json +902 -0
  49. tracebook_conformance-0.6.0/integrations/__init__.py +1 -0
  50. tracebook_conformance-0.6.0/integrations/flash_benchmark/README.md +102 -0
  51. tracebook_conformance-0.6.0/integrations/flash_benchmark/__init__.py +1 -0
  52. tracebook_conformance-0.6.0/integrations/flash_benchmark/artifacts/orderbook-rs-issue-88-divergence.json +27 -0
  53. tracebook_conformance-0.6.0/integrations/flash_benchmark/artifacts/orderbook-rs-issue-88-provenance.json +47 -0
  54. tracebook_conformance-0.6.0/integrations/flash_benchmark/bridge.py +244 -0
  55. tracebook_conformance-0.6.0/integrations/gocronx_matcher/Cargo.lock +932 -0
  56. tracebook_conformance-0.6.0/integrations/gocronx_matcher/Cargo.toml +23 -0
  57. tracebook_conformance-0.6.0/integrations/gocronx_matcher/README.md +77 -0
  58. tracebook_conformance-0.6.0/integrations/gocronx_matcher/rust-toolchain.toml +4 -0
  59. tracebook_conformance-0.6.0/integrations/gocronx_matcher/src/adapter.rs +687 -0
  60. tracebook_conformance-0.6.0/integrations/gocronx_matcher/src/lib.rs +3 -0
  61. tracebook_conformance-0.6.0/integrations/gocronx_matcher/src/main.rs +13 -0
  62. tracebook_conformance-0.6.0/integrations/gocronx_matcher/src/server.rs +20 -0
  63. tracebook_conformance-0.6.0/integrations/orderbook_rs/Cargo.lock +1261 -0
  64. tracebook_conformance-0.6.0/integrations/orderbook_rs/Cargo.toml +43 -0
  65. tracebook_conformance-0.6.0/integrations/orderbook_rs/README.md +303 -0
  66. tracebook_conformance-0.6.0/integrations/orderbook_rs/fifo-compatible.jsonl +13 -0
  67. tracebook_conformance-0.6.0/integrations/orderbook_rs/regressions/flash-issue-88-reduced.jsonl +4 -0
  68. tracebook_conformance-0.6.0/integrations/orderbook_rs/regressions/issue-88-failure.json +52 -0
  69. tracebook_conformance-0.6.0/integrations/orderbook_rs/regressions/issue-88-reduced.jsonl +4 -0
  70. tracebook_conformance-0.6.0/integrations/orderbook_rs/rust-toolchain.toml +4 -0
  71. tracebook_conformance-0.6.0/integrations/orderbook_rs/src/adapter.rs +1074 -0
  72. tracebook_conformance-0.6.0/integrations/orderbook_rs/src/bin/faulty_orderbook_adapter.rs +14 -0
  73. tracebook_conformance-0.6.0/integrations/orderbook_rs/src/bin/orderbook_rs_issue_88_adapter.rs +14 -0
  74. tracebook_conformance-0.6.0/integrations/orderbook_rs/src/lib.rs +3 -0
  75. tracebook_conformance-0.6.0/integrations/orderbook_rs/src/main.rs +49 -0
  76. tracebook_conformance-0.6.0/integrations/orderbook_rs/src/server.rs +22 -0
  77. tracebook_conformance-0.6.0/integrations/python_matching_engine/README.md +85 -0
  78. tracebook_conformance-0.6.0/integrations/python_matching_engine/__init__.py +1 -0
  79. tracebook_conformance-0.6.0/integrations/python_matching_engine/adapter.py +238 -0
  80. tracebook_conformance-0.6.0/integrations/python_matching_engine/fifo-compatible.jsonl +13 -0
  81. tracebook_conformance-0.6.0/integrations/rust_protocol/Cargo.lock +190 -0
  82. tracebook_conformance-0.6.0/integrations/rust_protocol/Cargo.toml +14 -0
  83. tracebook_conformance-0.6.0/integrations/rust_protocol/README.md +18 -0
  84. tracebook_conformance-0.6.0/integrations/rust_protocol/rust-toolchain.toml +4 -0
  85. tracebook_conformance-0.6.0/integrations/rust_protocol/src/lib.rs +276 -0
  86. tracebook_conformance-0.6.0/integrations/rust_protocol/src/server.rs +230 -0
  87. tracebook_conformance-0.6.0/packaging/lightweight-conformance.md +121 -0
  88. tracebook_conformance-0.6.0/packaging/tracebook-sim/LICENSE +21 -0
  89. tracebook_conformance-0.6.0/packaging/tracebook-sim/README.md +70 -0
  90. tracebook_conformance-0.6.0/packaging/tracebook-sim/pyproject.toml +84 -0
  91. tracebook_conformance-0.6.0/pyproject.toml +114 -0
  92. tracebook_conformance-0.6.0/setup.cfg +4 -0
  93. tracebook_conformance-0.6.0/src/tracebook/__init__.py +66 -0
  94. tracebook_conformance-0.6.0/src/tracebook/_version.py +3 -0
  95. tracebook_conformance-0.6.0/src/tracebook/benchmarks/__init__.py +1 -0
  96. tracebook_conformance-0.6.0/src/tracebook/benchmarks/runner.py +234 -0
  97. tracebook_conformance-0.6.0/src/tracebook/conformance/__init__.py +121 -0
  98. tracebook_conformance-0.6.0/src/tracebook/conformance/campaign.py +1155 -0
  99. tracebook_conformance-0.6.0/src/tracebook/conformance/classification.py +108 -0
  100. tracebook_conformance-0.6.0/src/tracebook/conformance/cli.py +440 -0
  101. tracebook_conformance-0.6.0/src/tracebook/conformance/compare.py +395 -0
  102. tracebook_conformance-0.6.0/src/tracebook/conformance/exit_codes.py +109 -0
  103. tracebook_conformance-0.6.0/src/tracebook/conformance/external.py +302 -0
  104. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/__init__.py +1 -0
  105. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/__init__.py +1 -0
  106. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/deep-cancellation.jsonl +16 -0
  107. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/fifo-lifecycle.jsonl +10 -0
  108. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/manifest.json +16 -0
  109. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/multi-symbol.jsonl +7 -0
  110. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/order-instructions.jsonl +6 -0
  111. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/pro-rata-allocation.jsonl +7 -0
  112. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/stp-cancel-incoming.jsonl +5 -0
  113. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/stp-cancel-resting.jsonl +5 -0
  114. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v1/tick-grid.jsonl +4 -0
  115. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/__init__.py +1 -0
  116. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/deep-cancellation.jsonl +16 -0
  117. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/fifo-lifecycle.jsonl +10 -0
  118. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/manifest.json +17 -0
  119. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/multi-symbol.jsonl +7 -0
  120. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/order-instructions.jsonl +6 -0
  121. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/pro-rata-allocation.jsonl +7 -0
  122. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/stp-cancel-incoming.jsonl +5 -0
  123. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/stp-cancel-resting-deep.jsonl +4 -0
  124. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/stp-cancel-resting.jsonl +5 -0
  125. tracebook_conformance-0.6.0/src/tracebook/conformance/fixtures/v2/tick-grid.jsonl +4 -0
  126. tracebook_conformance-0.6.0/src/tracebook/conformance/junit.py +192 -0
  127. tracebook_conformance-0.6.0/src/tracebook/conformance/minimize.py +170 -0
  128. tracebook_conformance-0.6.0/src/tracebook/conformance/model.py +527 -0
  129. tracebook_conformance-0.6.0/src/tracebook/conformance/protocol.py +139 -0
  130. tracebook_conformance-0.6.0/src/tracebook/conformance/qualification.py +272 -0
  131. tracebook_conformance-0.6.0/src/tracebook/conformance/reference.py +136 -0
  132. tracebook_conformance-0.6.0/src/tracebook/conformance/reproduce.py +128 -0
  133. tracebook_conformance-0.6.0/src/tracebook/conformance/semantic_coverage.py +156 -0
  134. tracebook_conformance-0.6.0/src/tracebook/conformance/suite.py +233 -0
  135. tracebook_conformance-0.6.0/src/tracebook/core/__init__.py +0 -0
  136. tracebook_conformance-0.6.0/src/tracebook/core/matching_engine.py +497 -0
  137. tracebook_conformance-0.6.0/src/tracebook/core/order.py +436 -0
  138. tracebook_conformance-0.6.0/src/tracebook/core/orderbook.py +1107 -0
  139. tracebook_conformance-0.6.0/src/tracebook/core/price_level.py +309 -0
  140. tracebook_conformance-0.6.0/src/tracebook/core/replay.py +191 -0
  141. tracebook_conformance-0.6.0/src/tracebook/corpus/__init__.py +29 -0
  142. tracebook_conformance-0.6.0/src/tracebook/corpus/cli.py +195 -0
  143. tracebook_conformance-0.6.0/src/tracebook/corpus/coinbase.py +1351 -0
  144. tracebook_conformance-0.6.0/src/tracebook/corpus/fixtures/__init__.py +1 -0
  145. tracebook_conformance-0.6.0/src/tracebook/corpus/fixtures/coinbase-btcusd-synthetic-v1/events.jsonl +8 -0
  146. tracebook_conformance-0.6.0/src/tracebook/corpus/fixtures/coinbase-btcusd-synthetic-v1/feed.jsonl +10 -0
  147. tracebook_conformance-0.6.0/src/tracebook/corpus/fixtures/coinbase-btcusd-synthetic-v1/golden.json +46 -0
  148. tracebook_conformance-0.6.0/src/tracebook/corpus/fixtures/coinbase-btcusd-synthetic-v1/manifest.json +73 -0
  149. tracebook_conformance-0.6.0/src/tracebook/corpus/fixtures/coinbase-btcusd-synthetic-v1/snapshot.json +20 -0
  150. tracebook_conformance-0.6.0/src/tracebook/events/__init__.py +39 -0
  151. tracebook_conformance-0.6.0/src/tracebook/events/cli.py +83 -0
  152. tracebook_conformance-0.6.0/src/tracebook/events/coinbase_cli.py +192 -0
  153. tracebook_conformance-0.6.0/src/tracebook/events/coinbase_l3.py +772 -0
  154. tracebook_conformance-0.6.0/src/tracebook/events/market_replay.py +608 -0
  155. tracebook_conformance-0.6.0/src/tracebook/profiling/__init__.py +0 -0
  156. tracebook_conformance-0.6.0/src/tracebook/profiling/magic_trace_wrapper.py +595 -0
  157. tracebook_conformance-0.6.0/src/tracebook/profiling/performance_monitor.py +615 -0
  158. tracebook_conformance-0.6.0/src/tracebook/profiling/trace_analyzer.py +534 -0
  159. tracebook_conformance-0.6.0/src/tracebook/profiling/trace_visualizer.py +475 -0
  160. tracebook_conformance-0.6.0/src/tracebook/py.typed +1 -0
  161. tracebook_conformance-0.6.0/src/tracebook/simulation/__init__.py +0 -0
  162. tracebook_conformance-0.6.0/src/tracebook/simulation/order_generator.py +960 -0
  163. tracebook_conformance-0.6.0/src/tracebook/simulation/simulation_engine.py +701 -0
  164. tracebook_conformance-0.6.0/src/tracebook/utils/__init__.py +0 -0
  165. tracebook_conformance-0.6.0/src/tracebook/visualization/__init__.py +0 -0
  166. tracebook_conformance-0.6.0/src/tracebook/visualization/dashboard.py +698 -0
  167. tracebook_conformance-0.6.0/src/tracebook/visualization/web/__init__.py +1 -0
  168. tracebook_conformance-0.6.0/src/tracebook/visualization/web/app.js +146 -0
  169. tracebook_conformance-0.6.0/src/tracebook/visualization/web/index.html +66 -0
  170. tracebook_conformance-0.6.0/src/tracebook/visualization/web/styles.css +312 -0
  171. tracebook_conformance-0.6.0/src/tracebook/visualization/web_server.py +258 -0
  172. tracebook_conformance-0.6.0/src/tracebook_conformance.egg-info/PKG-INFO +427 -0
  173. tracebook_conformance-0.6.0/src/tracebook_conformance.egg-info/SOURCES.txt +218 -0
  174. tracebook_conformance-0.6.0/src/tracebook_conformance.egg-info/dependency_links.txt +1 -0
  175. tracebook_conformance-0.6.0/src/tracebook_conformance.egg-info/entry_points.txt +2 -0
  176. tracebook_conformance-0.6.0/src/tracebook_conformance.egg-info/not-zip-safe +1 -0
  177. tracebook_conformance-0.6.0/src/tracebook_conformance.egg-info/requires.txt +17 -0
  178. tracebook_conformance-0.6.0/src/tracebook_conformance.egg-info/top_level.txt +1 -0
  179. tracebook_conformance-0.6.0/tests/__init__.py +0 -0
  180. tracebook_conformance-0.6.0/tests/benchmarks/__init__.py +0 -0
  181. tracebook_conformance-0.6.0/tests/benchmarks/microbench.py +126 -0
  182. tracebook_conformance-0.6.0/tests/conftest.py +10 -0
  183. tracebook_conformance-0.6.0/tests/fixtures/faulty_campaign_adapter.py +70 -0
  184. tracebook_conformance-0.6.0/tests/fixtures/faulty_conformance_adapter.py +57 -0
  185. tracebook_conformance-0.6.0/tests/test_artifact_schemas.py +696 -0
  186. tracebook_conformance-0.6.0/tests/test_audit_hardening.py +343 -0
  187. tracebook_conformance-0.6.0/tests/test_benchmark_runner_json_output.py +101 -0
  188. tracebook_conformance-0.6.0/tests/test_benchmark_scenarios.py +58 -0
  189. tracebook_conformance-0.6.0/tests/test_coinbase_corpus.py +424 -0
  190. tracebook_conformance-0.6.0/tests/test_coinbase_l3.py +410 -0
  191. tracebook_conformance-0.6.0/tests/test_concurrency_contracts.py +61 -0
  192. tracebook_conformance-0.6.0/tests/test_conformance.py +605 -0
  193. tracebook_conformance-0.6.0/tests/test_conformance_campaign.py +684 -0
  194. tracebook_conformance-0.6.0/tests/test_conformance_exit_codes.py +566 -0
  195. tracebook_conformance-0.6.0/tests/test_conformance_qualification.py +229 -0
  196. tracebook_conformance-0.6.0/tests/test_dashboard_demo_construction.py +270 -0
  197. tracebook_conformance-0.6.0/tests/test_distribution_split_verifier.py +336 -0
  198. tracebook_conformance-0.6.0/tests/test_external_integrations.py +226 -0
  199. tracebook_conformance-0.6.0/tests/test_flash_bridge.py +228 -0
  200. tracebook_conformance-0.6.0/tests/test_guided_diversity_experiment.py +112 -0
  201. tracebook_conformance-0.6.0/tests/test_invariants.py +253 -0
  202. tracebook_conformance-0.6.0/tests/test_lifecycle_hardening.py +88 -0
  203. tracebook_conformance-0.6.0/tests/test_market_event_replay.py +363 -0
  204. tracebook_conformance-0.6.0/tests/test_metrics_honesty.py +52 -0
  205. tracebook_conformance-0.6.0/tests/test_order_reduction.py +98 -0
  206. tracebook_conformance-0.6.0/tests/test_orderbook_edge_contracts.py +172 -0
  207. tracebook_conformance-0.6.0/tests/test_orderbook_semantics.py +367 -0
  208. tracebook_conformance-0.6.0/tests/test_public_api.py +18 -0
  209. tracebook_conformance-0.6.0/tests/test_release_metadata.py +311 -0
  210. tracebook_conformance-0.6.0/tests/test_replay.py +208 -0
  211. tracebook_conformance-0.6.0/tests/test_sdist_wheel_agreement.py +347 -0
  212. tracebook_conformance-0.6.0/tests/test_self_trade_prevention.py +175 -0
  213. tracebook_conformance-0.6.0/tests/test_simulation_benchmarks.py +273 -0
  214. tracebook_conformance-0.6.0/tests/test_simulation_event_metrics.py +86 -0
  215. tracebook_conformance-0.6.0/tests/test_tick_grid.py +171 -0
  216. tracebook_conformance-0.6.0/tests/test_v020_integrity.py +212 -0
  217. tracebook_conformance-0.6.0/tests/test_web_frontend.py +151 -0
  218. tracebook_conformance-0.6.0/tools/smoke_conformance_wheel.py +184 -0
  219. tracebook_conformance-0.6.0/tools/verify_distribution_split.py +929 -0
  220. tracebook_conformance-0.6.0/tools/verify_sdist_wheel_agreement.py +357 -0
@@ -0,0 +1,296 @@
1
+ # Changelog
2
+
3
+ All notable changes to `tracebook` will be documented here.
4
+
5
+ The project follows [Keep a Changelog](https://keepachangelog.com/) conventions.
6
+
7
+ ## Unreleased
8
+
9
+ ## 0.6.0 - 2026-07-27
10
+
11
+ - Fixed conformance CLI exit classification across single runs, suites,
12
+ minimization, campaigns, qualification, and reproduction. Semantic
13
+ disagreements remain exit `1`; malformed adapter output, timeouts, invalid
14
+ state hashes, snapshot failures, and shutdown failures now consistently exit
15
+ `2` as documented. Minimization and reproduction JUnit projections now also
16
+ fail instead of reporting green when their nested conformance run failed
17
+ operationally. A shutdown error no longer overwrites an earlier first
18
+ divergence; it is retained as auxiliary `close_error` evidence.
19
+ - Split the 0.6.0 install surface into non-overlapping distributions.
20
+ `tracebook-conformance` now owns the `tracebook` package, fixtures, typing
21
+ marker, and qualification command with no mandatory runtime dependencies.
22
+ The package-less `tracebook-sim` compatibility facade depends on that exact
23
+ version plus NumPy and psutil and retains the seven simulator/workbench
24
+ commands and their optional extras.
25
+ - Added dual-wheel ownership, metadata, resolver-driven clean-install,
26
+ uninstall, sdist-rebuild, and isolated qualification gates. The final
27
+ migration proof uses the SHA-256-pinned public 0.5.0 wheel, and reproducible
28
+ release wheels make partial-publication retries safe. A normal conformance
29
+ install now proves 3/3 fixed cases, 25/25 generated traces, 5,000 events, and
30
+ 10/10 capabilities without NumPy or psutil.
31
+ - Documented the required one-time migration from `tracebook-sim` 0.5.x:
32
+ uninstall the legacy distribution before installing either 0.6.0 package.
33
+ A direct in-place upgrade can otherwise let the old wheel's uninstall record
34
+ remove files newly owned by `tracebook-conformance`.
35
+ - Corrected public CI, security, suite-version, adapter-effort, API-stability,
36
+ and platform-support claims. JUnit is now described as an uploaded projection
37
+ unless a separate reporter consumes it, and qualification artifact
38
+ publication is no longer labeled operating-system independent.
39
+ - Recorded the 2/3 upstream native-regression retention pilot and its provenance
40
+ limit: the accepted patches validate demand for focused native regressions,
41
+ while a raw Flash divergence is still required to validate Tracebook's own
42
+ localization, minimization, and translation path.
43
+ - Reframed the adoption sequence around reviewable native evidence first,
44
+ optional out-of-tree qualification ownership, and independently retained
45
+ Tracebook-derived artifacts rather than stars, local adapters, or passing
46
+ repository-owned campaigns.
47
+
48
+ ## 0.5.0 - 2026-07-19
49
+
50
+ - Added a structured public engine-qualification intake that records time to
51
+ evidence, adapter size, failed attempts, protocol questions, profile-boundary
52
+ disagreements, artifacts, and upstream CI adoption. The project plan now
53
+ gates the next feature release on independently maintained engine use.
54
+ - Aligned contributor and release quality commands so experimental research is
55
+ formatted, linted, type-checked, and compiled, while maintained integration
56
+ code is included in the local security scan.
57
+ - Consolidated native Rust adapter framing, validation, canonical state hashing,
58
+ and process serving into one shared crate. Migrated package metadata,
59
+ dependencies, scripts, and package-data declarations to `pyproject.toml`,
60
+ removing duplicate Rust protocol copies and the legacy `setup.py` metadata
61
+ source.
62
+ - Moved qualification campaign validation ahead of all candidate work and
63
+ reject JUnit destinations inside campaign or qualification artifact trees,
64
+ preventing invalid requests and report-path collisions from causing external
65
+ side effects.
66
+ - Added qualification contract version 1 and `tracebook-conformance qualify`.
67
+ One atomic evidence bundle now combines only the immutable fixed cases inside
68
+ a declared profile, a deterministic generated campaign, complete semantic
69
+ coverage, JSON, JUnit, and any minimized failure.
70
+ - Reworked the project plan around external-adoption evidence and equal-budget
71
+ discovery experiments. Added a primary-source research roadmap covering
72
+ Flash, RESTler, TCP-Fuzz, NEZHA, AFLNet, FEST, PMA, and modern LOB simulators,
73
+ while explicitly deferring feedback-guided generation until it beats the
74
+ current generator on held-out defects.
75
+ - Added a commit-pinned `gocronx/matcher` Rust adapter. Its `fifo-limit-v1`
76
+ qualification passes 3/3 fixed cases, 25/25 generated traces, and 10/10
77
+ semantic capabilities; JSON/JUnit evidence is retained in scheduled CI while
78
+ two upstream contract questions remain explicitly pending.
79
+ - Published the frozen qualification-friction and held-out discovery study.
80
+ Semantic-transition-guided suffix mutation improved one injected defect but
81
+ regressed on the historical defect and a second injected defect, so no guided
82
+ generator mode, profile, CLI, or artifact-contract change was shipped.
83
+
84
+ - Added immutable `tracebook-conformance-v2` as the default bundled suite while
85
+ retaining v1 behind `sample --suite-version v1`. The new four-event case
86
+ pins FIFO `CANCEL_RESTING` as cancel-on-encounter and exposes
87
+ `orderbook-rs`'s valid cancel-all-at-touched-level policy as a documented
88
+ state difference.
89
+ - Documented the reference engine's binary64 half-even tick behavior and why
90
+ the Rust adapter's explicit cancel-and-new replacement path is load-bearing.
91
+ - Added `fifo-partial-fill-v1`, a hash-stable generated profile whose
92
+ four-event continuation probe verifies that a partially filled FIFO maker
93
+ retains priority over later same-price makers.
94
+ - Added a provenance-locked adapter for the historical `orderbook-rs` issue
95
+ #88 revision. A 200-event campaign reproduces Flash's real maker-priority
96
+ discrepancy at event 173, minimizes it to four events, and passes the same
97
+ committed regression on current `orderbook-rs` 0.12.0.
98
+ - Documented the Flash-to-Tracebook discovery and minimization handoff as a
99
+ bounded case study, with exact campaign, failure, JSON, and JUnit identities.
100
+ - Consumed Flash's merged schema-v1 canonical divergence at sequence 15738,
101
+ converted its 15,739-message workload prefix, and reduced the actual upstream
102
+ IDs, prices, quantities, and IOC instruction to a one-minimal four-event
103
+ regression in 193 runs. The affected engine reproduces queue-priority drift;
104
+ current `orderbook-rs` passes the same trace.
105
+ - Updated the maintained native adapter to `orderbook-rs` 0.12.0 and
106
+ `pricelevel` 0.9.1 after upstream end-to-end validation. Added a native
107
+ regression proving snapshots and matching expose the same queue-consumption
108
+ order after an in-place quantity increase; the versioned campaign profiles
109
+ remain unchanged.
110
+
111
+ ## 0.4.1 - 2026-07-14
112
+
113
+ - Updated the maintained native adapter to the upstream-reviewed
114
+ `orderbook-rs` 0.11.0 pin and configured deterministic, symbol-scoped native
115
+ trade-ID namespaces. Protocol v1 continues to compare portable source-order
116
+ fill semantics rather than candidate-private trade IDs.
117
+ - Recorded the upstream maintainer's confirmation of Tracebook's reduce,
118
+ replace, queue-order, and maker/taker mappings. Clarified that generated
119
+ profiles exclude in-place quantity increases; the review also prompted
120
+ upstream priority documentation, property tests, and a snapshot-restore fix.
121
+
122
+ ## 0.4.0 - 2026-07-13
123
+
124
+ - Began 0.4.0 development with deterministic, versioned differential campaigns.
125
+ Stateful generated traces are driven only by the reference engine, stop at
126
+ the first candidate divergence, and atomically emit the original failure,
127
+ exact semantic report, and automatically minimized reproducer.
128
+ - Added `fifo-limit-v1` and `fifo-full-v1` campaign profiles, a specified
129
+ cross-Python SplitMix64 generator, a stable campaign identity, and the
130
+ `tracebook-conformance campaign` command for local and CI use.
131
+ - Locked candidate identity across campaign and minimization subprocesses,
132
+ reserved the exact output path before candidate work, rejected changed output
133
+ reservations without overwriting them, failed closed where descriptor-safe
134
+ commits are unavailable, and fixed campaign IDs and trace hashes across the
135
+ Python CI matrix.
136
+ - Added a native Rust adapter for exactly pinned `orderbook-rs` 0.10.4. It
137
+ agrees on seven of eight standard cases, passes a 1,000-event generated FIFO
138
+ instruction campaign, documents the intentional pro-rata boundary, and runs
139
+ an injected Rust-side trade drift as a negative CI control. A scoped weekly
140
+ Dependabot feed proposes reviewed Cargo pin and lockfile updates.
141
+ - Added generator version 2's structured FIFO queue-priority probe. The public
142
+ seed-42 campaign detects an intentionally injected Rust maker-priority bug at
143
+ original event 173 and reduces the failing prefix to a one-minimal five-event
144
+ reproducer.
145
+ - Added deterministic failure-corpus bundles, stable failure classes,
146
+ `tracebook-conformance reproduce`, the option-friendly `--candidate-cmd`
147
+ form, and exact expected-versus-observed reproduction reports.
148
+ - Added reference-derived semantic capability coverage plus JSON and JUnit
149
+ outputs across run, suite, minimization, campaign, and reproduction paths.
150
+ - Included both correct and intentionally faulty native Rust adapter source in
151
+ the sdist, documented the `fifo-limit-v1` capability boundary, and updated the
152
+ copy-paste CI workflow to install `tracebook-sim==0.4.0` from public PyPI.
153
+
154
+ ## 0.3.0 - 2026-07-13
155
+
156
+ - Added the first maintained third-party engine integration: a commit-pinned
157
+ PythonMatchingEngine adapter, a 13-event native FIFO/LIMIT compatibility
158
+ trace, and a scheduled workflow that locks both the passing trace and the
159
+ honest `2/8` standard-suite contract profile.
160
+ - Added a real-engine README demo, a concise conformance architecture diagram,
161
+ a copy-paste GitHub Actions gate, and dedicated 0.3.0 release notes explaining
162
+ the move from Python simulator to matching-engine correctness lab.
163
+ - Repositioned Tracebook as a matching-engine conformance and reproducible
164
+ failure-analysis toolkit. Added a typed pluggable `EngineAdapter` API and an
165
+ incremental, language-neutral NDJSON protocol for testing external Rust,
166
+ C++, Java, Python, or other engines against the Tracebook reference path.
167
+ - Added `tracebook-conformance run` and `suite` with per-event applied/rejected
168
+ outcomes, stable rejection codes, source-ID trades, canonical queue-state
169
+ hashes, on-demand full snapshots, exact first-divergence paths, versioned JSON
170
+ artifacts, subprocess timeouts, and final-snapshot verification.
171
+ - Added deterministic delta-debugging through `tracebook-conformance minimize`,
172
+ which truncates after the first failure, emits a smaller JSONL reproducer,
173
+ and distinguishes a proven one-minimal result from run-budget exhaustion.
174
+ - Added a hash-locked, redistributable eight-case conformance suite covering
175
+ FIFO lifecycle and queue priority, IOC/FOK/market instructions, both
176
+ self-trade policies, pro-rata allocation, multiple symbols, tick-grid edge
177
+ cases, and deep-book cancellation pressure. Added property-based first-fault
178
+ tests and wheel-installed suite smoke coverage.
179
+ - Added `OrderBook.get_resting_orders()` for a detached, matching-priority view
180
+ of every resting order, including same-price queue order.
181
+ - Added `tracebook-corpus` for synchronized local Coinbase capture, offline
182
+ corpus preparation, pre-write field allowlisting and order-ID
183
+ pseudonymization, hash-locked manifests, exact golden replay verification,
184
+ machine-attributed import benchmarks, and environment-aware report
185
+ comparison. Live capture is an optional dependency and records that Coinbase
186
+ market-data redistribution rights are not granted by sanitization.
187
+ - Added a distributable synthetic BTC-USD corpus with canonical snapshot,
188
+ feed, normalized events, golden final state, and a stable corpus ID. System
189
+ smoke and wheel CI now reproduce it exactly.
190
+ - Added the dependency-free `tracebook-coinbase` offline adapter for Coinbase
191
+ Exchange REST L3 snapshots plus recorded `full` or compact `level3` feeds. It
192
+ validates dynamic compact schemas and per-product sequences, streams
193
+ normalized events, preserves observed exchange trades separately, ignores
194
+ future protocol message types without skipping sequence validation, and
195
+ rejects auction/crossed books rather than manufacturing queue state.
196
+ - Added priority-preserving `reduce_order()` and normalized `reduce` events for
197
+ partial maker fills and same-price size decreases. Core event logs and replay
198
+ summaries move to schema version 2; version 1 event logs remain readable.
199
+
200
+ ## 0.2.0 - 2026-07-10
201
+
202
+ Trust, installability, and real-data workflow release.
203
+
204
+ - Renamed the Python distribution to `tracebook-sim` because the `tracebook`
205
+ project name on PyPI belongs to an unrelated package. The import namespace and
206
+ existing `tracebook-*` console commands remain unchanged.
207
+ - Added `tracebook-replay` and the `tracebook.events` API for normalized CSV,
208
+ JSON, and JSONL order-event replay across multiple symbols. The strict mode
209
+ fails with event context; lenient mode records rejections and continues.
210
+ - Kept imported source order ids stable across replacement and later cancellation,
211
+ added configurable self-trade policy, and added optional trade output carrying
212
+ both source and engine ids.
213
+ - Made replacement an atomic cancel-and-new transaction with callbacks delivered
214
+ after unlocking, and preserved the original owner so replacement cannot bypass
215
+ either self-trade-prevention policy.
216
+ - Detached accepted orders, lookup results, trades, and callback payloads from
217
+ internal mutable state so callers cannot corrupt price levels or trade history.
218
+ - Tightened existing-order validation: ids, sides, order types, owners, timestamps,
219
+ prices, and quantities are type-checked without lossy integer coercion, and
220
+ malformed submissions return structured rejections.
221
+ - Added `clear` to deterministic event logs so recording and replay retain the
222
+ identical final book after a reset. Recorded submissions now retain an
223
+ externally supplied partial remaining quantity as well, and recording now
224
+ requires a pristine book with no earlier non-resting activity.
225
+ - Made pro-rata FOK preflight mirror level-wide `CANCEL_INCOMING` execution.
226
+ - Made fallback profiling collect configured matching functions through a real
227
+ Python profiling hook and emit completed calls and raw events.
228
+ - Made live frontend state atomic across depth, quote, trades, and statistics;
229
+ corrected chronological trade-direction coloring.
230
+ - Made the optional dashboard command keep `--help` and `--version` usable from
231
+ a core install and report the exact dashboard-extra install command otherwise.
232
+ - Separated achieved new-order rate from total event rate, made simulation metric
233
+ collection and batch ingestion configuration effective, and hardened cleanup
234
+ for failed or interrupted simulation and web sessions. Registered simulation
235
+ completion callbacks now receive the result artifact instead of being inert.
236
+ - Added PEP 561 `py.typed` metadata, Python 3.12/3.13 CI, a 75% coverage gate,
237
+ wheel-installed CLI smoke tests, package metadata checks, and a PyPI Trusted
238
+ Publishing release workflow.
239
+ - Added a dependency-free live order-book web frontend (`tracebook-web`): a
240
+ static HTML/CSS/JS page served by a stdlib HTTP server, backed by a background
241
+ simulation, showing a live depth ladder, top-of-book quote, engine metrics,
242
+ and a trade tape. It is loopback-only by default and ships in wheel/sdist.
243
+
244
+ ## 0.1.1 - 2026-07-02
245
+
246
+ Patch release from an adversarial QA pass: eight confirmed bugs fixed, each with a regression test.
247
+
248
+ - Required an empty book for `start_recording()` (QA found silent replay divergence): the event log captures only operations from the recording point on, so recording a book with pre-existing resting liquidity would replay to a different result (or crash on a later cancel of a pre-existing order). `start_recording()` now raises if any orders are resting.
249
+ - Stopped firing user callbacks while a lock is held (a deadlock vector found in QA): `replace_order` now submits the replacement with the book lock released, and `PerformanceMonitor.record_order_processing` fires alert callbacks after releasing the monitor lock. `replace_order` is now documented as cancel-then-new (its callbacks are lock-free like every other submission).
250
+ - Bounded the matching engine's trade history (found leaking in QA): `trades` is now a capped deque (retaining the recent tail for `get_recent_trades`) instead of an unbounded list, so a long-running book no longer grows memory per fill; `total_trades` remains the cumulative count.
251
+ - Hardened `MagicTraceSession.stop()` (found in QA): it now checks `poll()` before signalling, tolerates a self-exited child (magic-trace runs with a duration cap), always reaps the process, and marks the session inactive in a `finally` — previously a self-exited child raised `ProcessLookupError`, wedging the session and leaving a zombie.
252
+ - Fixed two tick-snapping matching bugs found in QA: an incoming limit whose price was within half a tick of a resting order could rest beside it and lock the book (the match decision used the raw price while resting prices were snapped), and a positive sub-half-tick price could snap to `0.0` and rest/execute for free. Incoming prices are now snapped onto the tick grid before validation and matching, and a price that snaps to a non-positive tick is rejected. The property-based invariants now fuzz off-grid prices.
253
+
254
+ ## 0.1.0 - 2026-07-02
255
+
256
+ First tagged alpha release. Consolidates the full alpha development history.
257
+
258
+ - Enabled `check_untyped_defs` in the mypy baseline (still `mypy src/tracebook` clean) and fixed the untyped-body issues it surfaced (nullable thread handles and an optional trace-file guard).
259
+ - Published a local benchmark baseline covering every scenario, including the newer ones, in `docs/performance.md`.
260
+ - Added benchmark scenarios: `deep_book` (deep resting liquidity), `high_cancellation` (heavier cancel/replace mix), `pro_rata_cancellation` (pro-rata with lifecycle events), and `multi_symbol` (independent books per symbol). `BenchmarkScenario` gained a `symbols` field threaded through to the simulation.
261
+ - Added artifact-level schema tests that lock the structure of the public JSON outputs (benchmark report, simulation results, and the replay `EventLog`), round-tripped through `json` the way the CLIs write them, so a refactor cannot silently change the output contract.
262
+ - Extended the mypy type-check baseline to the whole `src/tracebook` package and widened the CI gate to `mypy src/tracebook`. Fixed a real type-contract gap (the `OrderGenerator` ABC now declares the `order_factory`/`price_model` attributes its subclasses set and the stream assigns), made `SimulationConfig.symbols` a non-optional field with a default factory, and annotated the profiling/dashboard/simulation collections and implicit-`Optional` parameters.
263
+ - Established a mypy type-check baseline on the `core` package and enforce it in CI (initially `mypy src/tracebook/core`, clean). Added the annotations to get there, guarded `infer_price_decimals` against non-int `Decimal` exponents, and restored `mypy` as a dev dependency.
264
+ - Added a trusted fast path for orders built by the book's own factory: since the factory already validates side/type/price/quantity/owner and uses the book symbol with a fresh id, the `add_*`/`submit_*` methods skip the redundant book-level re-validation, symbol re-normalization, factory-id reconciliation, and a resting-state index lookup. Cut `add_deep` ~26% and `match` ~19%. The public `add_order`/`submit_order` (which accept externally built orders) still fully validate.
265
+ - Dropped `numba` as a dependency and removed the standalone `algorithms/{fifo,pro_rata}.py` analysis helpers, which were never wired into the live matching path. With `Order`/`Trade`/`PriceLevel` all plain Python, nothing on the order-book path used Numba; the package now imports and runs with Numba absent (verified with the import blocked).
266
+ - Made `Order` and `Trade` plain `__slots__` classes instead of Numba `jitclass` types. Profiling the per-order path showed the jitclass was about half the cost (`inspect`-based argument binding on every construction plus field-access boxing, all paid because the matching loop is pure Python); this roughly tripled `add_deep` and `match` throughput. Numba is no longer used on the order-book path.
267
+ - Made the FIFO match loop copy-free: it now iterates by repeatedly taking the O(1) price-level head instead of copying the entire level per aggressive order, so matching against a deep level is flat (O(1) per match) rather than O(level size). Verified by the `match` microbenchmark (now flat in level size) and a deep-sweep FIFO-order test.
268
+ - Replaced the price-level index's O(n) Python linear-scan insert and `list.remove` with `bisect` (per-side key), removing the Python-loop cost from level insert/removal. A local comparison against `sortedcontainers.SortedList` (command, machine, and Python cited in `docs/performance.md`) found `bisect` + list faster for realistic level counts, so no sorted-container dependency was added.
269
+ - Made in-level order removal O(1) by keying each price level's orders with an insertion-ordered dict (preserving FIFO order), replacing the previous O(n) linear scan. Moving `PriceLevel` off the Numba `jitclass` also removed per-access boundary cost from the pure-Python matching loop, substantially speeding up matching. Added a deterministic operation microbenchmark (`tests/benchmarks/microbench.py`) and before/after numbers in `docs/performance.md`.
270
+ - Added self-trade prevention: orders carry an optional `owner` id, and `OrderBook(self_trade_policy=...)` supports `CANCEL_RESTING` and `CANCEL_INCOMING` (default `NONE`). Both policies keep the book uncrossed, FOK fillability mirrors each policy (own liquidity excluded, and `CANCEL_INCOMING` stops at the first same-owner order so a FOK never partially executes), and the policy plus owners are captured in the replay log. Exported `SelfTradePolicy` and `NO_OWNER`.
271
+ - Made replay fail fast on a malformed or incompatible log: a hard-rejected submission (via a new `OrderResult.accepted` flag) or a cancel that finds no order now raises instead of diverging silently; soft outcomes such as an unfillable FOK still replay faithfully.
272
+ - Computed rolling throughput with an O(1) running window total instead of re-summing the deque on every order.
273
+ - Made `infer_price_decimals` use the tick's exact decimal representation so fine or scientific-notation tick sizes no longer collapse canonical prices to whole numbers.
274
+ - Added deterministic record/replay: `OrderBook.start_recording()`/`stop_recording()` capture a serializable `EventLog`, and `replay()` reconstructs the identical trade sequence and final book state (also across a JSON round-trip). Exported `EventLog` and `replay` from the package root.
275
+ - Reported throughput as a rolling one-second window rate instead of a lifetime cumulative average, so the dashboard shows an instantaneous rate.
276
+ - Removed the synchronous psutil sweep from the order-processing hot path; alerts and summaries now read the background-sampled resource snapshot.
277
+ - Attributed a replacement that crosses the book to matching latency rather than lifecycle-event latency, so replace-heavy scenarios no longer hide matching cost.
278
+ - Made `replace_order` atomic: an invalid replacement is rejected before the original is cancelled, and a replacement that fails to submit after cancellation restores the original resting order, so a replace never destroys liquidity.
279
+ - Bounded the order-id replay guard so long-running books no longer leak memory (most-recent-N window, configurable via `_seen_id_cap`).
280
+ - Keyed price levels by integer ticks (configurable `tick_size`, default `0.01`); prices now snap to a canonical grid, removing the float-identity hazard of dict-keying on raw prices.
281
+ - Consolidated execution pricing to a single rule (matches fill at the resting/maker price) and removed the unused JIT `match_orders_fifo` helper and the divergent timestamp-based `calculate_match_price`.
282
+ - Added property-based matching invariants (quantity conservation, no crossed book, level consistency) and tick-grid tests; added `hypothesis` as a dev dependency.
283
+ - Moved package code under the `tracebook` namespace.
284
+ - Added structured order submission results and richer order book lifecycle APIs.
285
+ - Added event-based simulation with new, cancel, and replace events.
286
+ - Added reproducible benchmark runner and local performance baseline docs.
287
+ - Added dashboard demo simulation support.
288
+ - Added GitHub Actions CI, packaging metadata, and open-source project templates.
289
+ - Reworked the README and docs into an artifact-first professional repo front door.
290
+ - Added release guidance, architecture docs, command docs, and richer package metadata.
291
+ - Added a source distribution manifest for docs, examples, tests, and project metadata.
292
+ - Hardened symbol, enum, numeric, duplicate-order-id, dashboard host, and magic-trace artifact validation.
293
+ - Made simulation lifecycle replacement IDs thread-safe and documented analyzer output as not yet collected.
294
+ - Refreshed local benchmark sample numbers from the current benchmark runner.
295
+ - Removed the unused mypy dev dependency/config until typed-package support has a real passing baseline.
296
+ - Added compile and dependency consistency checks to CI and clarified dependency grouping.
@@ -0,0 +1,24 @@
1
+ cff-version: 1.2.0
2
+ message: "If you use Tracebook in research or engineering work, please cite this software."
3
+ type: software
4
+ title: "Tracebook: Matching-Engine Conformance Testing and Reproducible Failure Analysis"
5
+ abstract: >-
6
+ Tracebook runs deterministic order-lifecycle traces through an inspectable
7
+ reference engine and an external matching engine, compares semantic outcomes,
8
+ localizes the first divergence, and reduces failures to reproducible CI
9
+ regressions.
10
+ authors:
11
+ - name: "Taz33m"
12
+ email: "tazeemmahashin@gmail.com"
13
+ version: "0.6.0"
14
+ date-released: 2026-07-27
15
+ license: MIT
16
+ repository-code: "https://github.com/Taz33m/tracebook"
17
+ url: "https://pypi.org/project/tracebook-conformance/0.6.0/"
18
+ keywords:
19
+ - matching engine
20
+ - conformance testing
21
+ - differential testing
22
+ - delta debugging
23
+ - market microstructure
24
+ - limit order book
@@ -0,0 +1,22 @@
1
+ # Code Of Conduct
2
+
3
+ This project should be a place where people can do careful technical work without needless friction.
4
+
5
+ ## Expected Behavior
6
+
7
+ - Be respectful and specific.
8
+ - Assume good intent, but accept correction when impact differs from intent.
9
+ - Critique code and ideas, not people.
10
+ - Keep disagreements focused on evidence, tradeoffs, and project goals.
11
+ - Make space for new contributors to ask basic questions.
12
+
13
+ ## Unacceptable Behavior
14
+
15
+ - Harassment, threats, insults, or discriminatory language.
16
+ - Publishing private information without consent.
17
+ - Repeatedly derailing issues or pull requests.
18
+ - Bad-faith demands for unpaid support.
19
+
20
+ ## Enforcement
21
+
22
+ Maintainers may edit, hide, or remove comments; close issues; reject pull requests; or block users when behavior harms the project. If you need to report conduct privately, contact the maintainer through the GitHub profile for `Taz33m`.
@@ -0,0 +1,115 @@
1
+ # Contributing
2
+
3
+ Thanks for helping make `tracebook` better. This matching-engine conformance,
4
+ qualification, and failure-forensics toolkit is early alpha, so the best
5
+ contributions are focused, tested, and honest about behavior.
6
+
7
+ ## Development Setup
8
+
9
+ ```bash
10
+ python -m venv venv
11
+ source venv/bin/activate
12
+ python -m pip install -e ".[dev]"
13
+ python -m pip install -e "./packaging/tracebook-sim[dashboard]"
14
+ ```
15
+
16
+ ## Local Checks
17
+
18
+ Run these before opening a pull request:
19
+
20
+ ```bash
21
+ python -m black --check src tests examples integrations experiments tools install_deps.py test_system.py
22
+ python -m flake8 src tests examples integrations experiments tools install_deps.py test_system.py
23
+ python -m mypy src/tracebook experiments tools
24
+ python -m bandit -q -r src integrations tools
25
+ python -m compileall -q src tests examples integrations experiments tools install_deps.py test_system.py
26
+ python -m pytest --cov=tracebook --cov-report=term-missing --cov-fail-under=75
27
+ python test_system.py
28
+ tracebook-benchmark --scenario smoke --duration 1 --throughput 50 --seed 1337 --warmup-seconds 0.01 --output benchmark_results/local-smoke.json
29
+ tracebook-dashboard --demo-simulation --help
30
+ tracebook-replay examples/data/sample_events.jsonl --output /tmp/tracebook-replay.json
31
+ tracebook-coinbase examples/data/coinbase_btcusd_l3_snapshot.json examples/data/coinbase_btcusd_full.jsonl --tick-size 0.01 --output /tmp/tracebook-coinbase.json
32
+ tracebook-corpus verify src/tracebook/corpus/fixtures/coinbase-btcusd-synthetic-v1
33
+ tracebook-conformance suite src/tracebook/conformance/fixtures/v2 --candidate python examples/conformance_adapter.py
34
+ ```
35
+
36
+ For packaging changes, also run:
37
+
38
+ ```bash
39
+ python -m build --sdist --wheel --outdir dist/conformance .
40
+ python -m build --sdist --wheel --outdir dist/simulator packaging/tracebook-sim
41
+ python -m twine check dist/conformance/* dist/simulator/*
42
+ python tools/verify_distribution_split.py \
43
+ --expected-version 0.6.0 \
44
+ --conformance-wheel dist/conformance/*.whl \
45
+ --sim-wheel dist/simulator/*.whl \
46
+ --resolver-runtime-checks
47
+ python tools/verify_sdist_wheel_agreement.py \
48
+ --conformance-wheel dist/conformance/*.whl \
49
+ --conformance-sdist dist/conformance/*.tar.gz \
50
+ --sim-wheel dist/simulator/*.whl \
51
+ --sim-sdist dist/simulator/*.tar.gz \
52
+ --expected-version 0.6.0
53
+ python tools/smoke_conformance_wheel.py dist/conformance/*.whl
54
+ ```
55
+
56
+ Normalized feed adapters should emit `tracebook.MarketEvent` values and keep
57
+ venue-specific parsing, sequence checks, and assumptions outside the core replay
58
+ engine. Include a small fixture and strict rejection tests with each adapter.
59
+ Fixtures must be synthetic or explicitly redistributable, and adapter semantics
60
+ must cite the venue's primary documentation.
61
+
62
+ Do not commit a live market-data corpus unless the repository has explicit
63
+ redistribution permission. Pseudonymized captures are still market data. Corpus
64
+ format changes must update schema tests, regenerate the synthetic fixture, and
65
+ document an intentional corpus-ID change.
66
+
67
+ The command reference in `docs/commands.md` is the source of truth for reviewer-facing smoke paths.
68
+
69
+ Candidate adapters must keep stdout reserved for protocol NDJSON, report source
70
+ order IDs rather than private engine IDs, preserve queue order in snapshots, and
71
+ include timeout/error tests. Protocol changes require an artifact schema test,
72
+ cross-process coverage, a changelog entry, and an explicit versioning decision.
73
+ New standard-suite cases must be synthetic, document the semantic edge they
74
+ cover, and update the manifest hash intentionally.
75
+
76
+ The small Python process example wraps Tracebook's own reference adapter and is
77
+ only a framing smoke test. A real candidate integration must document its
78
+ engine-specific lifecycle, numeric, trade-ID, and snapshot translations,
79
+ including measured adapter size and time to first evidence. Do not describe the
80
+ workflow's build and command substitutions as the full integration effort.
81
+
82
+ Maintained third-party integrations belong under `integrations/`. Pin the exact
83
+ upstream revision, link its license and primary repository, keep its dependencies
84
+ optional, include one native compatibility trace, and run the real upstream code
85
+ in a dedicated workflow. Document unsupported semantics as divergences; do not
86
+ retrofit them in the adapter merely to produce a green suite.
87
+
88
+ ## Pull Requests
89
+
90
+ - Keep changes scoped to one clear theme.
91
+ - Add or update tests for user-visible behavior.
92
+ - Keep performance claims tied to a reproducible benchmark command and machine context.
93
+ - Prefer public APIs under `tracebook.*`; do not reintroduce old `src/core` style imports.
94
+ - If a change affects matching semantics, include a small example in the PR description.
95
+ - If a change fixes a conformance failure, include the minimized trace or add it
96
+ as a regression case.
97
+
98
+ ## Commit Identity
99
+
100
+ GitHub contributor attribution depends on the commit author email being verified on your GitHub account. Check before committing:
101
+
102
+ ```bash
103
+ git config user.name
104
+ git config user.email
105
+ ```
106
+
107
+ ## Reporting Bugs
108
+
109
+ Please include:
110
+
111
+ - Python version and OS
112
+ - install command used
113
+ - minimal code or CLI command that reproduces the issue
114
+ - expected vs actual behavior
115
+ - relevant benchmark JSON when reporting performance regressions
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Tazeem Mahashin
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,47 @@
1
+ include README.md
2
+ include LICENSE
3
+ include CHANGELOG.md
4
+ include CITATION.cff
5
+ include CODE_OF_CONDUCT.md
6
+ include CONTRIBUTING.md
7
+ include PROJECT_PLAN.md
8
+ include QUICKSTART.md
9
+ include SECURITY.md
10
+ include SUPPORT.md
11
+
12
+ recursive-include docs *.md *.png *.svg
13
+ exclude docs/openwiki.md
14
+ exclude docs/graphify.md
15
+ exclude AGENTS.md
16
+ exclude CLAUDE.md
17
+ prune openwiki
18
+ prune graphify-out
19
+ prune .local-tools
20
+ recursive-include examples *.py *.json *.jsonl *.yml
21
+ recursive-include experiments *.py *.json
22
+ recursive-include packaging *.md
23
+ include packaging/tracebook-sim/pyproject.toml
24
+ include packaging/tracebook-sim/LICENSE
25
+ recursive-include tools *.py
26
+ recursive-include integrations *.py *.md *.json *.jsonl
27
+ recursive-include integrations/orderbook_rs/src *.rs
28
+ include integrations/orderbook_rs/Cargo.toml
29
+ include integrations/orderbook_rs/Cargo.lock
30
+ include integrations/orderbook_rs/rust-toolchain.toml
31
+ prune integrations/orderbook_rs/target
32
+ recursive-include integrations/gocronx_matcher/src *.rs
33
+ include integrations/gocronx_matcher/Cargo.toml
34
+ include integrations/gocronx_matcher/Cargo.lock
35
+ include integrations/gocronx_matcher/rust-toolchain.toml
36
+ prune integrations/gocronx_matcher/target
37
+ recursive-include integrations/rust_protocol/src *.rs
38
+ include integrations/rust_protocol/Cargo.toml
39
+ include integrations/rust_protocol/Cargo.lock
40
+ include integrations/rust_protocol/rust-toolchain.toml
41
+ include integrations/rust_protocol/README.md
42
+ prune integrations/rust_protocol/target
43
+ recursive-include tests *.py
44
+ recursive-include src/tracebook/visualization/web *.html *.css *.js
45
+ recursive-include src/tracebook/corpus/fixtures *.json *.jsonl
46
+ recursive-include src/tracebook/conformance/fixtures *.json *.jsonl
47
+ include src/tracebook/py.typed