Brainwash: A Data System for Feature Engineering

Michael R. Anderson, Dolan Antenucci, Victor Bittorf, Matthew Burgess, Michael J. Cafarella, Arun Kumar, Feng Niu, Yongjoo Park, Christopher Ré, Ce Zhang

Abstract

While machine learning algorithms often receive the bulk of academic attention, the practical bottleneck in building modern AI systems—such as IBM’s Watson or Google’s Knowledge Graph—is the "relentless slog" of feature engineering. This paper introduces Brainwash, a proposed data system designed to automate the tedious process of feature extraction. By treating feature engineering as a collaborative, data-driven workflow, Brainwash aims to accelerate the "Explore-Extract-Evaluate" loop that currently consumes the majority of a machine learning engineer's time.

The Bottleneck: The "Relentless Slog"

Building high-performance machine learning models involves writing extensive code to extract signals from raw, messy data. This process is often inefficient for three primary reasons:

  1. Manual Statistical Analysis: Developers spend significant time writing throwaway code to visualize data distributions or identify outliers.
  2. Unknowable Specifications: Real-world data is inherently noisy. It is often impossible to determine if a feature idea—such as using a person's name to predict demographic data—will be effective until it has been fully implemented and tested.
  3. Redundancy and Failure: Even a correctly implemented feature may provide zero predictive uplift if its information is already captured by existing signals.

Because these features often operate on massive datasets, developers are trapped in a high-latency cycle: writing code, waiting hours for cluster processing, discovering the feature's failure, and repeating the process.

The Brainwash System Architecture

Brainwash is designed as a middleware layer situated between the developer and the data storage layer (SQL, NoSQL, or flat files). It introduces a novel three-phase development lifecycle to mitigate the traditional bottlenecks:

1. Explore

The system automatically generates "commodity metadata," such as frequency distributions and data samples, for both raw data and "derived objects" (intermediate data created by other developers). This provides immediate visibility into the data without requiring custom analysis code.

2. Extract

Brainwash leverages code recommendation to assist developers. By analyzing schema matches, the system identifies when a developer is working on a dataset similar to one previously processed. It then suggests existing User-Defined Functions (UDFs) that might be applicable, encouraging code reuse across the organization.

3. Evaluate

To address the latency problem, Brainwash employs speculative execution. Similar to how a CPU predicts branch paths, Brainwash guesses which code or permutations a developer might run next. It executes these tasks in the background during "slack time," providing near-instant feedback when the developer is ready to review results.

Case Studies and Preliminary Insights

The design of Brainwash is informed by two real-world projects:

  • GeoDeepDive: A system that integrates data from approximately 20,000 geology-oriented scientific papers to answer macro-level questions about the Earth's rock record.
  • Automan: A project utilizing Twitter metadata (timestamps, messages, and social networks) to estimate real-time demographic and economic trends.

In the GeoDeepDive case, the authors discovered that sophisticated linguistic features often performed no better than simple baseline features. In a traditional workflow, this discovery takes weeks; Brainwash aims to surface such insights in minutes.

Key Principles

  • Features Over Sophistication: Most successful systems (e.g., Google’s ranking algorithms) succeed not through a single complex mathematical breakthrough, but through the combination of hundreds of loosely coupled features.
  • The Multi-User Advantage: A centralized system can repurpose work across teams. If one user creates a high-quality "paragraph extractor," the system can automatically offer that output to another user working on the same raw text.
  • Schema as a Proxy for Intent: By requiring explicit input/output schemas for feature code, Brainwash can infer the purpose of opaque, compiled code without needing complex static analysis.

Conclusion and Future Work

Brainwash represents a shift from viewing feature engineering as a manual craft to treating it as a scalable system problem. While the current prototype demonstrates the potential of speculative execution and code reuse, several challenges remain. Future research will focus on improving the ranking of candidate function recommendations and refining speculative accuracy to minimize wasted computational resources. The ultimate goal is to utilize "distant supervision"—using external databases to provide labels—to further automate the recommendation and validation of new features.

Summary updated

BibTeX
@inproceedings{anderson2013brainwash,
  author = {Michael R. Anderson and Dolan Antenucci and Victor Bittorf and Matthew Burgess and Michael J. Cafarella and Arun Kumar and Feng Niu and Yongjoo Park and Christopher Ré and Ce Zhang},
  title = {{Brainwash: A Data System for Feature Engineering}},
  booktitle = {CIDR},
  year = {2013},
}
Figure