GLACIER: Rethinking Mass Spectrum Prediction as an Object Detection Problem
About
Predicting tandem mass spectra (MS/MS) from molecular structures represents a central task in analytical chemistry with direct relevance to clinical metabolomics, systems biology, and adjacent disciplines. In this work, we revisit the problem through the lens of object detection on molecular graphs. Molecular fragmentation, a central step in MS/MS prediction, can be approximated as detecting a set of subgraphs (i.e., fragments) and their associated spectral contributions. Existing fragment-based models follow a two-stage paradigm -- first generating candidate fragments and then scoring them -- analogous to two-stage R-CNNs in computer vision. Towards higher accuracy and faster inference, we introduce GLACIER, a single-stage transformer-based fragment detection neural network for molecular graphs. This unified formulation eliminates the need for candidate enumeration, enabling scalable and globally consistent modeling of molecular fragmentation. GLACIER is faster and more accurate than existing state-of-the-art by a significant margin, achieving 70.0% and 69.7% Top-1 retrieval accuracy with and without contrastive finetuning on the MassSpecGym dataset (from the previous SOTA of 64.0%) and 52.5% and 38.5% respectively on the NIST'20 dataset (from 33.2%). Furthermore, GLACIER provides nearly 8-fold inference speedup over our prior two-stage model. Code is available at https://github.com/coleygroup/ms-pred
Related benchmarks
| Task | Dataset | Result | Rank | |
|---|---|---|---|---|
| Molecular retrieval | NIST 2020 (Scaffold) | Top-1 Accuracy46 | 16 | |
| Molecule Retrieval | MassSpecGym Formula Split | Recall@149.88 | 16 | |
| Molecular retrieval | NIST 2020 (Random split) | Top-1 Accuracy53.3 | 12 | |
| Spectral prediction | NIST [M+H]+ adduct '20 (Random split) | Cosine Similarity0.838 | 8 | |
| Spectral prediction | NIST [M+H]+ adduct '20 (Scaffold split) | Cosine Similarity78.8 | 8 | |
| Molecular retrieval | MassSpecGym Mass Challenge 3 | Recall@169.95 | 7 | |
| Spectral prediction | NIST positive mode 2020 (Random) | Cosine Similarity82.9 | 6 | |
| Spectral prediction | NIST positive mode Scaffold 2020 | Cosine Similarity0.787 | 6 | |
| Retrieval | NIST 2020 | Top-1 Accuracy52 | 5 | |
| Spectral prediction | NIST Positive+negative mode Random split 20 | Cosine Similarity0.821 | 5 |