Hierarchical Grammar-Induced Geometry for Data-Efficient Molecular Property Prediction

Minghao Guo, Veronika Thost, Samuel W Song, Adithya Balachandran, Payel Das, Jie Chen, Wojciech Matusik

Abstract

In the fields of drug discovery and materials science, the scarcity of labeled data often limits the effectiveness of deep learning models. While Graph Neural Networks (GNNs) have become a standard for molecular property prediction, they typically require large datasets to learn meaningful structural representations. This paper introduces Geo-DEG (Geometry-induced Data-Efficient Grammar), a framework that constructs an explicit "geometry" of molecular space using a hierarchical molecular grammar. By measuring structural similarity through the distance between production rules and performing graph neural diffusion over this induced map, Geo-DEG achieves state-of-the-art performance on small-scale datasets where traditional supervised and pre-trained models often fail.

1. Introduction

The acquisition of molecular property data is a resource-intensive process involving laborious wet-lab experiments. Consequently, many critical datasets in chemistry and biology are "small," often containing fewer than 300 samples. Standard GNNs are notoriously data-hungry and struggle to generalize in these low-data regimes because they lack a robust "structural prior"—an inherent understanding of molecular similarity—without extensive supervision.

To address this, we propose a shift from learning isolated latent embeddings to building a comprehensive map of molecular relationships. By leveraging a generative grammar to define the geometry of the molecular neighborhood, we can treat property prediction as a collective task, utilizing the known properties of structurally similar molecules to inform predictions for new, unseen samples.

2. Methodology

2.1 Hierarchical Molecular Grammar

The core of the Geo-DEG framework is a two-level hierarchical grammar designed to manage computational complexity while capturing structural nuance:

  1. Meta-Grammar: Defines the high-level "skeleton" or junction tree of the molecule. This pre-defined component handles the complex topological arrangements common across molecular classes.
  2. Molecular Grammar: A learnable component that handles specific atoms and bonds (the "flesh").

This hierarchy allows the system to efficiently construct a large-scale map of molecular space without the combinatorial explosion of intermediate states that hindered previous geometric approaches.

2.2 Grammar-Induced Geometry

Using these grammar rules, we construct a literal graph—the geometry—where each node represents a molecule or an intermediate structure, and each edge represents a specific grammar production rule. In this space, the distance between two molecules is a direct reflection of their structural similarity as defined by the shared rules required to construct them. This provides a more interpretable and explicit prior than black-box neural embeddings.

2.3 Graph Neural Diffusion (GRAND)

Rather than predicting properties for a molecule in isolation, Geo-DEG employs Graph Neural Diffusion (GRAND). This process "smooths" property values across the entire grammar-induced geometry. By treating the geometry as a manifold, the model leverages the neighborhood effect: if a cluster of structurally similar molecules exhibits a specific property, a new sample within that neighborhood is likely to share it. This diffusion mechanism provides a grounding effect that stabilizes predictions in the face of limited data.

3. Experimental Setup

We evaluated Geo-DEG across eight benchmark datasets representing diverse chemical domains and tasks:

  • Small-Scale Datasets: CROW (polymers), Permeability, HOPV (organic photovoltaics), DILI (liver injury), and PTC (toxicology).
  • Standard Benchmarks: FreeSolv (hydration free energy), Lipophilicity, and ClinTox.

The evaluation included both regression and classification tasks, comparing Geo-DEG against standard supervised GNNs and large-scale pre-trained models like GIN.

4. Results and Analysis

4.1 Superiority in Small-Data Regimes

Geo-DEG consistently outperformed both supervised GNNs and pre-trained models on small datasets. A notable example is the CROW polymer dataset, where Geo-DEG trained on only 50% of the available data matched the performance of a state-of-the-art pre-trained GNN trained on 100% of the data. This demonstrates a significant leap in data efficiency.

4.2 Stability and Generalization

Traditional GNNs often exhibit high variance and instability when trained on small samples. In contrast, the grammar-induced geometry of Geo-DEG provides a structural anchor that leads to more consistent and reliable predictions. On the ClinTox dataset, Geo-DEG (using an MPNN encoder) achieved a 92.2 ROC-AUC, a substantial improvement over the 72.6 ROC-AUC achieved by a standard pre-trained GIN model.

5. Discussion and Conclusion

The success of Geo-DEG suggests that generative grammars are not merely tools for molecular design, but are powerful frameworks for measuring molecular similarity. By explicitly mapping the "molecular neighborhood," we can overcome the limitations of data scarcity.

5.1 Limitations and Future Work

Currently, the framework operates on 2D hypergraphs. However, in many biological contexts, 3D conformation is a primary driver of function. Future iterations of this work will explore extending the grammar-induced geometry to 3D structures. Additionally, while the meta-grammar is robust, the molecular grammar currently requires domain-specific learning. Expanding the scope of this approach to other graph-based domains, such as circuit design or social network analysis, remains a promising avenue for research.

Summary updated

BibTeX
@inproceedings{guo2023hierarchical,
  author = {Minghao Guo and Veronika Thost and Samuel W Song and Adithya Balachandran and Payel Das and Jie Chen and Wojciech Matusik},
  title = {{Hierarchical Grammar-Induced Geometry for Data-Efficient Molecular Property Prediction}},
  booktitle = {International Conference on Machine Learning},
  year = {2023},
  url = {https://openreview.net/forum?id=G3vwtUqvrk},
}
Figure