Anomaly Detection using Source-Reversed Flow Matching

Amine Youcef Khodja, Jeremie Pantin, Gaël Dias, Fabrice Maurel


Abstract
Anomaly detection in textual data remains an underexplored problem, hindered by fragmented benchmarks, scarce labeled data, and methods that fail to model the distribution of normal text in a continuous and generative manner. We propose Flocat, an unsupervised approach that reformulates this task through a source-reversed flow matching paradigm: rather than learning to generate, we learn a flow from inlier text embeddings toward a compact isotropic Gaussian target, whose radius is explicitly constrained to ensure that the distance to the centroid serves as a geometrically consistent anomaly score. Built on a Diffusion Transformer (DiT) backbone, Flocat operates at both token and sentence level through a level-agnostic interpolation mechanism, enabling fine-grained signal interpretability. We evaluate on 10 datasets spanning text classification, spam detection, sentiment analysis, human- vs. machine-generated text and depression screening, consistently achieving state-of-the-art AUC-ROC across all benchmarks and text representations.
Anthology ID:
2026.emnlp-main.2322
Volume:
Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing
Month:
October
Year:
2026
Address:
Budapest, Hungary
Editors:
Hung-Yi Lee, Sunipa Dev, Jessy Li, Desmond Elliott
Venue:
EMNLP
SIG:
SIGDAT
Publisher:
Association for Computational Linguistics
Note:
Pages:
52746–52767
Language:
URL:
https://aclanthology.org/2026.emnlp-main.2322/
DOI:
Bibkey:
Cite (ACL):
Amine Youcef Khodja, Jeremie Pantin, Gaël Dias, and Fabrice Maurel. 2026. Anomaly Detection using Source-Reversed Flow Matching. In Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing, pages 52746–52767, Budapest, Hungary. Association for Computational Linguistics.
Cite (Informal):
Anomaly Detection using Source-Reversed Flow Matching (Khodja et al., EMNLP 2026)
Copy Citation:
PDF:
https://aclanthology.org/2026.emnlp-main.2322.pdf