Hierarchical Symbolic Reasoning in Hyperbolic Space for Deep Discriminative Models

Ainkaran Santhirasekaram, Avinash Kori, Andrea G. Rockall, Mathias Winkler, Francesca Toni, Ben GlockerarXiv 2022 · OpenReview

Abstract

Explanations for black-box models help us understand model decisions as well as provide information on model biases and inconsistencies. Most of the current explainability techniques provide a single level of explanation, often in terms of feature importance scores or feature attention maps in input space. Our focus is on explaining deep discriminative models at multiple levels of abstraction, from fine-grained to fully abstract explanations. We achieve this by using the natural properties of hyperbolic geometry to more efficiently model a hierarchy of symbolic features and generate hierarchical symbolic rules as part of our explanations. Specifically, for any given deep discriminative model, we distill the underpinning knowledge by discretisation of the continuous latent space using vector quantisation to form symbols, followed by a hyperbolic reasoning block to induce an abstraction tree. We traverse the tree to extract explanations in terms of symbolic rules and its corresponding visual semantics. We demonstrate the effectiveness of our method on the MNIST and AFHQ high-resolution animal faces dataset. Our framework is available at https://github.com/koriavinash1/SymbolicInterpretability.

Introduction

Deep learning models are notoriously opaque. While standard Explainable AI (XAI) tools like saliency maps identify important input features, they often provide "flat" explanations that fail to capture the hierarchical reasoning of the model—how low-level features combine into mid-level concepts and high-level decisions. Furthermore, representing these exponential hierarchies in Euclidean space leads to significant distortion because hierarchies grow exponentially, while Euclidean space only grows polynomially.

Methodology

The proposed framework bridges the gap between continuous neural networks and discrete symbolic logic through a three-step pipeline designed to distill model-centric logic:

  1. Symbol Formation (Discretization): The continuous latent space of a pre-trained classifier is discretized using Vector Quantization (VQ) to create a vocabulary of visual concepts.
  2. Hyperbolic Reasoning Blocks: Leveraging hyperbolic geometry (specifically the Poincaré disk and Hyperboloid models), the system models hierarchies with minimal distortion. Binary weight layers learn "conjunctions"—how groups of symbols at one level combine to form a more abstract symbol at the next level.
  3. Rule Extraction & Visualization: Logical rules are generated by traversing the resulting abstraction tree. A separate decoder is used to visualize the "semantic difference" each symbol contributes, making the abstract logic human-understandable.
The proposed architecture for distilling black-box models into hierarchical symbolic rules.

Experimental Evaluation

The framework was evaluated on two distinct benchmarks:

  • MNIST: A classic dataset of handwritten digits used as a proof of concept for symbolic rule generation.
  • AFHQ (Animal Faces High-Quality): A dataset of high-resolution animal faces (cats, dogs, wildlife) used to demonstrate that the method scales to complex, real-world imagery.

Results and Discussion

Hyperbolic embeddings proved significantly more efficient than Euclidean ones for capturing hierarchical relationships. On MNIST, a 2-dimensional Poincaré embedding achieved 90% distillation accuracy, significantly outperforming a 2D Euclidean embedding at 81%.

This "Hyperbolic Advantage" stems from the fact that hyperbolic space is essentially a continuous version of a tree. As the complexity of the dataset increases (moving from MNIST to AFHQ), the performance gap widens. Hyperbolic embeddings maintain high accuracy even as dimensionality is reduced, proving they are far more efficient at capturing the exponential growth of hierarchical structures.

Visualization of the learned symbolic hierarchy embedded in hyperbolic space.

Qualitatively, the visual rules produced show a clear progression from localized heatmaps to global heatmaps as one moves up the hierarchy, effectively "showing the model's work" at every stage of abstraction.

Conclusion

While the framework provides faithful, multi-level explanations, some limitations remain. The number of symbols in the codebook currently requires manual tuning, and the visualization decoder is trained independently of the reasoning blocks. Future work could involve domain experts to map these discovered symbols to linguistic concepts, creating a truly "neuro-symbolic" bridge for human-in-the-loop interpretability.

Summary updated

Abstract

Explanations for \emph{black-box} models help us understand model decisions as well as provide information on model biases and inconsistencies. Most of the current explainability techniques provide a single level of explanation, often in terms of feature importance scores or feature attention maps in input space. Our focus is on explaining deep discriminative models at \emph{multiple levels of abstraction}, from fine-grained to fully abstract explanations. We achieve this by using the natural properties of \emph{hyperbolic geometry} to more efficiently model a hierarchy of symbolic features and generate \emph{hierarchical symbolic rules} as part of our explanations. Specifically, for any given deep discriminative model, we distill the underpinning knowledge by discretisation of the continuous latent space using vector quantisation to form symbols, followed by a \emph{hyperbolic reasoning block} to induce an \emph{abstraction tree}. We traverse the tree to extract explanations in terms of symbolic rules and its corresponding visual semantics. We demonstrate the effectiveness of our method on the MNIST and AFHQ high-resolution animal faces dataset. Our framework is available at \url{https://github.com/koriavinash1/SymbolicInterpretability}.
BibTeX
@misc{santhirasekaram2022hierarchical,
  author = {Ainkaran Santhirasekaram and Avinash Kori and Andrea G. Rockall and Mathias Winkler and Francesca Toni and Ben Glocker},
  title = {{Hierarchical Symbolic Reasoning in Hyperbolic Space for Deep Discriminative Models}},
  year = {2022},
  eprint = {2207.01916},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2207.01916},
}
Figure