cs.LGOct 31, 2026

HieraNTP: Structured Risk Representations for Time-Series Anomaly Detection via Hierarchical Next-Token Prediction

Authors: Yujie Li, Zezhi Shao, Boyu Diao, Zhulin An, Yongjun Xu, Xueqi Cheng, Fei Wang

Organizations: State Key Laboratory of AI Safety, Institute of Computing Technology, Chinese Academy of Sciences, Beijing, China · University of Chinese Academy of Sciences, Beijing, China

Abstract

Time-series anomaly detection commonly converts deviations from learned temporal regularities into anomaly scores. This practice can conflate violations of temporal regularity with task-specific anomaly judgments: the same deviation may be anomalous under one task definition and benign under another. Aggregating heterogeneous deviations into a single score before task-specific adaptation can obscure the evidence needed to distinguish these cases. We introduce HieraNTP, a Hierarchical Next-Token Prediction framework that separates self-supervised predictive modeling from task-specific risk interpretation. HieraNTP pretrains a hierarchical tokenizer and a causal next-token predictor to capture temporal regularities at multiple scales. It then organizes prediction discrepancies into a structured risk representation, preserving complementary evidence across temporal scales in token, local-statistic, and observation spaces. A task-adaptive detector uses anomaly labels to select and combine this evidence for the target task. Across anomaly detection benchmarks, HieraNTP improves VUS-PR by 12.0% on TSB-AD-U and 15.5% on TSB-AD-M relative to the strongest baselines, and achieves the highest composite score on both TAB tracks, with controlled comparisons supporting the value of retaining distinct evidence. Our code is available at https://github.com/blisky-li/HieraNTP.

Figures & tables

Appendix figures & tables21 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. LEAP: a Latent Embedding Anomaly Patch-Transformer for time-series anomaly detection

    Oct 26, 2026Cristhian Moya-Mota, Ignacio Aguilera-Martos, Diego García-Gil +1Time-Series Anomaly DetectionUnsupervised Anomaly Detection

  2. Generalist Representation, Specialist Detection: TS-Router for Time-Series Anomaly Detection

    Oct 1, 2026Tian Lan, Yifei Gao, Yimeng Lu +6Unsupervised Anomaly DetectionTime-Series Anomaly Detection

  3. LEFT: Learnable Fusion of Tri-view Tokens for Unsupervised Time Series Anomaly Detection

    Feb 9, 2026Dezheng Wang, Tong Chen, Guansong Pang +3Multi-View LearningUnsupervised Anomaly Detection