# Composition of Relational Features with an Application to Explaining Black-Box Predictors

arXiv: https://arxiv.org/abs/2206.00738 · HTML: https://mlsanity.com/paper/2206.00738/

## Key facts

- No citing papers in the map yet (data through 14 Oct 2026).
- Builds on 8 of its 85 references that are in the map.
- First posted on arXiv 1 Jun 2022.

## Builds on (most cited first, 8 of 8)

- [Adam: A Method for Stochastic Optimization](https://mlsanity.com/paper/1412.6980/) (2014)
- [PyTorch: An Imperative Style, High-Performance Deep Learning Library](https://mlsanity.com/paper/1912.01703/) (2019)
- [Towards Robust Interpretability with Self-Explaining Neural Networks](https://mlsanity.com/paper/1806.07538/) (2018)
- [Explainable Deep Learning: A Field Guide for the Uninitiated](https://mlsanity.com/paper/2004.14545/) (2020)
- [Towards Explainable Deep Neural Networks (xDNN)](https://mlsanity.com/paper/1912.02523/) (2019)
- [Incorporating Symbolic Domain Knowledge into Graph Neural Networks](https://mlsanity.com/paper/2010.13900/) (2020)
- [Logical Explanations for Deep Relational Machines Using Relevance Information](https://mlsanity.com/paper/1807.00595/) (2018)
- [Inclusion of Domain-Knowledge into GNNs using Mode-Directed Inverse Entailment](https://mlsanity.com/paper/2105.10709/) (2021)

## Abstract (arXiv)

Relational machine learning programs like those developed in Inductive Logic Programming (ILP) offer several advantages: (1) The ability to model complex relationships amongst data instances; (2) The use of domain-specific relations during model construction; and (3) The models constructed are human-readable, which is often one step closer to being human-understandable. However, these ILP-like methods have not been able to capitalise fully on the rapid hardware, software and algorithmic developments fuelling current developments in deep neural networks. In this paper, we treat relational features as functions and use the notion of generalised composition of functions to derive complex functions from simpler ones. We formulate the notion of a set of M-simple features in a mode language M and identify two composition operators (ρ1 and ρ2) from which all possible complex features can be derived. We use these results to implement a form of "explainable neural network" called Compositional Relational Machines, or CRMs, which are labelled directed-acyclic graphs. The vertex-label for any vertex j in the CRM contains a feature-function fj and a continuous activation function gj. If j is a "non-input" vertex, then fj is the composition of features associated with vertices in the direct predecessors of j. Our focus is on CRMs in which input vertices (those without any direct predecessors) all have M-simple features in their vertex-labels. We provide a randomised procedure for constructing and learning such CRMs. Using a notion of explanations based on the compositional structure of features in a CRM, we provide empirical evidence on synthetic data of the ability to identify appropriate explanations; and demonstrate the use of CRMs as 'explanation machines' for black-box models that do not provide explanations for their predictions.
