# IMD Picks Structured Forecast Report Contract v1.0.0 **Named artifact:** `imd.forecast-report/1.0.0`. **Proposed policies** for later integration; **synthetic** examples. IMD Swarm alone researches, models, calibrates, predicts and writes text. Existing allowances/free access/current price only: no independent AI, paid API or added customer fee. ## Typed contract Types/rules are normative. All properties required; reject extras, omissions, duplicate keys, nonfinite numbers and dangling references. D requires a text-ID reason for null. ID matches `^[a-z][a-z0-9._:-]{0,95}$`; TID references text. Int=safe integer; Nat>=0; P=integer probability millionths, 0–1000000. Decimal=decimal string, <=6 fractional digits, no leading zeros/trailing fractional zeros or negative zero; odds>1. SHA=64 lowercase hex characters. UTC=valid `YYYY-MM-DDTHH:mm:ssZ`, seconds 00–59; no guessed/local times ([RFC 3339 §5.6](https://www.rfc-editor.org/rfc/rfc3339.html#section-5.6)). Lang=canonical BCP 47 tag ([RFC 5646](https://www.rfc-editor.org/rfc/rfc5646.html)). Both checked 2026-11-29. Source URIs: credential-free HTTPS or immutable internal imd: artifacts. ```ts type ID=string;type TID=ID;type UTC=string;type Lang=string; type SHA=string;type Decimal=string; type Int=number;type Nat=Int;type P=Int; type D={value:T;why:null}|{value:null;why:TID}; type Confidence="unavailable"|"low"|"medium"|"high"; type Sport="football"|"basketball"|"tennis"|"cricket" | "american_football"|"baseball"|"hockey"|"mma"|"boxing" | "motorsports"|"esports"|"rugby"|"volleyball"|"golf" | "handball"|"horse_racing"|"table_tennis"|"badminton" | "darts"|"snooker"; type Topic="momentum"|"form"|"h2h"|"opponent_strength" | "recruits_chemistry"|"lineups_entries"|"absences_rotation" | "motivation"|"fatigue_travel"|"coaching_tactics" | "weather_venue"|"advanced_statistics"|"risk"|"other"; type NoBetReason="missing_price"|"stale_price"|"access_restricted" | "market_mismatch"|"unsupported_settlement"|"no_positive_value" | "uncalibrated"|"wide_uncertainty"|"insufficient_evidence" | "material_contradiction"|"unknown_dependence"|"event_unavailable" | "budget_exhausted"|"joint_pricing_not_supported"; type Panel={ state:"available"|"partial"|"unavailable"|"not_applicable"; why:TID|null;ids:ID[]; }; type Panels={ alternatives:Panel;bookmaker_quotes:Panel;momentum:Panel; h2h:Panel;lineups_entries:Panel;risks:Panel; complete_reasoning:Panel;sources:Panel;other_findings:Panel; }; type Interval={ low_ppm:P;high_ppm:P;level_ppm:P; method_ref:string; }; type Settlement={ win:P;half_win:P;push:P;half_loss:P;loss:P;void:P; }; type Estimate={ state:"calibrated"|"uncalibrated"|"unavailable"; raw_ppm:D

;calibrated_ppm:D

