{
  "schema_version": "1.0",
  "topic_id": "D08-F07-A18",
  "title": "Market Entropy",
  "purpose": "machine-readable publication-contract verification",
  "data_class": "synthetic teaching input",
  "selected_formula": "H=-sum_k p_k log(p_k); normalize by log(K) after discretizing returns with fixed, point-in-time bins",
  "canonical_question": "How dispersed are recent return states across a declared symbol alphabet?",
  "input_contract": "ordered OHLC observations, explicit lookbacks and thresholds, and pivots confirmed without future leakage",
  "scenario_assertions": [
    {
      "name": "canonical",
      "expected_state": "calculated",
      "assertion": "valid and sufficiently warm synthetic input reaches calculation"
    },
    {
      "name": "boundary",
      "expected_state": "waiting",
      "assertion": "one missing observation or unresolved equality is not coerced to zero"
    },
    {
      "name": "failure",
      "expected_state": "invalid",
      "assertion": "non-finite, misordered, future-dated, or basis-mixed input is withheld"
    }
  ],
  "timing_rule": "A state at t may use only observations available through t; confirmed swings retain their confirmation timestamp and are never relabeled as known at the pivot bar.",
  "expected_non_claims": [
    "not historical market data",
    "not a forecast",
    "not a trading instruction",
    "not evidence of profitability"
  ],
  "implementation_status": "Python canonical runtime and audited Node/TypeScript adapter released with topic-owned fixtures and tests"
}
