De Novo Molecular Generation from Mass Spectra via Many-Body Enhanced Diffusion
Xichen Sun, Wentao Wei, Jiahua Rao, Jiancong Xie, Yuedong Yang
TL;DR
MBGen addresses de novo molecular structure generation from MS/MS spectra by introducing an edge-centric graph decoder with a many-body attention mechanism, integrated into a discrete diffusion process conditioned on a spectrum-derived fingerprint $y$. The approach uses a spectrum encoder (MIST-based) to produce $y$ and an edge-centric diffusion-based decoder to iteratively denoise a bond-graph, capturing higher-order bond interactions and intra-peak isomer information. Through a three-stage training paradigm—spectrum encoder pretraining, many-body decoder pretraining, and end-to-end finetuning—MBGen achieves state-of-the-art results on NPLIB1 canopus and MassSpecGym, with substantial gains in Top-1/Top-10 accuracy, MCES, and Tanimoto similarity, and robust isomer differentiation. Ablation and case studies confirm the value of the many-body coupling and pretraining strategy, demonstrating improved interpretability and performance in complex fragmentation scenarios.
Abstract
Molecular structure generation from mass spectrometry is fundamental for understanding cellular metabolism and discovering novel compounds. Although tandem mass spectrometry (MS/MS) enables the high-throughput acquisition of fragment fingerprints, these spectra often reflect higher-order interactions involving the concerted cleavage of multiple atoms and bonds-crucial for resolving complex isomers and non-local fragmentation mechanisms. However, most existing methods adopt atom-centric and pairwise interaction modeling, overlooking higher-order edge interactions and lacking the capacity to systematically capture essential many-body characteristics for structure generation. To overcome these limitations, we present MBGen, a Many-Body enhanced diffusion framework for de novo molecular structure Generation from mass spectra. By integrating a many-body attention mechanism and higher-order edge modeling, MBGen comprehensively leverages the rich structural information encoded in MS/MS spectra, enabling accurate de novo generation and isomer differentiation for novel molecules. Experimental results on the NPLIB1 and MassSpecGym benchmarks demonstrate that MBGen achieves superior performance, with improvements of up to 230% over state-of-the-art methods, highlighting the scientific value and practical utility of many-body modeling for mass spectrometry-based molecular generation. Further analysis and ablation studies show that our approach effectively captures higher-order interactions and exhibits enhanced sensitivity to complex isomeric and non-local fragmentation information.
