Interpretable Set Functions

Andrew Cotter, Maya R. Gupta, Heinrich Jiang, James Muller, Taman Narayan, Serena Wang, Tao ZhuarXiv 2018

Abstract

We propose learning flexible but interpretable functions that aggregate a variable-length set of permutation-invariant feature vectors to predict a label. We use a deep lattice network model so we can architect the model structure to enhance interpretability, and add monotonicity constraints between inputs-and-outputs. We then use the proposed set function to automate the engineering of dense, interpretable features from sparse categorical features, which we call semantic feature engine. Experiments on real-world data show the achieved accuracy is similar to deep sets or deep neural networks, and is easier to debug and understand.

Introduction

Many real-world machine learning tasks involve processing variable-length sets of data, such as customer reviews for a product or ingredients in a recipe. Traditional architectures like "Deep Sets" handle these unordered collections by learning transformations for each item and aggregating them. However, these models often function as "black boxes," making it difficult to understand why a specific input led to a prediction. Furthermore, they lack the ability to enforce common-sense constraints, such as ensuring that a higher star rating never decreases a sales prediction. We address these challenges by introducing Interpretable Set Functions based on Deep Lattice Networks (DLNs).

Methodology: DLN Aggregation and Monotonicity

Our approach replaces standard dense neural network layers with DLN Aggregation Functions. This architecture relies on two primary components to ensure transparency and reliability.

First, we utilize Deep Lattice Networks (DLNs). These networks use 1D "calibrators" (piecewise linear functions) to pre-process features, followed by "lattices" (interpolated look-up tables). This structure allows the model to capture complex non-linear relationships while remaining mathematically constrained.

Second, we enforce Monotonicity Constraints. By baking domain knowledge directly into the model, we can guarantee that the output responds logically to specific inputs. For example, in a sales prediction model, we can force the relationship between "average star rating" and "predicted sales" to be monotonically increasing.

The DLN Aggregation architecture uses 1D PLF calibrators and multi-dimensional lattices to process set features.

To handle sparse categorical data, we introduce the Semantic Feature Engine (SFE). The SFE decomposes sets into "tokens" or subsets and calculates statistics for them. If a specific combination of items is rare, the SFE employs a "fallback" logic, reverting to smaller, more reliable subsets to maintain prediction stability.

A critical design choice is the use of a "bottleneck" ($K=1$), which forces the model to condense the entire set into a single intermediate score. This simplification significantly enhances the ability to visualize and debug the model's logic.

Experiments and Results

We evaluated the DLN Aggregator across five diverse datasets, including Product Sales (luxury goods reviews), User Intent, CelebA attributes, Recipe Cuisine, and Wine Quality.

Performance and Reliability

In the Product Sales case study, the DLN Aggregator achieved a Mean Absolute Error (MAE) of 7502 on the test set, outperforming Deep Sets (8323) and a linear baseline (8221). The researchers found that monotonicity acted as a powerful regularizer; while Deep Sets overfit to noise in the small, non-IID dataset, the DLN remained "sensible" due to its structural constraints. Similarly, in the Wine Quality task, the DLN achieved the lowest Mean Squared Error (7.19) compared to standard DNNs and Deep Sets.

Visualizing Interpretability

One of the primary advantages of this approach is the ability to inspect the learned "calibrator curves." By plotting the relationship between input features and their calibrated values, developers can verify the model's logic.

Calibrator curves for star rating and word count demonstrate the model's learned logic and enforced monotonicity.

As shown in the calibration plots, the model can learn nuanced behaviors—such as treating 1-star and 2-star reviews as similarly negative while identifying a significant value jump for 5-star reviews—all while adhering to the global requirement of monotonicity.

Conclusion

Interpretable Set Functions offer a robust alternative to black-box deep learning for set-based data. By combining the flexibility of Deep Lattice Networks with the rigor of monotonicity constraints, we achieve competitive accuracy while providing clear, debuggable insights into model behavior. Future work will explore scaling these methods to higher-dimensional raw data and optimizing the training efficiency of constrained lattice models.

Summary updated

BibTeX
@misc{cotter2018interpretable,
  author = {Andrew Cotter and Maya R. Gupta and Heinrich Jiang and James Muller and Taman Narayan and Serena Wang and Tao Zhu},
  title = {{Interpretable Set Functions}},
  year = {2018},
  eprint = {1806.00050},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1806.00050},
}
Figure