Published May 29, 2026 | Version 1.3

A Grammar of Machine Learning Workflows: Rejecting Data Leakage at Call Time

Authors/Creators

Description

Data leakage has been identified in 648 published papers across 30 scientific fields. The knowledge to prevent it has existed for over a decade; the problem persists because the tools do not enforce what the textbooks teach. This paper presents a grammar (eight typed primitives connected by a directed acyclic graph with four hard constraints) that makes the most damaging leakage types structurally unrepresentable within the grammar's scope. The core mechanism is a terminal assessment gate: the first call-time-enforced evaluate/assess boundary documented in the peer-reviewed ML methodology literature (to my knowledge, as of May 2026), backed by a specification precise enough for independent reimplementation. A companion landscape study across 2,047 datasets grounds the constraints in measured effect sizes. Two reference implementations (Python, R) are available.

Files

roth2026_grammar_ml_workflows_v1.3.pdf

Files (268.0 kB)

Name Size Download all
md5:6fbbe2b2688a975cafb34d3108948f70
268.0 kB Preview Download

Additional details

Related works

Is identical to
Preprint: arXiv:2603.10742 (arXiv)
Is supplemented by
Software: https://github.com/epagogy/ml (URL)
Software: https://pypi.org/project/mlw/ (URL)
Preprint: 10.5281/zenodo.19406148 (DOI)

Software

Repository URL
https://github.com/epagogy/ml
Programming language
Python , R
Development Status
Active