; settlement:D;interval:D; calibration_id:D;confidence:Confidence; why:TID;finding_ids:ID[]; }; type Selection={id:ID;label:TID;subject_ids:ID[];outcome_code:string;estimate:Estimate}; type Market={ id:ID;event_id:ID; kind:"winner"|"moneyline"|"spread"|"total"|"prop"|"outright"; period:string;metric:string;unit:string;line:D; subject_ids:ID[]; rules_id:ID;rules_text:TID;rules_source_ids:ID[]; comparison:"partition"|"overlapping"; selections:Selection[]; }; type Quote={ id:ID;market_id:ID;selection_ids:ID[];normalized_key:string|null; bookmakers:("stake"|"bet99"|"bet365"|"other")[]; other_name:D;jurisdiction:D;conditions:D; state:"available"|"missing"|"stale"|"suspended"|"blocked"|"mismatch"; decimal:D;quoted_utc:D;checked_utc:UTC; source_ids:ID[];why:TID|null; }; type Value={ state:"estimated_value"|"not_value"|"unknown"; selection_id:D;quote_id:D; ev_ppm:D;ev_interval_ppm:D<{low:Int;high:Int}>; why:TID; }; type Decision={ primary_market_id:D;primary_selection_id:D; most_probable:D; estimated_value:Value; verdict:"consider"|"no_bet";no_bet_reasons:NoBetReason[]; short_reason:TID; }; type Event={ id:ID;sport:Sport;label:TID;competition:D; start_utc:D; status:"scheduled"|"postponed"|"cancelled"|"unknown"; participants:{id:ID;label:TID;role:"home"|"away"|"entrant"}[]; aliases:{provider:string;provider_event_id:string}[]; decision:Decision;panels:Panels; }; type Source={ id:ID;kind:"official"|"bookmaker"|"secondary"|"model_artifact"|"synthetic"; publisher:string;uri:D;accessed_utc:UTC; published_utc:D;excerpt:string;locator:string; snapshot_sha256:D; access:"free"|"free_login"|"unavailable";limitation:TID|null; }; type Finding={ id:ID;event_ids:ID[];selection_ids:ID[];topic:Topic;metrics:{key:string;value:D;unit:D}[];claim:TID; status:"verified"|"projected"|"disputed"|"unknown"; stance:"supports"|"opposes"|"neutral"|"unknown"; source_ids:ID[];effective_utc:D;gap:TID|null; use:"used"|"unused";unused_reason:TID|null;contradicts:ID[]; }; type Reasoning={ id:ID;event_ids:ID[];selection_ids:ID[];conclusion:TID; finding_ids:ID[];assumptions:TID[]; effect:"increase"|"decrease"|"neutral"|"unresolved"; }; type Calibration={ id:ID;model_ref:string;calibrator_ref:string;stratum:string; train_end_utc:UTC;validation_start_utc:UTC;validation_end_utc:UTC; n:Nat;brier_ppm:P;logloss_micro:Nat;calibration_error_ppm:P; interval_coverage_ppm:P;drift:"pass"|"fail"|"unknown"; source_ids:ID[]; }; type Dependence={ a:ID;b:ID;state:"modeled"|"independence_justified"|"unknown"; finding_ids:ID[];why:TID; }; type Joint={ selection_ids:ID[];definition:"all_positive_profit"; state:"single"|"modeled"|"bounds_only"|"unavailable"; method:"identity"|"conditional_chain"|"joint_simulation"|"bounds"|"none"; p_ppm:D

;bounds:D<{low_ppm:P;high_ppm:P}>; interval:D;dependence:Dependence[]; conditionals:{selection_id:ID;given_ids:ID[];p_ppm:P}[]; model_source_ids:ID[];simulation_n:D;seed:D; verdict:"no_bet";value_status:"unknown";why:TID; }; type TextNode={ id:TID;template:string; bindings:{token:string;pointer:string; format:"percent1"|"decimal"|"integer"|"utc"|"text_ref"}[]; }; type Core={ schema_version:"imd.forecast-report/1.0.0"; mode:"production"|"synthetic";id:ID;revision:Nat; supersedes:ID|null;engine:"IMD Swarm"; cutoff_utc:UTC;generated_utc:UTC; budget:{allowance_ref:string;state:"complete"|"exhausted";why:TID|null}; events:Event[];markets:Market[];quotes:Quote[]; sources:Source[];findings:Finding[];reasoning:Reasoning[]; calibrations:Calibration[];joint:Joint;texts:TextNode[]; }; type Report={ core:Core;core_sha256:SHA; language:{ requested:Lang;rendered:Lang|null; state:"complete"|"partial"|"unavailable";why:TID|null; nodes:{id:TID;template:string}[];missing_text_ids:TID[]; }; }; ``` ## Cross-field rules **1. IDs/counts.** Registry event IDs identify one contest/race/round, independent of language/book. Preserve aliases/ID on rescheduling; changed contest gets new ID. Never merge by names alone. Market identity is `(event,kind,period,metric,unit,line,sorted subjects,rules_id)`; selection identity adds outcome_code/subject_ids, a registered predicate under those rules (win means the subject wins). Rules text covers applicable overtime/retirement/void/etc. terms. Changed rules/predicate need new IDs; rules_id is an immutable registry key. Events 1–14, mixed sports allowed; markets 0–N/event; selections 2–N/market; participants/aliases 0–N (zero participants forces unavailable/no-bet). Other collections 0–N; metric keys unique per finding; selection subjects belong to the event. Numeric findings use metrics and text bindings. Entity IDs globally unique; reference lists unique/resolving/well scoped. Findings/reasoning have 1–14 event IDs; selections belong to those events. Known most_probable has 1–N IDs in primary market. Joint has one primary selection/event, 1–14 when complete; missing primaries require unavailable, known subset 0–13 and explanation. Exactly one decision/all nine panels per event, one joint/report. **2. Cutoff.** Known starts>cutoff; unknown/postponed/cancelled event forces no-bet. Generated>=cutoff; source access, known publication, effective, quote/check times<=cutoff. Unknown publication needs reason/as-of capture. Preserve projected versus confirmed entries. Later information/results/corrections require new report; historical tests use captured as-of features, never current pages as past evidence. Synthetic mode cannot publish in production. **3. Probability.** Raw is pre-calibration P(positive net profit). Calibrated requires all five data known; settlement sums exactly to 1000000 and calibrated=win+half_win. Half states mean half win/loss, half refund; push/void refund. Unsupported variable payouts force no-bet. Partition: no half states, identical push/void masses, sum(win)+common push+void=1000000. Overlapping markets cannot be primary partitions. Uncalibrated: raw known, other four data null; unavailable: all five null. Both confidence unavailable/no-bet; raw only in labeled details, never substitute odds/0%/50%. Interval contains point, level=900000, with versioned method and held-out coverage; it concerns probability-estimation uncertainty, not scores/certainty. **4. Calibration/confidence.** Calibration n>0, sources nonempty; train_end1000000. Verified errors train later versions only; no hindsight/data leakage. Unavailable=no validated calibrated estimate/interval. Otherwise low unless medium conditions all hold: relevant n>=200, drift pass, error<=50000, 90% coverage>=850000, width<=200000, primary evidence for material inputs/rules, no unresolved material contradiction. High additionally: n>=1000, error<=30000, coverage>=880000, width<=100000, material entries resolved or modeled/validated. Missing material inputs, projected material entries or unknown/failing drift cap at low. Explain tier in why; confidence is reliability, separate from outcome probability. **5. Conclusions.** Most-probable lists all exact maximal calibrated probabilities in a complete primary partition; primary is lexicographically first tie. Any missing member makes primary selection/most_probable null; absent supported market makes primary market null too. Value may concern another selection. For decimal odds d, exact per-unit net `EV=(p_win+p_half_win/2)*(d-1)-p_loss-p_half_loss/2`. Use rational arithmetic, round final EV to signed millionths half away from zero. EV interval contains EV and derives from validated settlement-scenario draws, not merely a win-probability band. estimated_value requires lower EV>0, confidence>=medium, eligible quote and no material gap. Eligible tested candidate failing the test is not_value; unavailable/ineligible data gives unknown, null EV/interval, reason. IDs may remain known. consider requires known primary, eligible value and no blocking reason; otherwise no_bet with >=1 reason. consider has none. Material budget exhaustion forces no-bet. Missing price need not hide a forecast. **6. Quotes.** normalized_key=compact JSON `[event_id,kind,period,metric,unit,line.value,sorted_subject_ids,rules_id,selection_id]`. Compare identical keys and compatible known jurisdiction/conditions only; preserve actual mismatched keys. Bookmakers/selection_ids are unique nonempty arrays; normally each has one member. Only missing/blocked may group observations, with normalized_key null/reason, expanding their Cartesian product into rows. Every researched primary/alternative has Stake, BET99, bet365 rows, including gaps. Available needs price, quote/check times, direct bookmaker source, known jurisdiction/conditions; quoted<=checked<=cutoff, both within 300 seconds of cutoff. Verified live-display capture may be labeled quote time. Missing/blocked/suspended price=null with reason; stale price retained/ineligible. Never invent quote time from attempt time, bypass access or combine cross-book best prices into an accumulator. **7. Joint.** All-positive-profit excludes push/void. Single/identity equals its calibrated leg, interval and bounds [p,p]. For 2–14 events include every unordered dependence pair; cross-sport does not establish independence. Modeled needs artifacts and either reproducible full joint simulation (positive count, seed, marginals within 1 ppm, separate simulation/model uncertainty) or ordered conditional chain: each given_ids exactly all preceding legs. Multiply once before rounding; marginal substitution requires independence from the entire preceding set, not just pairs. Validate conditionals/joint and propagate leg/dependence uncertainty; any displayed joint confidence cannot exceed weakest leg/joint-validation tier. Unknown/unvalidated dependence or insufficient budget: bounds_only/bounds, point/interval null, bounds `[max(0,sum(p)-(n-1)),min(p)]` in integer ppm. These are logical bounds on point marginals, not uncertainty intervals. Modeled point lies inside them. Unknown marginals: unavailable/none, point/bounds/interval null. Non-chain conditionals empty; non-simulation count/seed null; single dependence empty. Never guess correlations. V1 joint betting value is deliberately unknown/no-bet: analytical probability only. Executable accumulator EV needs a future joint-payout/combination-quote extension. **8. Ledger/panels.** Inputs link findings→sources; conclusions link reasoning→findings/assumptions. Verified findings require sources; unknown requires gap; unused requires unused_reason, used requires null. Contradicts links reciprocal, resolved/unresolved explicitly in reasoning. Production calibrated forecasts require used verified official primary evidence plus model artifacts; engine string alone is not provenance proof. Preserve unfavorable/unused relevant findings, stale quotes, attribution and source gaps; no invented facts. Panel available=nonempty IDs/why null; partial=nonempty/reason; unavailable/not_applicable=empty/reason. Alternatives→other selections; quotes→quotes; momentum/H2H/lineups/risks/other→findings; reasoning→reasoning; sources→sources, event scoped. Every relevant finding/source/quote/reasoning remains reachable. All nine panels start collapsed, expand/export stored references without new research. Keyboard/aria-expanded follow [W3C disclosure](https://www.w3.org/WAI/ARIA/apg/patterns/disclosure/) (checked 2026-11-29). **9. Views/language.** Default shows primary, calibrated probability, separate confidence, short reason, event/market identity, cutoff and no-bet badge/reason. Missing states explicitly show forecast/probability/confidence unavailable and why. Joint names its definition/limit. Both views read identical canonical fields. core_sha256=SHA-256(UTF-8(JCS(core))), per [RFC 8785](https://www.rfc-editor.org/rfc/rfc8785.txt) (checked 2026-11-29). Freeze core; changes need new ID/revision/supersedes. Locale packs retain hash. Canonical templates are English; complete en pack reuses them with nodes empty. Other complete packs have rendered=requested, exactly one node/text ID, missing empty/why null. Partial/unavailable list missing IDs with reason; unavailable has rendered null/nodes empty. No silent fallback: show existing requested-language unavailable label. Production requires complete selected-language text, including Hindi/all configured existing locales; locale inventory/allowance amounts were not supplied, inherit rather than invent them. Token sets {{token}} exactly match unique bindings; pointers relative to core resolve scalars/text IDs, text-ref chains acyclic. Swarm translates narrative/gaps, preserving IDs, tokens, negation/verdict; source excerpts remain original. All numerical conclusions use bindings, never separately translated numbers. percent1=ppm/10000 percent, one decimal half-up; 612345→61.2%. Intervals use same rounding, odds retain canonical precision. Decisions/ties use original integers; don't force displayed partitions to 100%. Near endpoints use <0.1%/>99.9%, exact values in details. Local digits/separators may vary; numbers cannot. Deduplicate/reuse ledger under existing allowance_ref; exhausted work becomes explicit gaps, no extra fees. ## Minimal valid instance (synthetic) Fictitious event/calibration, not real evidence/performance. Missing prices force unknown value/no-bet; forecast available. English reuses canonical text. ```json {"core":{"schema_version":"imd.forecast-report/1.0.0","mode":"synthetic","id":"report1","revision":1,"supersedes":null,"engine":"IMD Swarm","cutoff_utc":"2026-11-29T12:00:00Z","generated_utc":"2026-11-29T12:00:00Z","budget":{"allowance_ref":"synthetic:allowance/v1","state":"complete","why":null},"events":[{"id":"e1","sport":"tennis","label":"tevent","competition":{"value":null,"why":"tgap"},"start_utc":{"value":"2026-11-30T18:00:00Z","why":null},"status":"scheduled","participants":[{"id":"p1","label":"tn","role":"entrant"},{"id":"p2","label":"ts","role":"entrant"}],"aliases":[],"decision":{"primary_market_id":{"value":"m1","why":null},"primary_selection_id":{"value":"s1","why":null},"most_probable":{"value":["s1"],"why":null},"estimated_value":{"state":"unknown","selection_id":{"value":"s1","why":null},"quote_id":{"value":"q1","why":null},"ev_ppm":{"value":null,"why":"tgap"},"ev_interval_ppm":{"value":null,"why":"tgap"},"why":"tgap"},"verdict":"no_bet","no_bet_reasons":["missing_price"],"short_reason":"treason"},"panels":{"alternatives":{"state":"available","why":null,"ids":["s2"]},"bookmaker_quotes":{"state":"available","why":null,"ids":["q1"]},"momentum":{"state":"unavailable","why":"tgap","ids":[]},"h2h":{"state":"unavailable","why":"tgap","ids":[]},"lineups_entries":{"state":"unavailable","why":"tgap","ids":[]},"risks":{"state":"available","why":null,"ids":["f1"]},"complete_reasoning":{"state":"available","why":null,"ids":["r1"]},"sources":{"state":"available","why":null,"ids":["x1"]},"other_findings":{"state":"unavailable","why":"tgap","ids":[]}}}],"markets":[{"id":"m1","event_id":"e1","kind":"winner","period":"full_contest","metric":"winner","unit":"outcome","line":{"value":null,"why":"tna"},"subject_ids":[],"rules_id":"rules1","rules_text":"trules","rules_source_ids":["x1"],"comparison":"partition","selections":[{"id":"s1","label":"tn","subject_ids":["p1"],"outcome_code":"win","estimate":{"state":"calibrated","raw_ppm":{"value":600000,"why":null},"calibrated_ppm":{"value":600000,"why":null},"settlement":{"value":{"win":600000,"half_win":0,"push":0,"half_loss":0,"loss":400000,"void":0},"why":null},"interval":{"value":{"low_ppm":400000,"high_ppm":800000,"level_ppm":900000,"method_ref":"synthetic:interval/v1"},"why":null},"calibration_id":{"value":"c1","why":null},"confidence":"low","why":"tlow","finding_ids":["f1"]}},{"id":"s2","label":"ts","subject_ids":["p2"],"outcome_code":"win","estimate":{"state":"calibrated","raw_ppm":{"value":400000,"why":null},"calibrated_ppm":{"value":400000,"why":null},"settlement":{"value":{"win":400000,"half_win":0,"push":0,"half_loss":0,"loss":600000,"void":0},"why":null},"interval":{"value":{"low_ppm":200000,"high_ppm":600000,"level_ppm":900000,"method_ref":"synthetic:interval/v1"},"why":null},"calibration_id":{"value":"c1","why":null},"confidence":"low","why":"tlow","finding_ids":["f1"]}}]}],"quotes":[{"id":"q1","market_id":"m1","selection_ids":["s1","s2"],"normalized_key":null,"bookmakers":["stake","bet99","bet365"],"other_name":{"value":null,"why":"tna"},"jurisdiction":{"value":null,"why":"tgap"},"conditions":{"value":null,"why":"tgap"},"state":"missing","decimal":{"value":null,"why":"tgap"},"quoted_utc":{"value":null,"why":"tgap"},"checked_utc":"2026-11-29T12:00:00Z","source_ids":[],"why":"tgap"}],"sources":[{"id":"x1","kind":"synthetic","publisher":"Synthetic fixture","uri":{"value":null,"why":"tgap"},"accessed_utc":"2026-11-29T11:00:00Z","published_utc":{"value":null,"why":"tgap"},"excerpt":"Synthetic test inputs only.","locator":"Worked acceptance case","snapshot_sha256":{"value":null,"why":"tgap"},"access":"unavailable","limitation":"tgap"}],"findings":[{"id":"f1","event_ids":["e1"],"selection_ids":["s1","s2"],"topic":"risk","metrics":[],"claim":"tfixture","status":"verified","stance":"neutral","source_ids":["x1"],"effective_utc":{"value":"2026-11-29T11:00:00Z","why":null},"gap":null,"use":"used","unused_reason":null,"contradicts":[]}],"reasoning":[{"id":"r1","event_ids":["e1"],"selection_ids":["s1","s2"],"conclusion":"treason","finding_ids":["f1"],"assumptions":["tfixture"],"effect":"neutral"}],"calibrations":[{"id":"c1","model_ref":"synthetic:model/v1","calibrator_ref":"synthetic:calibrator/v1","stratum":"synthetic tennis winner","train_end_utc":"2025-12-31T00:00:00Z","validation_start_utc":"2026-01-01T00:00:00Z","validation_end_utc":"2026-01-31T00:00:00Z","n":100,"brier_ppm":200000,"logloss_micro":500000,"calibration_error_ppm":20000,"interval_coverage_ppm":900000,"drift":"pass","source_ids":["x1"]}],"joint":{"selection_ids":["s1"],"definition":"all_positive_profit","state":"single","method":"identity","p_ppm":{"value":600000,"why":null},"bounds":{"value":{"low_ppm":600000,"high_ppm":600000},"why":null},"interval":{"value":{"low_ppm":400000,"high_ppm":800000,"level_ppm":900000,"method_ref":"synthetic:interval/v1"},"why":null},"dependence":[],"conditionals":[],"model_source_ids":[],"simulation_n":{"value":null,"why":"tna"},"seed":{"value":null,"why":"tna"},"verdict":"no_bet","value_status":"unknown","why":"tjoint"},"texts":[{"id":"tgap","template":"Unavailable: this synthetic fixture has no live data/capture.","bindings":[]},{"id":"tna","template":"Not applicable to this example.","bindings":[]},{"id":"tevent","template":"Synthetic North v South","bindings":[]},{"id":"tn","template":"North","bindings":[]},{"id":"ts","template":"South","bindings":[]},{"id":"trules","template":"Synthetic full-contest winner rules; only win or loss settles.","bindings":[]},{"id":"tlow","template":"Low: insufficient synthetic sample and wide interval.","bindings":[]},{"id":"treason","template":"Synthetic North {{p}}; missing prices: no bet.","bindings":[{"token":"p","pointer":"/markets/0/selections/0/estimate/calibrated_ppm/value","format":"percent1"}]},{"id":"tfixture","template":"Synthetic inputs/validation; no real sports evidence.","bindings":[]},{"id":"tjoint","template":"Analytical only; joint pricing unsupported: no bet.","bindings":[]}]},"core_sha256":"2f45444533439f56c228354585d3983fd53137295abcc0351072103e3f08d07f","language":{"requested":"en","rendered":"en","state":"complete","why":null,"nodes":[],"missing_text_ids":[]}} ``` ## Worked acceptance and limits | Case | Expected | |---|---| | Validate fixture | Accept synthetic only; probabilities sum to 1000000; IDs/hash resolve. | | Default/expanded | North, 60.0%, low; no-bet/missing price. Same binding in both views; nine collapsed/retrievable panels; six missing prices/times, no EV. | | Hindi reason template | `नॉर्थ की संभावना {{p}}; भाव उपलब्ध नहीं, इसलिए दांव नहीं।` keeps treason/p binding and yields 60.0%; other locales follow the same contract. | | Joint | Single 600000, analytical only, value unknown/no-bet. | | **Invalid mutation** | Set core.quotes[0].decimal to {"value":0,"why":null}, recompute hash: reject QUOTE_ODDS_RANGE (canonical string>1 required; missing quote must have null price). | | Separate synthetic dependence test | Marginals 600000/500000, unknown dependence: bounds [100000,500000], point null; never assume 300000. | Limits: no live data/API/locale/provenance/model-performance verification. Registries/models need integration; unsupported payouts/joint pricing require abstention.