A Pattern Language for Machine Learning Tasks
Benjamin Rodatz, Ian Fan, Tuomas Laakkonen, Neil John Ortega, Thomas Hoffmann, Vincent Wang-Mascianica
TL;DR
The paper introduces a diagrammatic, task-based language for ML in which objectives are encoded as equational constraints among learners. It formalises atomic and compound tasks, defines objective functions via divergences and a differentiable combination, and shows how standard ML paradigms instantiate patterns that can be reasoned about compositionally. It then introduces a novel manipulation task that edits a target attribute while preserving other properties, and proves connections to Bayesian inversion and CycleGAN through refinements, showing how such tasks can yield architecture-agnostic, training-stable models without adversarial training per se. Empirically, it validates manipulation on Spriteworld, MNIST, and CelebA, demonstrating end-to-end, pattern-driven design with interpretable latent-space effects.
Abstract
We formalise the essential data of objective functions as equality constraints on composites of learners. We call these constraints "tasks", and we investigate the idealised view that such tasks determine model behaviours. We develop a flowchart-like graphical mathematics for tasks that allows us to; (1) offer a unified perspective of approaches in machine learning across domains; (2) design and optimise desired behaviours model-agnostically; and (3) import insights from theoretical computer science into practical machine learning. As a proof-of-concept of the potential practical impact of our theoretical framework, we exhibit and implement a novel "manipulator" task that minimally edits input data to have a desired attribute. Our model-agnostic approach achieves this end-to-end, and without the need for custom architectures, adversarial training, random sampling, or interventions on the data, hence enabling capable, small-scale, and training-stable models.
