Towards Token-Level Text Anomaly Detection

Yang Cao, Bicheng Yu, Sikun Yang, Ming Liu, Yujiu Yang
1/20/2026
cs.CLcs.LG

Official code: charles-cao/TokenCore (4 stars, Apache-2.0, last commit 2025-11-24).

Abstract

Despite significant progress in text anomaly detection for web applications such as spam filtering and fake news detection, existing methods are fundamentally limited to document-level analysis, unable to identify which specific parts of a text are anomalous. We introduce token-level anomaly detection, a novel paradigm that enables fine-grained localization of anomalies within text. We formally define text anomalies at both document and token-levels, and propose a unified detection framework that operates across multiple levels. To facilitate research in this direction, we collect and annotate three benchmark datasets spanning spam, reviews and grammar errors with token-level labels. Experimental results demonstrate that our framework get better performance than other 6 baselines, opening new possibilities for precise anomaly localization in text. All the codes and data are publicly available on https://github.com/charles-cao/TokenCore.

View on arXivView PDF

Code Implementations(1)

Apache-2.0
40Python, Jupyter NotebookOct 29, 202511 months agoApache-2.0

Similar Papers

Cite this paper

@article{cao2026towards,
  title  = {Towards Token-Level Text Anomaly Detection},
  author = {Yang Cao and Bicheng Yu and Sikun Yang and Ming Liu and Yujiu Yang},
  year   = {2026},
  eprint = {2601.13644},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2601.13644v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2601.13644.svg)](https://codeofpaper.com/paper/2601.13644)

Discussion