Acknowledge the terms to access this dataset
This repository is publicly accessible, but you have to accept the conditions to access its files and content.
Access is granted for non-commercial research and evaluation use only. By requesting access you agree not to redistribute this dataset or any derivative data, to cite Dhi Technologies in any publication or output that uses it, and to obtain a separate commercial license via dhi-tech.com before any commercial use. Access requests are reviewed manually by Dhi Technologies.
Log in or Sign Up to review the conditions and access this dataset content.
Causal Predictive Alerting Benchmark
Product: causal-predictive-alerting ("precausal"): predicts an incident seconds before it happens from kinematic trajectories, and proves why via ablation-replay counterfactuals and a falsification ledger (every prediction is later graded fulfilled or falsified against what actually happened).
Synthetic data, real-data validation in progress
All scenarios are seeded, procedurally generated kinematic trajectories (zone-entry,
convergence, crowd-buildup, and several designed negative and edge cases), run through the
actual production code (precausal.state.WorldState, precausal.predict.Predictor,
precausal.grounding.FalsificationLedger, precausal.counterfactual.explain), not a
reimplementation. CPU-only, no GPU, no external data. Real-camera and real-incident validation
has not been performed on this product.
What's in this dataset
Two batteries, from two different harness runs, kept separate rather than merged, so the numbers below are not mixed:
battery_200.jsonl(201 lines, about 66 KB: 200 scenario rows plus 1 trailing summary row): the earlier, simpler 200-scenario battery:zone_entry,convergence,crowd_buildup,no_incident, 50 each. Real measured summary (embedded as the last line of the file):- 200 scenarios, 150 alerts fired (75%)
- Ledger verdicts: 63 fulfilled, 87 falsified, 50 no-alert (63 + 87 + 50 = 200; 63 + 87 = 150, reconciles with alerts fired)
- Outcome base rate 0.34 (68 of 200 scenarios actually reached the hazard)
- Mean predicted lead time: 4.688 s (median 4.5 s)
scenario_battery_rows.jsonl(1996 rows, about 1.58 MB) plusscenario_battery_summary.json(about 3.1 KB): the current, scaled battery (about 9.5x the size of the prior 210-scenario run, same proportions, same 8 scenario kinds:zone_entry,convergence,convergence_multi,crowd_buildup,no_incident,departing,stationary,out_of_horizon). Each row also carries the counterfactual explanation (would_not_fire_if,still_fires_despite,necessity_by_entityper-entity ablation replay result). Real measured per-kind precision fromscenario_battery_summary.json:kind n TP FP FN TN precision recall mean abs lead error (s) zone_entry 428 275 141 10 2 0.661 0.965 0.622 convergence 333 143 189 0 1 0.431 1.0 1.313 convergence_multi 95 41 53 0 1 0.436 1.0 1.201 crowd_buildup 428 179 249 0 0 0.418 1.0 1.396 At this larger scenario count,
zone_entryshows its first non-zero false-negative bucket (10 of 428, plus 2 true negatives): a real, reproducible finding the 210-scenario battery was too small to surface, not a scenario-generation artifact. See Limitations.False-positive rate on the 712 negative scenarios: 8.8% overall (
no_incident0.0%,departing1.1%,stationary23.7%,out_of_horizon11.3%, the two hardest edge cases). Counterfactual stability: removing the causal entity eliminates the prediction 100% of the time forzone_entry,convergence, andconvergence_multi(pct_remove_necessary); forcrowd_builduponly 24.1% of the time, because a crowd above threshold genuinely does not depend on any single occupant. Freezing the approaching entity (pct_freeze_necessary) is 100.0% forzone_entry, 99.4% forconvergence, and 98.4% forconvergence_multi: the small gap below 100% on the two-and-three-track cases is the known, disclosed asymmetry where one track's approach alone can still close the gap when the other is frozen, not a bug.
How to load it
Verified against the actual files in this repository (prints 201 for the battery file, 1996
scenario rows, and the summary's n_scenarios):
import json
from huggingface_hub import hf_hub_download
repo_id = "Dhi-Technologies/causal-predictive-alerting-benchmark"
battery_path = hf_hub_download(repo_id, "battery_200.jsonl", repo_type="dataset")
rows_path = hf_hub_download(repo_id, "scenario_battery_rows.jsonl", repo_type="dataset")
summary_path = hf_hub_download(repo_id, "scenario_battery_summary.json", repo_type="dataset")
battery = [json.loads(line) for line in open(battery_path)] # last line is a summary, not a scenario
rows = [json.loads(line) for line in open(rows_path)]
summary = json.load(open(summary_path))
print(len(battery), "battery_200 lines (200 scenarios + 1 summary)")
print(len(rows), "scenario_battery rows")
print(summary["n_scenarios"])
# 201
# 1996
# 1996
Measured result
Precision below 1.0 is disclosed, not hidden: this is an early-warning system trading some false
alarms for lead time, and the ledger plus counterfactuals exist specifically so that trade-off is
measurable per scenario kind rather than asserted. At the larger scenario count in this release,
recall for zone_entry also drops below 1.0 (0.965, 10 false negatives out of 428) for the same
reason: a wider sweep of randomized zone geometry and headings surfaces real misses that a smaller
run does not have enough scenarios to hit.
Reproduce the default (210-scenario) battery with:
PYTHONPATH=src .venv/bin/python experiments/scenario_battery.py --seed 0 \
--out evidence/scenario_battery_rows.jsonl \
--summary-out evidence/scenario_battery_summary.json
This default-count command was re-run as part of producing this release and diffed byte-for-byte against the evidence files checked into the product repository: rows and summary were both byte-identical. That default run is a non-regression check, not the file published here; see "Regeneration provenance" below for exactly how the 1996-scenario files in this dataset were produced.
Schema notes
battery_200.jsonlrows andscenario_battery_rows.jsonlrows use different schemas (the newer battery addscounterfactual,occurred_at_t, andzonefields); do not concatenate them without normalizing.predicted_lead_sis the lead time the predictor claimed at alert time;actual_lead_s(newer battery only) is the lead time actually measured once the ledger resolved the prediction as fulfilled.ledger_fulfillmenthas exactly two terminal values,fulfilledandfalsified, plusno_alertfor scenarios where nothing fired; nothing else is invented by the ledger.
Method card, no trained weights
No trained model or weights. Predictions come from kinematic short-horizon extrapolation run through the real production code; every prediction is graded fulfilled or falsified against what actually happened (the falsification ledger), and every alert carries an ablation-replay counterfactual. Precision below 1.0 is disclosed per scenario kind, not hidden.
Limitations
- Kinematics is constant-velocity in this version; every designed hazard scenario begins with a
straight-line approach before any abort, which is an easier case for a constant-velocity
predictor by construction.
recall = 1.0still holds forconvergence,convergence_multi, andcrowd_buildupin this release, and held for all kinds in the smaller 210-scenario battery, but is scenario-generator-shaped, not a claim of perfect real-world detection: erratic or curved early trajectories are not stress-tested by either battery. At the larger scenario count,zone_entryrecall is measured at 0.965 (10 false negatives of 428), the first time this battery has surfaced a genuine miss. crowd_buildupprecision (0.418 at this scenario count, 0.356 at the smaller 210-scenario count) is genuinely the weakest of the four core alert kinds, a reproducible property of trend-slope extrapolation over a short occupancy history, not a scenario-generation artifact.- False positives at high observation noise combined with a short sample interval are a known,
reproducible edge case (
stationaryandout_of_horizonrows above): a median-of-differences velocity estimate with only a few warm-up observations can read an apparent speed well above the track's true speed from jitter alone. - All scenarios in this dataset, and in the product's own test suite, are seeded synthetic kinematic trajectories. There is no real-world camera or tracker validation of this product to date.
Regeneration provenance
The 1996-scenario battery in this release (2026-07-10) was generated from the causal-predictive-alerting
product repository at commit 93b6f71845eb2d62de5c4a60208b987ec0549d23 (origin/main,
"docs(readme): correct test count to match verified run (#16)"). No existing fix for the crash
described below was found anywhere in the repository's history or on any open branch as of this
date; a minimal, disclosed fix was applied locally to generate this release (not committed or
pushed to the product repository).
Exact scenario counts used (seed 0, about 9.524x the default 210-scenario proportions):
{
"zone_entry": 428, "convergence": 333, "convergence_multi": 95, "crowd_buildup": 428,
"no_incident": 190, "departing": 190, "stationary": 190, "out_of_horizon": 142
}
Command run (the packaged CLI only exposes --seed/--out/--summary-out, not a counts
override, so the counts above were passed directly to run_battery() via a small driver calling
the same production functions, run_battery, summarize, and _row_for_jsonl, that
experiments/scenario_battery.py --seed 0 ... itself calls):
PYTHONPATH=src .venv/bin/python <driver calling run_battery(seed=0, counts=<counts above>)> \
--seed 0 --out evidence/scenario_battery_rows.jsonl \
--summary-out evidence/scenario_battery_summary.json
Wall-clock time for the 1996-scenario run: 43 seconds (CPU-only, no GPU).
Crash found and fixed: at this scenario count, 7 of the 428 zone_entry scenarios
(scenario_id 92, 187, 208, 267, 310, 325, 340) crashed the unpatched generator with:
AssertionError: zone_entry harness bug: start point lands inside the zone
Root cause: _simulate_zone_entry's cheap min_clear heuristic backs a track off from its target
point by the zone's half-diagonal (hypot(half_w, half_h)) plus a small margin. That heuristic
assumes the target sits at the zone center, but the target is actually drawn up to half the zone's
extent off-center. When the target lands near a far corner and the approach heading points back
across the zone, the true exit distance approaches the FULL diagonal, not the half-diagonal, so
the heuristic underestimates the required backoff and the generated start point can still land
inside the (possibly large, rotated) zone. This is a rare geometry draw only reached at larger
scenario counts, which is why it did not appear in the 210-scenario battery.
Fix applied (minimal, only engages when the cheap heuristic would fail): after computing the
heuristic backoff, check whether the resulting start point still lands inside the zone; if so, and
only then, recompute the exact backoff distance via a ray-exit binary search from the target point
along the same heading (reusing the same boundary_point_along_ray geometry the out_of_horizon
scenario kind already uses). This changes behavior for exactly the scenarios where the heuristic
was previously wrong; every scenario where the heuristic already cleared the zone is unaffected.
Non-regression proof: the default battery (--seed 0, default counts: zone_entry=45, convergence=35, convergence_multi=10, crowd_buildup=45, no_incident=20, departing=20, stationary=20, out_of_horizon=15, n=210) was regenerated with the same fix applied and diffed
byte-for-byte against this repository's committed evidence/scenario_battery_rows.jsonl and
evidence/scenario_battery_summary.json: both were byte-identical (no scenario in the default
210-scenario battery hits the geometry this fix touches). The product's full test suite
(PYTHONPATH=src .venv/bin/python -m pytest tests/ -q) was also run and passed: 16 passed in 1.10s.
License
This dataset is released under CC BY-NC 4.0 (non-commercial). Access is gated and requires manual approval: it is provided for non-commercial research and evaluation only, redistribution is not permitted, and any publication or output using it should cite Dhi Technologies. Commercial use requires a separate agreement; contact dhi-tech.com.
Try it
- Live demo (static, precomputed battery verdict counts and per-kind breakdown): causal-predictive-alerting-demo
- Blog: Six products, one honesty thesis
- Dhi Labs overview: dhi-tech.com/labs
- Dhi Labs product page: dhi-tech.com/labs/causal-predictive-alerting/
Source & research context
- Code: proprietary, closed source permanently; not a publicly browsable repository. Partnership or access inquiries: dhi-tech.com.
- Companion paper: Dhi Labs paper 10 (causal predictive alerting), in preparation
- Collection: Dhi Labs, honest edge vision AI
- Blog dataset: https://huggingface.co/datasets/Dhi-Technologies/blog
- Org: https://huggingface.co/Dhi-Technologies, GitHub org: https://github.com/DHI-Technologies-Inc
Commercial licensing
Research and evaluation use is free. Production and commercial use is licensed self-serve with published prices.
- Get a license: https://dhi-tech.com/buy/predictive-safety
- All published prices: https://dhi-tech.com/pricing/
- Downloads last month
- 7