cs.LGFeb 18, 2026

Small molecule retrieval from tandem mass spectrometry: what are we optimizing for?

Authors: Gaetan De Waele, Marek Wydmuch, Krzysztof Dembczyński, Wojciech Kotłowski, Willem Waegeman

Organizations: Department of Data Analysis and Mathematical Modelling, Ghent University, Belgium · Snowflake AI Research · Poznan University of Technology

Abstract

One of the central challenges in the computational analysis of liquid chromatography-tandem mass spectrometry (LC-MS/MS) data is to identify the compounds underlying the output spectra. In recent years, this problem is increasingly tackled using deep learning methods. A common strategy involves predicting a molecular fingerprint vector from an input mass spectrum, which is then used to search for matches in a chemical compound database. While various loss functions are employed in training these predictive models, their impact on model performance remains poorly understood. In this study, we investigate commonly used loss functions, deriving novel regret bounds that characterize when Bayes-optimal decisions for these objectives must diverge. Our results reveal a fundamental trade-off between the two objectives of (1) fingerprint similarity and (2) molecular retrieval. Optimizing for more accurate fingerprint predictions typically worsens retrieval results, and vice versa. Our theoretical analysis shows this trade-off depends on the similarity structure of candidate sets, providing guidance for loss function and fingerprint selection.

Figures & tables

Appendix figures & tables10 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. When should we trust the annotation? Selective prediction for molecular structure retrieval from mass spectra

    Mar 11, 2026Mira Jürgens, Gaetan De Waele, Morteza Rakhshaninejad +1Selective PredictionMass Spectrometry

  2. FlexMS: A Unified Public Benchmark for Molecule Tandem Mass Spectrum Prediction

    Feb 26, 2026Yunhua Zhong, Yixuan Tang, Yifan Li +5Benchmark DesignMass Spectrometry