When Will It Fail?: Anomaly to Prompt for Forecasting Future Anomalies in Time Series
Authors: Min-Yeong Park
Won-Jeong Lee
Seong Tae Kim
Gyeong-Moon Park
Venue: ICML 2025 poster (2025)
Keywords: Time series forecasting
time series anomaly detection
Primary area: deep_learning->sequential_models_time_series
TL;DR: A2P: See anomalies before they strike!

Abstract: Recently, forecasting future abnormal events has emerged as an important scenario to tackle realworld necessities. However, the solution of predicting specific future time points when anomalies will occur, known as Anomaly Prediction (AP), remains under-explored. Existing methods dealing with time series data fail in AP, focusing only on immediate anomalies or failing to provide precise predictions for future anomalies. To address AP, we propose a novel framework called Anomaly to Prompt (A2P), comprised of Anomaly-Aware Forecasting (AAF) and Synthetic Anomaly Prompting (SAP). To enable the forecasting model to forecast abnormal time points, we adopt a strategy to learn the relationships of anomalies. For the robust detection of anomalies, our proposed SAP introduces a learnable Anomaly Prompt Pool (APP) that simulates diverse anomaly patterns using signal-adaptive prompt. Comprehensive experiments on multiple real-world datasets demonstrate the superiority of A2P over state-of-the-art methods, showcasing its ability to predict future anomalies.

When Will It Fail?: Anomaly to Prompt for Forecasting Future Anomalies in Time Series
Min-Yeong Park
Won-Jeong Lee 2 Seong Tae Kim
Gyeong-Moon Park
Abstract
Given signal Predicted signal
Unarrived signal
Recently, forecasting future abnormal events has emerged as an important scenario to tackle real- world necessities. However, the solution of pre- dicting specific future time points when anoma- lies will occur, known as Anomaly Prediction (AP), remains exper-ex Existing meth- ods dealing with time series data fail in AP, fo- cusing only immediate anomalies failing to provide precise predictions for future anoma- lies. To address the AP task, we propose a novel framework called Anomaly to Prompt (A2P), comprised of Anomaly-Awart Forecasting (AAF) and Synthetic Anomaly Prompting (SAP). en- able the forecasting model to forecast abnormal time points, adopt strategy to learn the re- lationships of anomalies. For the robust detec- tion of anomalies, our proposed SAP introduces a learnable Anomaly Prompt Pool (APP) that simulates diverse anomaly patterns using signal- adaptive prompt. Comprehensive experiments on multiple real-world datasets demonstrate the su- periority of A2P over ofate-ofthhe-ar methods, showcasing its ability predict future anoma- lies. Our implementation code is available at https::/ http://ggtttttt.t/e www/cu-ooo///. -U////UVVVGVAGIGG VGI/AP.
Detected anomaly
Forecasting
Anomaly Detection
Anomaly Prediction
(AP)
Figure Comparison among different scenarios of existing time series anomaly detection, forecasting, and a newly proposed anomaly prediction.
(Jhin et al., 2023) and (You et al., 2024), aiming to enhance preparedness for potential abnormal events in real-world scenarios. For example, it is greatly helpful for medical doctors to predict potential abnormalities based on patients' biomedical data because they can make decisions about their health in advance. Another example tenance of industrial systems where prediction of future abnormal events is crucial, since companies or users can minimize costs from abrupt system failure.
be the main-
The illustration of three different scenarios about time se- ries forecasting, time series anomaly detection (AD), and Anomaly Prediction (AP) depicted in Figure 1. In time series forecasting, model should predict how future sig- nals will look like, while in anomaly detection, model should detect abnormal time points from the given signal. In Anomaly Prediction, a model should detect anomalies in the predicted signal. This a more realistic and challenging scenario, which we are interested in this paper.
1. Introduction
As deep learning methods have evolved rapidly, their appli- cation to time series analysis has gained significant attention due to their critical importance in real-world scenarios. As part of this, recently, forecasting future abnormal events has been newly proposed in time series analysis, such as in
'Equal contribution 'Department of Artificial Intelligence, Kyung Hee University, Yongin, Republic of Korea DDeparmment of Artificial Intelligence, Korea University. Seoul, Republic of Korea. Correspondence to: Scong Tae Kim kim khu.ac.kr>, Gycong-Mooi Moon Park <gm- -art-park@@k mannk@kora..ccco kc.
Although there have been some recent attempts to detine the AP scenario in which model should predict future anomalies in (Jhin et al., 2023) and (You et al., 2024), they cannot meet the demands of the real world. (Jhin et al., 2023) can only detect if an anomaly likely to occur in the very near future, while failing to provide information on exact abnormal time points. In the real world, it crucial
Proceedings of the ndnd International Conference Machine Learning. Vancouver, Canada. PMLR 267, 2025. Copyright 2025 by the author(s).

---

When Will It Fail?
to predict possible future anomalies within more distant future, robustly against the various lengths of the future in which we are interested. However, existing works including (You et al., 2024) do not directly tackle the problems of Anomaly Prediction yet and also lack analysis on longer and various future lengths, limiting its applicability in the real world. To sum up, despite the significance of the AP scenario, how to predict the timing of abnormal events in the future is still under-explored.
Anomaly Prompt Pool (APP) to improve the robustness of anomaly detection. Anomaly prompts, which are learnable parameters, are utilized to intensify the diversity of signals used for reconstruction in the anomaly detection model, by capturing the characteristics of anomalies. We leverage a novel dignal-adaptive prompt tuning, with a specially de- signed loss term to guide signals to have abnormal features and an Anomaly Prompt Pool that contains instructions for transforming normal signals into anomalous ones. Further- more, we adopt shared backbone architecture that can learn unified representation, enabling forecasting and anomaly detection at once. This can remove the need for separate models, i.e., enhancing efficiency, and improves the overall performance, proven by our extensive experiments.
A straightforward combina- tion of existing sfate-of-the- art time series forecasting and anomaly detection methods may appear to be a natu- ral baseline for the AP task, where the anomaly detection model detects anomalies from predicted signals that are the outputs of the forecasting model. Figure 2 presents a comparison of AD, which de- tects anomalies from past sig- nals, and AP, which identifies anomalies from the predicted future signals using a combina- tion of time series forecasting and anomaly detection meth- ods. However, as shown in Figure 2, we empirically found that naive combination of the time series forecasting model and time series anomaly detection model fails at predict- ing future anomalies. The reason for this failure is quite intuitive: existing forecasting models are trained on only normal signals and predict them, thereby overlooking the prominence of abnormality in abnormal time points when predicting future signals. As a result, anomaly detection models fail at detecting anomalies because the forecasting models rather reduce the degree of abnormality of anomaly time points, which makes it difficult to detect them for anomaly detection models.
F1-Score
80
AD
75
70
Our main contributions can be summarized as follows:
65
For the first time, we introduce novel Anomaly to Prompt (A2P) method to address the Anomaly Predic- tion (AP) task, which aims to identify the time points at which abnormal events are likely to occur in the future based on the observed signals.
60
55
50
Figure Comparison of F1 F1-scores for existing time series anomaly detection task (AD) and Anomaly Prediction task (AP) the MBA dataset.
We propose an unprecedented method for forecasting time points with anomalies. To achieve this, we intro- duce Anomaly- Aware Forecasting (AAF) to endow the forecasting ability of future signals containing anoma- lies.
We propose a novel Synthetic Anomaly Prompting (SAP) method simulate anomalies with a novel loss objective train Anomaly Prompt Pool (APP), com- posed of set of learnable parameters. This method enables our model to effectively diversify training sig- nals through a novel signal-adaptive tuning method.
We conducted comprehensive experiments on various real-world datasets to show the effectiveness of our proposed method and demonstrate that our method outperforms the state-of-the-ar methods.
2. Related Work
To effectively resolve this challenging scenario, we propose a simple yet effective framework, Anomaly to Prompt (A2P), which is composed of Anomaly-Aware Aware Forecasting (AAF) and Synthetic Anomaly Prompting (SAP). AAF aims to consider the existence of anomalies in the train- ing process of forecasting. To achieve this, we utilize Anomaly-Aware Forecasting Network which is pre-trained before the main training to learn the probability of being an anomaly at a specific time point. By learning the relation- ship of anomaly signals, we solve the absence problem of abnormality in signals while forecasting, which hinders ex- isting forecasting models from tackling the AP task. Along with the method to endow the capability to forecast anoma- lous time steps, we introduce a novel SAP method with
Time Series Forecasting. Time series forecasting, which is the task of forecasting future signals based on historical observations, is important in terms of practicality in the real world. Previous works on time series have achieved strong prediction performance by leveraging advances in se- quence modeling machine learning methods and deep neural networks such as RNN (Hochreiter & Schmidhuber, 1997; Tokgöz& & Ünal, 2018; Abdel-Nasser & Mahmoud, 2019), GNN (Jiang & Luo, 2022; Wang et al., 2022b; Panagopou- los et al., 2021), and CNN (Bai et al., 2018; Livieris et al., 2020) to capture temporal dependencies. Recently, Trans- formers (Vaswami et al., 2017) have begun to be actively used for time series forecasting (Zhou et al., 2021; 2022:
2

---

When Will It Fail?
Wu et al., 2021; Liu et al., 2021; Cirstea al., 2022: Zhang & Yan, 2022; Nie et al., 2023; Zhou et al., 2023; Liu al., 2024; Xu et al., 2023). However, existing forecasting mod- els are trained on normal signals, neglecting anomalies, which leads to poor prediction of abnormal events. Ad- ditionally, these models require human interpretation for decision-makinn which is time-consuming. This paper presents novel approach to forecast abnormal events, pro- viding direct, practical insights for decision-making
3. Method
In this section, we formulate a novel scenario called Anomaly Prediction, to foresee potential anomalies in future signals in Section 3.1. Then, we explain the architecture of A2P, a unified shared backbone network to perform both forecasting and anomaly detection at once in Section 3.2. To tackle our challenging scenario effectively, in Section 3.3, we introduce a new approach called Anomaly-Aware Forecasting for more precise forecasting of abnormal time points. Furthermore, we propose a novel method coined Synthetic Anomaly Prompting which trains a newly pro- posed Anomaly Prompt Pool. Anomaly-Awar Forecasting Network and Anomaly Prompt Pool are jointly pre- pre-trained in advance of the main training where the shared backbone for both forecasting and anomaly detection is trained. Fi- nally, we summarize the total objective function in Section 3.5.
Time Series Anomaly Detection. Multivariate time series anomaly detection is a crucial problem for many applica- tions and has been widely studied. Most of the previous studies are mainly performed in unsupervised manner considering the restriction on access to abnormal data. Con- temporary works on time series anomaly detection can be divided into reconstruction-basse
approaches (Shen et al., 2021; 2020a; Li et al., 2019; Su et al., 2019b; Zhou et al., 2019; Yang et al., 2023; Shin et al., 2023) which find latent representations of normal time series data for reconstruction, and forecasting-
3.1. Scenario Description: Time Series Anomaly Prediction
approaches (Shen et al., 2020b; Si et al., 2023). Among them, (Xu et al., 2022) proposes new association- based method, which applies the learnable Gaussian kernel for better reconstruction. Another recent reconstruction-base based model DCdetector (Yang et al., 2023) achieves a similar goal in a much more general and concise way with a -ttentatennioon self-suuervised contrastive- ttype structure. Existing anomaly detection models identify past anomalies, limiting real- wellwworld applicability. In this paper, we tackle a more practical challenge: predicting anomalies in future signals for the first time.
Time series anomaly prediction is a scenario that aims to pinpoint the exact time steps of anomaly points in the upcoming signals. Specifically, for given input signal Xin E R 22xxxC the final goal is to obtain the binary results of anomaly detection O E Rhoue from the pre- dicted signal Xout E Ro where Lin and Lout are the lengths of the input and predicted signals, respectively, and C is the number of channels in the signal. To per- form anomaly prediction, we need a network for time series forecasting denoted as OF, and network for time series anomaly detection denoted as OAD. Therefore, O can be written O = AD (F(X.n) = θ AD (Xout). where Xout = O₂ (X..). For the evaluation of anomaly predic- tion performance, FI-score is used as existing time series anomaly detection methods do. The difference in the mea- surement from the existing methods is that the Point Ad- justment (PA) proposed in (Audibert et al., 2020) cannot be adopted in original way, since in anomaly prediction, it is important to identify specific time points. Therefore, we alleviate PA for our metric, which is explained in Section 4.
Predicting Future Anomalies. Recently, predicting whether anomalies are likely to occur in the future for time- series data has been studied in (Jhin et al., 2023) and (You et al., 2024). In (Jhin et al., 2023), Trecursor-of- offunooll- (PoA) detection is proposed which aims to detect future anomalies in advance. However, in PoA detection, the model can only know if any anomalies will occur in the near future or not. Therefore, it cannot be used in scenar- ios where identifying time steps with anomalies is crucial. In response to the need to predict the specific time points of anomalies in the future, (You et al., 2024) introduces Anomaly Prediction in which model is required to pinpoint abnormal time steps in the future. Although it formulated the AP scenario, it does not directly tackle its challenges. Related studies have been done in early accident anticipa- tion (Liao et al., 2024: Thakur et al., 2024) for autonomous driving as well. However, they focus detecting the possi- bility of an accident as early as possible within short video clip and cannot point out when the accident will happen in the future. Thus, there is no method that can solve AP yet. In this work, we first propose a method to deal with the problems of AP.
3.2. Unified Architecture for Anomaly Prediction
Both existing time series forecasting models such (Nie et al., 2023; Wang et al., 2022a; Zhou et al., 2023; Wu et al., 2021; Zhou et al., 2021; 2022; Liu et al., 2021) and anomaly detection models like (Xu et al., 2022; Yang et al., 2023) capture the representation of time series data. Inspired by this point, we adopt a shared backbone (0) to establish a unified architecture learn the representations of signals for both the forecasting and anomaly detection models at the same time, as shown in Figure 3.
3

---

When Will It Fail?
Specifically, in our framework, several base layers of trans- former blocks denoted as 0 are shared, while other specific parts, the embedding layers (ep and eAD) and output lay- ers (op and OAD) to construct Or and ADD exist sepa- rately, i.e,, F = {er,or 0) and AD = {eAD: OAD, 0). By sharing the backbone network, our model can accumu- late general knowledge for both time series forecasting and anomaly detection effectively, resulting in rich represen- tations and performance improvements. We analyze the effectiveness of the unified framework in Section 4.
is used for the loss term. As result, the final loss term for training Anomaly-Aware Forecasting Network in advance of the main training is follows:
LAAF (o (Attn( (At (X (x))); Cin ()))))) Vour); (1)
where is the activation function, sigmoid function, and Attn is the cross attention layer.
Synthetic Anomaly Prompting. To accurately predict anomaly points, forecasting the future signal from prior signal while considering the existence of anomaly points is crucial. To tackle this challenge, we propose novel ap- proach, named Synthetic Anomaly Prompting (SAP), which utilizes synthetic anomaly prompts for our model to predict future abnormal signals effectively. For SAP, we integrate a new Anomaly Prompt Pool (APP) into our unified architec- ture, as shown in Figure 3. The purpose of APP, which is a set of additional trainable parameters P, is to guide an input signal to behave like an abnormal signal, by infusing the anomaly prompts into the original embedding of the signal.
3.3. Pre- Tre-nrain of Anomaly-Aware Forecasting Network and Anomaly Prompt Pool
Anomaly-Aware Forecasting. We propose a novel method called Anomaly-Awart Forecasting (AAF), which improves the accuracy of future signal prediction by ex- plicitly accounting for anomalies in prior signals. Unlike traditional forecasting models that treat all past data equally, our approach incorporates an additional module improve robustness in dynamic and unpredictable environments. The Forecasting Net-
core of this method is the Anomaly- work, which is pre-trained to learn the complex relationships between prior signal anomalies and future trends. This pre- training step enables the network to anticipate how past anomalies might influence upcoming signals, thereby pro- viding more informed and accurate forecast during the main training phase.
In detail, APP is defined as P ((k1)P)). (k2, ... (kM.PM) where pm E &R4xDD and kn E IR. denote the m-th anomaly prompt and its corresponding key, respectively, L2 and D are the token length of single anomaly prompt and the embedding dimension, and M is the pool size, which is the number of total anomaly prompts in APP. Moreover, to select N best-matched prompts with the input signal X (X, = ADD(X in the pool, we introduce feature extractor (-), which is a simple three-layer transformer architecture with a [CLS] token, as a query function, i.e., (X*),, = [ (CT.S. The [CI.S] token is a learnable embedding used to capture global representations, and it helps to select the most relevant anomaly prompt in A2P, enabling effective abnormal feature synthesis.
The main purpose of AAF is to learn the relation between abnormal features inherent in prior signal and its following future signal. To this end, we exploit Anomaly-Aware Fore- casting Network which is composed of embedding layers, an attention layer, and an activation layer as shown in Figure Forecasting Network are
3. The inputs of Anomaly-Awan X and X which are the results of random anomaly injection among seasonal, global, trend, contextual, and shapelet anomaly types from Xout and X;.. respectively. For the detailed implementation of the injection, we adopt the scheme used in (Darhan et al., 2025). We first iden- tify where to inject these abnormalities by comparing each signal with its reconstruction output using frr,, which is pre-trained model, and focusing on the regions that yield the highest Mean Squared Error. Moreover, the magnitude of the injected abnormalities is treated as learnable pa- rameter, allowing the model to adaptively determine how much abnormality to inject at each identified location. The query for attention in Anomaly-Aware Forecasting Network is eowe (oue(XXur)) (X which is the target that we want to know about, while key and value are e (XY,), the ground for as- sessing the abnormality of X out. where Cout and ein refers to the embedding layers for X Yuu and X The output of the network is trained to indicate the probability of being an anomaly for each time step. This output is compared to ground truth label yiut of X² 2 and Mean Squared Error
The process of our proposed anomaly synthesis method us- ing APP is displayed in Figure 3. First, we pre-train the feature extractor (-) with the train set, which will be used to select the most relevant anomaly prompt from APP. After the training of s (-). it is frozen and used for the retrieval of features from signals. Second, we train Anomaly Prompt Pool with input data X which is the reconstructed output of Xin- The input signal passes through the feature extractor to obtain the query q( (- This query is then matched against the keys in the APP, and the prompts cor- responding to the top-N closest keys are attached to the embedded input X E LR... x D where X eA (XT)). Note that the synthesis of anomaly is executed at the embed- ding level, which enables more diverse prompting in high dimensions. Finally, the simulated embedding of anomaly in
X is defined as follows:
XP 122
= [Pe, :.. :PaNi XTr..
8, E
(2)
4

---

CD -KL((AAAX))) A(Xr)) D (ffer km). (4) Here, we obtain the reconstruction output XT, which plays role of pseudo-normal signal, where A is the first attention layer in 0. Then, the model attaches anomaly prompts from Anomaly Prompt Pool to pseudo-normal embedding X7, to simulate anomaly, which results in XP_ Since we aim to train APP to add abnormalities into the signal, the features of synthetic anomaly and pseudo-norma input features are trained to be distinct with LD. which serves to intensify the gap between the features of pseudo-norme normal feature and When Will It Fail?
Autt
X
X
Rour *o Nout Rout + Xaut
Lp
Xin
Forecasting N Network
fm
Xout
X
Caur
Claa
Anomaly-4e Hemualy-Aware Aware
X
CAAP
KAAP
VAAF
oou
LD
MSE Error
Muc
Cross-Attenton
X
Synthetic
Different
Inject Anomalyy
Sigmnad
Anomaly Prompting
Yut
Ancenaly Probubility
(SAP)
AAF
C MSE
Attention Map
X
oout
0000100001100
Anomaly Prompt Pool (APP)
Figure 3: Pre-training of Anomaly-Awe Aware Forecasting Network and Anomaly Prompt Pool. Our model first pre-trains trains Anomaly- Aware Forecasting Network and Anomaly Prompt Pool (APP) by injecting anomalies train data. After pre-training, Anomaly-Awe Aware Forecasting Network APP are frozen in the main training.
N Σ y ka))
synthetic anomaly feature. Note that after the pre-training phase, the proposed Anomaly-Aware Forecasting Network and APP are frozen.
S argmax where the score function 7 is the cosine similarity, which is for calculating how each anomaly prompt is related to each normal signal, and [ denotes the concatenation. The se- lected prompt tokens attached the input tokens of Xy after passing through the embedding layer CAD, trans- form the original normal signal into an abnormal signal. The output anomaly prompts are then removed before the final projection of each Of and OAD. to match the dimension.
(3)
(.:) CIIM
Forecasting Loss. Along with Anomaly-Awar Forecast- ing Network and APP, the forecasting model pre-trained to predict future time series with anomaly signals, as well as normal signals. The outputs of X,, and X from the forecasting model O which result in Xost and X= Xout re- spectively, are used pre-train Op via forecasting loss LF as follows:
To make the model detect more diverse anomalies, we pre-train the Anomaly Prompt Pool which holds the knowledge of characteristics of anomalies. The pre-trained APP can then be used infuse plausible anoma- lies later in the main training phase. For the efficient pre- training of APP, we introduce novel Divergence loss (L.) to guide the anomaly prompts in the APP to prompt the signals to function as anomalies, distinct from normal sig- nals. Along with a term to make abnormal signals, we add an additional term to pull the selected keys closer the corresponding features of normal signals as follows:
Divergence Loss.
1 CF - { Xove +
|
A= |
Xome (i)l))
(5)
3.4. Main Training
In the main training stage, the pre-trained Anomaly-Aware Forecasting Network, explained in section 3.3, used to out- put anomaly probability, indicated in Figure 4. Therefore, in the main training, the final loss term regarding forecasting is as follows:
CAF g(Xin Xoue) @ |Xour Xous |
(6)
where g(-) is Anomaly-Aware Forecasting Network, Xout is θ (Xin) and @ is element-wise multiplication. By con- sidering the errors in anomaly time steps more than other time steps, the network can be trained to focus on abnormal areas.
We employ additional loss term that aims to reconstruct X to its original normal form Xin, as follows:
CR = 2 (IIX.. - X.-" + X x2.11) (7)
5

---

When Will It Fail?
shown in Figure 5. First, the forecasted signal X out is obtained by forwarding the input signal Xin to 0r. Then the reconstructed output of Xout is obtained as X O₂ (Xout). Finally, the anomaly score for each time step is calculated using Xou and X% following the scheme of (Xu et al., 2022).
Anomaly-A Warre
Forecasting Network (g)
Simmold
Anomaly Probability
Cross-Attention
AF
Xin
Cout
MSE
4. Experiments
Ront Xout
Cp
OF
4.1. Experimental Setup
Frtr
L
Dataset Configurations. We evaluated our method on four real-world time series datasets: 1) MBA (MIT-BIH Supraventricular Arrhythmia Database) (Moody & Mark, 2001) is a set of electrocardiogram recordings from four patients, composed of two distinct types of irregularities (supraventricular contractions or premature heartheats). 2) Exathlon (Jacob et al., 2020) is set of real-world datasets collected using Apache Spark. It is comprised of eight sub- datasets, each dataset with 19 dimensions. 3) SMD (Server Machine Dataset) (Su et al., 2019a) is 5-week-long long dataset that was collected from large Internet company with 38 dimensions. 4) WADI (Water Distribution) (Ahmed et al., 2017) a distribution system comprising larger number of water distribution pipelines with 123 dimensions.
in
Anomaty
CAD
P by
OAD
Xn
Prompt
XP. in
Pool
Concatenation
Synthetic Anomaly Prompting (SAP)
Element- Wise Multiplication
Figure 4: Main Training of A2P. Only the shared backbone is trained during the main training, and others are frozen.
OF
X in
ep
Op
8 out
CAD
OAD
&oul
Baselines and Evaluation Metrics. We compared our model with various combinations of existing forecasting models and anomaly detection models, considering them as our baselines. For forecasting models, adopted state-of- the-art models, PatchTST (Nie et al., 2023), MICN (Wang et al., 2022a), GPT2 (Zhou et al., 2023), iTransformer (Liu et al., 2024), and FITS (Xu et al., 2023). Regarding anomaly detection models, we adopted reconstruction- basod meth- ods, moomllyTransfore
Anomaly Score
AD
Figure 5: Test time of Anomaly Prediction.
where XP- (O(P)( is the reconstruction out- in
put of synthesized abnormal input embedding and X AXm) is that of original normal input signal.
(Xu et al., 2022), DCDetector (Yang et al., 2023), and CAD (Si et al., 2023). We con- ducted additional baseline experiments, which are described in Appendix C.3. We used F1-score (F1) as the main eval- uation metric. If not mentioned, the scores reported in the tables indicate F1 F1-scores. In addition, F1-score was calcu- lated without point adjustment introduced in (Audibert et al., 2020). Instead, we used F1- F1-score with tolerance which denotes the time window within which errors tolerated in anomaly detection. For example, when model predicts that time step is an anomaly, the real ground-truth anomaly time points from [i - t, + are considered to be correctly detected before the calculation of F1-score.
3.5. Total Objective Function
The total objective function of our proposed framework is summarized follows:
Lrotal dAAFLAFF + ADLD XFLe for PT, A + DAPLAP
for MT,
(8) where PT and MT mean pre-training and main training, respectively, and À = [AAAF, Ap, XF, AR, >AF) } is a set of coefficients for weighting each loss term. We set all five coefficients to default values during whole experiments.
Hy Hyperparameters. periments are mentioned in Appendix A.2, and the sen- sitivity results on various parameter values are shown in Appendix
The hyperparameters used in our ex-
3.6. Test Time
In the test time for the evaluation of A2P, only the shared backbone is utilized and other modules are discarded as
6

---

When Will It Fail?
Table Anomaly Prediction results on multivariate cases Lin results are highlighted.
100, averaged over random seeds. The best and second bestt
Model
Dataset
Lout
Avg. Fl
AD
MBA
Exathlon
SMD
WADI
AT
55.0513.75
18,10:0..44
34.32:10.50
58.02:1:3995
41.37
P-TST
DC
59.59+33.94
17.21+00.17
23.01=55.31
18.50=#13.9
29.08
CAD
53.75:10.11
18.10:10.36
25.55=10.10
54.33+22.10
37.93
AT
38.84+144885
17.30+1.22
34.06+1.38
54.51+3.99
36.18
MICN
DC
17.90
17.35::1.19
3.6
10.21
29.82
CAD
57.42+0.52
5.19+0.44
18.17+1.90
18.45+7.227
24.81
AT
49.20
17.83:13.20
29.49-12.46
59.88:17.03
39.60
100
GPT2
DC
55.13+
9.66+0.74
31.23++.98
21.56+7.50
29.90
CAD
16.64+8.77
1..3
8.14++0557
26.97+2.53
17.77
AT
54.72::5.35
17.82++0.81
32.75=0088
54.54++8228
39.96
iTransformer
DC
53.07+:5.30
12.98:+3.73
13.47=66.62
13.65+12.82
23.29
CAD
39.76:16.38
16.94110.88
25.69
24.36:11.60
26.69
AT
5..31
17.7412.88
32.65
60.30:1-4.46
39.55
FITS
DC
61.39:14.89
17.38+3326
32.45=1.227
52.96:16.11
41.55
CAD
23.72:19.43
10.87+00.06
33.15
28.93:::.445
24.67
A2P (Ours)
5.65
18.64+0.16
0.12
64.91+10.47
46.84
AT
51.25
17.65410.31
34.07
55.2411.62
39.55
P-TST
DC
59.04+33.69
16.23++0.50
13.42-45.38
7.36+
24.01
CAD
16.87+15.21
16.28400.1
6.71+
31.69+ 1.41
17.89
AT
56.57+12.90
17.30+0.009
3..44=t1.81
55.24+3.87
40.64
MICN
DC
57.80
17.4140.34
30.32-22.13
56.24+1.13
40.94
CAD
50.46:10.82
2.4410007
6.36:10.23
32.75+:2.00
23.00
AT
49.29:12.55
17.64.10.54
35.12:10.90
59.35:14.34
40.35
200
GPT2
DC
55.44
10.25++0.12
9.77+4.667
26.1443.100
25.09
CAD
2..2411.77
15.40:10.13
7.42:10.77
27.87+2.11
19.73
AT
54.13+00.08
17.88+0.11
27.26+66011
48.72+-9.47
37.50
iTransformer
DC
52.53:7.47
14.8610.005
3.65
14.45+20.44
21.87
CAD
21.14+-..35
16.58+00.8
7,66+00.3
30.37+22.39
18.44
AT
27.85-12.07
17.88-10.26
35.70-1.22
64.10:1..22
41.38
FITS
DC
51.21+7.66
17.56++0.21
+..57
53.60+33449
38.02
CAD
51.44++14.45
10.04+0..4
9.32+0.70
32.75+-2.000
25.39
A2P (Ours)
5.992
2..71++0.54
4..36
66.65 1.93
53.08
AT
47.25+111.15
17.30+40.49
26.56=1.50
56.05+11.33
36.79
P-TST
DC
56.89+8.21
16.65+0..2
84.55=8.778
47.36+t
33.36
CAD
20.04
13.40:1.31
3.75
20.22:10.78
14.35
AT
57.81+1.577
17.37+0.75
35.71++0.10
53.83++
41.18
MICN
DC
56.08-15.30
17.4910.49
29.95
57.80-13.88
40.83
CAD
21.12++1.8
13.40+0.10
3.86+0.10
5.02++0.26
10.85
AT
50.31 40
17.53-10.89
32.89-3.449
52.86-16.447
38.90
400
GPT2
DC
57.70+ 10.28
9.49+3.29
3.89++3.06
15.16+ 1.80
21.06
CAD
3.57+2.25
11.07+44.22
4.14++0.2
11.07+44.22
7.96
AT
49.14
17.41+0.77
32.89-t3.49
53.17++5.58
38.15
iTransformer
DC
49.72:t4.23
15.46:+0.22
12.61=7.20
10.7=
21.84
CAD
24.87-1.002
12.3741..13
3.58
40.23-18.44
12.76
AT
46.60:15.77
18.03:10.95
22.99
56.66.1..88
38.20
FITS
DC
54.32+111.29
17.66::0.22
23.83++11.40
15.12+
35.73
CAD
66.33
7.50+0.56
4.95:t0.12
22.60:t:0008
25.84
A2P (Ours)
79.5
43.57++1.10
48.10-22.55
74.57-+6.37
58.89

---

When Will It Fail?
Anomaly Threshold. The threshold for deciding anoma- lies from anomaly scores is set by following the widely accepted protocol from (Shen et al., 2020a), adjusting for percentage of anomalies in the test data. This approach ensures consistency with established standards for anomaly detection tasks.
Table 2: Ablation the proposed AAF and SAP, when
Lin
Lout
100.
AAF
SAP
MBA
Exathlon
SMD
WADI
Avg.
x
x
36.26
17.65
34.74
58.66
36.82
V
X
40.95
17.76
34.87
61.98
38.89
X
55.95
18.29
36.05
59.36
42.41
67.55
18.64
36.29
64.91
46.84
4.2. Anomaly Prediction Results
Table Ablation of loss terms LD and Cr used in pre-training.
The results of the Anomaly Prediction experiments are demonstrated in Table For the Fl-score, our model con- sistently outperforms the baselines, showing the effective- ness of our proposed Anomaly-Aware Forecasting and Syn- thetic Anomaly Prompting. Note that ours were effective in datasets from various domains, which implies that our methods are robust to the various statistics of datasets.
Cp
Cp
MBA
Exathlon
SMD
WADI
Avg. Fi
40.95
17.76
34.87
61.98
38.89
/
50.57
17.91
34.92
62.31
41.42
65.19
17.91
35.17
63.25
45.38
67.55
18.64
36,29
64.91
46.84
Table 4: Ablation for the shared transformer backbone.
Shared
MBA
Exathlon
SMD
WADI
Avg. F1
4.3. Ablation Study
x
51.53
18.00
35.60
60.70
41.45
67.55
18.64
36.29
64.91
46.84
AAF and SAP. To further examine the effectiveness of our novel methods, we thoroughly conducted ablation stud- ies. The ablation results of AAF and SAP are indicated in Table 2 to see the impact of each method. As shown in Table 2, 1) utilizing the knowledge of the relationship among anomaly signals and 2) synthesizing anomalies at the embedding level in learnable way improved Anomaly Prediction performance, respectively.
Table 5: Ablation for the use of anomaly probability in main training.
Forecasting Loss
MBA
Exathlon
SMD
WADI
Avg. Fl
MSE
64.20
18.24
36.13
59.19
44.44
MSE @ AN. Prob.
67.55
18.64
36.29
64.91
46.84
Table 6: Forecasting performances evaluated by MSE of forecasting models and A2P (Ours) on the MBA dataset.
Pre-training Loss Ablation. Table 3 demonstrates the ablation of two loss terms used in the pre-training phase. For training the backbone, utilizing Er and our proposed Lo both contributed to significant performance enhancement. Especially, the Divergence loss (CD) alone improved about 24% of its performance the MBA dataset, emphasizing the effectiveness of LD for the robust reconstruction of time series data from various abnormal features.
Lout
100
200
400
PatchTST
1.174
1.261
1.272
MICN
1.012
1.017
1.041
GPT2
1.021
1.096
1.100
iTransformer
1.140
1.256
1.279
FITS
1.495
1.844
2.390
A2P (Ours)
0.788
0.864
0.930
4.4. Analysis
Shared Backbone. In order to investigate the impact of sharing transformer layers between the forecasting model and the anomaly detection model, we conducted ablation experiments regarding the effectiveness of the shared back- bone as demonstrated in Table 4. Sharing the layers of backbone for forecasting and anomaly detection remark- ably enhanced the performances, implying that sharing the knowledge of forecasting and anomaly detection helped to enrich the representation learning of time series signals.
Results on Forecasting. As shown in Table 6, our pro- posed A2P was advantageous at predicting more accurate future signals. The performance improvements in not only Anomaly Prediction but also forecasting indicate that our proposed approaches contributed to learning the representa- tions of both normal and abnormal signals effectively, com- pared to the baseline. Notably, when Lout was significantly longer, our proposed A2P outperformed forecasting future signals with anomalies, indicating the capability of handling long-term signals.
Using Anomaly Probability for AAF. To investigate the effectiveness of using anomaly probability for training the forecasting model in main training phase, we ablated the use of anomaly probability in Table 5. Using weighted loss term AF notably enhanced the performance of AP compared to using traditional forecasting loss, indicating considering anomaly probability forecasting process is effective.
Qualitative Results Anomaly Prediction. To further examine the effectiveness of our method, we visualized the time series signals as shown in Figure 6. As shown in the figure, our proposed A2P successfully forecasted the signal whereas our baseline, the naive combination of PatchTST and moomllyrranfoome failed. Our proposed
8

---

When Will It Fail?
A2P achieved average 10% improvement in performance the baseline, demonstrating favorable trade-off be- tween cost and accuracy. Moreover, the train time consumed is utmost hour in WADI dataset, which is negligible and is not really a heavy burden for A2P to be applied real-world scenarios.
Potdris
AZPiCum)
Signal
ny to 1
Anumaly Score
5. Conclusion
Signal
In this paper, first addressed a solution to Anomaly Pre- diction (AP), where the model needs to detect abnormal time points from unarrived future signals. We tackle AP by employing synthetic anomalies train time, whereas traditional time series forecasting and anomaly detection models were trained with only normal signals, limiting their generalizability abnormal signals. We proposed two ef- fective approaches, Anomaly-Aware Forecasting (AAF) and Synthetic Anomaly Prompting (SAP). In AAF, we designed Anomaly-Aware Forecasting Network to help the model forecast time steps with anomalies. In SAP, we defined APP which learns how to prompt the input signals to have anoma- lous features. We achieved state-of-the performances on the AP task in various real-world datasets, demonstrating the effectiveness of our methods through comprehensive experiments. We hope pioneering attempt to predict future anomalies provides an opportunity to anticipate po- tential breakdowns, while also opening up a new direction for research.
NeestsT AT
A3P10ura)
Figure 6: Ground-truth and predicted signals of MBA dataset from the baseline and A2P (top), with corresponding anomaly scores (bottom). The black dotted line represents the threshold of anomaly scores, and red-shaded area indicates time step with anomalies.
1e6
Number of Parameters
3.5
2.5
Eeathlon
A Acknowledgement
2.0
WAD
PatchtSSi +A
This work supported by Korea Planning & Evalua- tion Institute of Industrial Technology (KEIT) grant funded by the Korea govermment (MOTIE) (RS- 44400444-004444444 and in part by Institute of Information & communications Technology Planning & Evaluation (IITP) grant funded by the Korea government (MSIT) (No. 15--0019-1119007) Artificial Intelligence Graduate School Program (Korea Uni- versity), and No. RS-2024-00457882, Al Research Hub Project).
(Ouns)
10
20
40
50
GFLOPs
Figure 7: Comparison of GFLOPs and the number of parameters.
A2P predicted the abnormal events appropriately, and led
successful anomaly detection.
Impact Statement
This paper presents research aimed for the advance Ma- chine Learning by contributing novel methodologies for predicting future anomalies from unarrived time series data, Our work has the potential influence various domains which utilize time series data, including artificial intelli- gence, data science, and automated decision-making While we recognize that any progress in time series analysis may have broad societal implications--anginn from ethical considerations to real-world applications industry and academia we do not identify any specific consequences that warrant particular emphasis this time. However, encourage further discussion and evaluation of the broader impact as the field continues to evolve.
Computational Complexity. To investigate the impact of additional computational complexity of our proposed methods, we measured GFLOPs per iteration (including both pre-training and main training) and the total number of parameters of the baseline (combination of PatchTST and and our proposed A2P. As shown in the Figure A2P does require additional computation compared to the baseline. However, since our model uni- fies both forecasting and anomaly detection within single framework, it significantly reduces the overall parameter footprint. More importantly, this additional cost only in- curred during training, with no extra overhead at inference time. Despite the modest increase in training complexity,
GoomallTransformen

---

When Will It Fail?
References
Jiang, W. and Luo, J. Graph neural network for traffic forecasting: A survey. Expert Systems with Applications, 207:1 2022.
Abdel-Nasser, M. and Mahmoud, K. Accurate photovoltaic power forecasting models using deep Isnm-rnn. Neural computing and applications, 31:2727-2740, 2019.
Kingma, D. P. and Ba, J. Adam: A method for stochastic optimization. ICLR, 2015.
Abdulaal, A., Liu, Z., and Lancewicki, T. Practical ap- proach asynchronous multivariate time series anomaly detection and localization. In Proceedings of the 27th ACM SIGKDD conference on knowledge discovery & data mining, pp. 2485-2494, 2021.
Li, D., Chen, D., Jin, B., Shi, L.., Goh, J., and Ng. S.-K. Mad- gan: Multivariate anomaly detection for time series data with generative adversarial networks. In International conference on artificial neural networks, pp. 703-716. Springer, 2019.
Ahmed, C. M., Palleti, V. R., and Mathur, A. Wadi: water distribution testbed for research in the design of secure cyber physical systems. In Proceedings of the 3rd international workshop on cyber-physice, systems for smart water networks, pp. 25-28, 2017.
Liao, H., Li, Y., Wang, C., Guan, Y., Tam, K., Tian, C., Li, L., Xu, C., and Li, Z. When, where, and what? a novel benchmark for accident anticipation and localization with large language models. arXiv preprint arXiv:2407.16277 2024.
Audibert, J., Michiardi, P., Guyard, F., Marti, S., and Zu- luaga, M. A. Usad: Unsupervised anomaly detection on multivariate time series. In Proceedings of the 26th ACM SIGKDD international conference on knowledge discovery & data mining, pp. 3395-3404, 2020.
Liu, S., Yu, H., Liao, C.,, Li, J., Lin, W., Liu, A. X., and Dustdar, S. Pyraformer: Low Low-complexity pyramidal atten- tion for long-range time series modeling and forecasting. International conference on learning representations, 2021.
Bai, S., Kolter, J. Z.,, and Koltun, V. An empirical evalua- tion of generic convolutional and recurrent networks for sequence modeling. arXiv preprint arXiv: 1803.0127,, 2018.
Liu, Y., Hu, T., Zhang, H., Wu, H., Wang, S., Ma, L., and Long, M. itransformer: Inverted transformers effective for time series forecasting. ICLR, 2024.
Cirstea, R.-G., Guo, C., Yang, B., Kieu, T., Dong, X., and Pan, S. Triformer: Triangular, variable-specific attentions for long sequence multivariate time series forecasting- full version. IJCAI, 2022.
Livieris, I. E., Pintelas, E., and Pintelas, P. A cnn-lstm model for gold price time-series forecasting. Neural computing and applications, 32:17351-1736/ 2020.
Mathur, A. P. and Tippenhauer, N. O. Swat: A water treat- ment testbed for research and training on ics security. In 2016 international workshop cyber-physical systems for smart water networks (CySWater), pp. 31-36. IEEE, 2016.
Darban, Z. Z.,, Webb, G. I., Pan, S., Aggarwal, C. C.,, and Salehi, M. Carla: Self-supervised contrastive representa- tion learning for time series anomaly detection. Pattern Recognition, 157: 1 2025.
Hochreiter, and Schmidhuber. Long short-term memory. Neural computation, 9()):1335-178) 1997.
Moody, G. B. and Mark,
R. G. The impact of the mit-bih arrhythmia database. IEEE engineering in medicine and biology magazine, 20(3):4-50,, 2001.
Hundman, K., Constantinou, V., Laporte, C., Colwell, I., and Soderstrom, T. Detecting spacecraft anomalies us- ing Istms and nonparametric dynamic thresholding. In Proceedings of the 24th ACM SIGKDD international con- ference on knowledge discovery data mining, pp. 387- 395, 2018.
Nic, Y., Nguyen, N. H., Sinthong, P., and Kalagnanam, J. A time series is worth 64 words: Long-term forecasting with transformers. ICLR, 2023.
Panagopoulos, G., Nikolentzos, G., and Vazirgiannis, M. Transfer graph neural networks for pandemic forecast- ing. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pp. 4838 4845, 2021.
Jacob, V., Song, F., Stiegler, A., Rad, B., Diao, Y., and Tatbul, N. Exathlon: A benchmark for explainable anomaly detection over time series. arXiv preprint arXiv:2010.05073. 2020.
Paparrizos. J., Boniol, P., Palpanas, T., Tsay, R. S., Elmore, A., and Franklin, M. J. Volume under the surface: a new accuracy evaluation measure for time-series anomaly detection. Proceedings of the VLDB Endowment, 15(11): 2774-2787, 2022.
Jhin, S. Y., Lee, J., and Park, N. Precursor-of-anome detection for irregular time series. In Proceedings of the 29th ACM SIGKDD Conference on Knowledge Discovery and Data Mining, pp. 917-929, 2023.
10

---

When Will It Fail?
Paszke, A., Gross, S., Massa, F., Lerer, A., Bradbury, J., Chanan, G., Killeen, T., Lin, Z., Gimelshein, N., Antiga, L., et al. Pytorch: An imperative style, high-performance deep learning library. Advances in neural information processing systems, 32, 2019.
Tuli, S., Casale, G., and Jennings, N. R. Tranad: Deep trans- former networks for anomaly detection in multivariate time series data, arXiv preprint arXiv:2201.0728/ 2022.
Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, E., and Polosukhin, At- tention is all you need. Advances in neural information processing systems, 30, 2017.
Shen, L., Li, Z., and Kwok, J. Timeseries anomaly detection using temporal hierarchical one-class network. Advances in Neural Information Processing Systems, 33:13016- 13026, 2020a.
Wagner, D., Michels, T., Schulz, F. C.,, Nair, A., Rudolph, M., and Kloft, M. Timesead: Benchmarking deep multi- variate time-series anomaly detection. Transactions on Machine Learning Research, 2023.
Shen, L., Li, Z., and Kwok, Timeseries anomaly detection using temporal hierarchical one-class network. Advances in Neural Information Processing Systems, 33:13016- 13026, 2020b.
Wang, H., Peng, J., Huang, F., Wang. J., Chen, J., and Xiao, Y. Mien: Multi-scale local and global context model- ing for long-term series forecasting. In The Eleventh International Conference Learning Representations, 2022a.
Shen, L., Yu, Z., Ma. Q. and Kwok, J. T. Time series anomaly detection with multiresolution ensemble decod- ing. In Proceedings of the AAAI Conference on Artificial Intelligence, volume 35, pp. 9567-9575, 2021.
Wang. I.., Adiga, A., Chen, J., Sadilek, A., Venkatramanan, S., and Marathe, M. Causalgnn: Causal-based graph neural networks for ing. In Proceedings of the AAAI conference on artificial intelligence, volume 36, pp. 12191-12199 2022b.
Shin, A.,.., Kim, S. T., and Park, G.-M. Time series anomaly detection using transformer-based gan with two- step masking. IEEE Access, 11.74035-74047, 2023.
epidemic forecast-
Si, H., Pei, C., Li, Z., Zhao, Y., J., Zhang, H., Diao, Z., Li, J., Xie, G., and Pei, D. Beyond sharing: Conflict- aware multivariate time series anomaly detection. In Proceedings of the 31st ACM Joint European Software Engineering Conference and Symposium on the Founda- tions of Software Engineering, pp. 1635-1645, 2023.
Wu, H., Xu, J., Wang. J., and Long, M. Autoformer: Decom- position transformers with auto-correlation for long-term series forecasting. Advances in neural information pro- cessing systems, 34:22419-2244 2021.
Xu, J., Wu, H., Wang, J., and Long, M. Anomaly trans- former: Time series anomaly detection with association discrepancy. ICLR, 2022.
Su, Y., Zhao, Y., Niu, C., Liu, R., Sun, W., and Pei, D. Robust anomaly detection for multivariate time series through stochastic recurrent neural network. In Proceed- ings of the 25th ACM SIGKDD international conference on knowledge discovery & data mining, pp. 2828-28 2837, 2019a.
Xu, Z., Zeng, A., and Xu, Q. Fits: Modeling time series with 10k parameters, arXiv preprint XiXi::2377.07766 2023.
Yang, Y., Zhang, C., Zhou, T., Wen, Q. and Sun, L. Dede- tector: Dual attention contrastive representation learning for time series anomaly detection. In Proceedings of the 29th ACM SIGKDD Conference on Knowledge Discovery and Data Mining, pp- 3033-3045, 2023.
Su, Y., Zhao, Y., Niu, C., Liu, R., Sun, W., and Pei, D. Robust anomaly detection for multivariate time series through stochastic recurrent neural network. In Proceed- ings of the 25th ACM SIGKDD international conference on knowledge discovery & data mining, pp. 2828-288888 2837, 2019b.
You, J., Cela, A., Natowicz, R., Ouanounou, J., and Siarry, P. Anomaly prediction: A novel approach with explicit delay and horizon. In 2024 IEEE 20th International Conference on Intelligent Computer Communication and Processing (ICCP), pp. 1-8, IEEE, 2024.
Thakur, N., Gouripeddi, P., and Li, B. Graph (graph): A nested graph-based framework for early accident antici- pation. In Proceedings of the IEEE/CVF Winter Confer- ence on Applications of Computer Vision, pp. 7533-7541, 2024.
Zhang, H., Wang. 7.,, Zeng, D., Wu, 7., and Jiang, Y.-G. Diffusionad: Norm-guided one-step denoising diffusion for anomaly detection. IEEE Transactions on Pattern Analysis and Machine Intelligence. 2025.
Tokgöz, A. and Ünal, G. A rnn based time series approach for forecasting turkish electricity load. In 2018 26th Signal processing and communications applications con- ference (SIU), pp. 1-4, IEFE, 2018
Zhang, Y. and Yan, J. Crossformer: Transformer utilizing cross-dimension dependency for multivariate time series

---

When Will It Fail?
forecasting. In The eleventh international conference learning representations, 2022.
Zhou, B., Liu, S., Hooi, B., Cheng, X., and Ye, J. Beatgan: Anomalous rhythm detection using adversarially gener- ated time series. In IJCAI, volume 2019, pp. 4433-4439, 2019.
Zhou, H.. Zhang. S., Peng, J., Zhang, S., Li, J., Xiong, H., and Zhang. W. Informer: Beyond efficient transformer for long sequence time-series forecasting. In Proceedings of the AAAI conference on artificial intelligence, volume 35, pp. 11106-1111,, 2021.
Zhou, T., Ma, Z., Wen, Q. Wang, X., Sun, L., and Jin, R. Fedformer: Frequency enhanced decomposed trans- former for long-term series forecasting. In Interna- tional conference machine learning. pp. 27268-2722 PMIR, 2022.
Zhou, T., Niu, P., Sun, L., Jin, R., al. One fits all: Power general time series analysis by pretrained Im. Advances in neural information processing systems, 36:43322 43355, 2023.
12

---

When Will It Fail?
A. Additional Information
A.I. Notations
Table 7: Categorized notations.
Symbol
Description
Lin
Length of input signal
Lout
Length of forecasted signal
C
Dimension of time series data
Dimension
M
Number of anomaly prompts in Anomaly Prompt Pool
N
Number prompts to attach in Synthetic Anomaly Prompting
L
Length of single token of anomaly prompt
D
Embedding dimension
0
Shared transformer blocks
er
Emhedding layer for forecasting Embedding layer for anomaly detection
CAD
OF
Projection layer for forecasting Projection layer for reconstruction Forecasting network
Parameters
OAD
OF
+ AD
Anomaly detection network
for
Feature cxiractor for obtaining class token Set of parameters of Anomaly Prompl Pool Ground truth prior time series
X
Xout
Ground truth posterior time series
X
Time series after injecting random anomaly to Xin Time series after injecting random anomaly to Xout Forecasted time series from Xin Forecasted time series from X Reconstructed oulput of X Reconstructed output of X
x out
Signal
X out
X
X
Xp
Xr
Reconstructed output of X
X on
Embedding feature of X
Feature
X
Embedding feature of prompted anomaly
X
Embedding feature of X
Eic.
Vou
Ground truth anomaly label of X out
A.2. Training Details
For all models, we trained all models using Standard scaler, Adam optimizer (Kingma Ba, 2015) with 31 0.9 B3 0.999, a batch size of 16, and a constant learning rate 0.0001 for all settings. We used the length of input sequence Li. 100 for all settings. Also, we conducted experiments varying the length of output sequence Lout from 100 400. For Synthetic Anomaly Prompting, 10, respectively, as default. In the selection of top-N N anomaly prompts in anomaly prompt pool, we used N 3. We trained the models for epochs, with 3 layers of transformer backbone, and the embedding dimension D is fixed to 256. Also, our experiments were executed on single GPU (NVIDIA RTX 3090), implementation library (PyTorch (Paszke et al., 2019)) for fair and exhaustive comparison. Regarding the anomaly detection model for Anomaly Prediction, we set the window size of 100, and used sliced predicted signals obtain the output of anomaly detection in experiments, including all comparing methods.
adopted the length of anomaly prompts L, and the size of anomaly prompt pool 5 and
A.3. Dataset Details of the Anomalies
Table 8 provides detailed information about the anomaly configurations of the datasets.
13

---

When Will It Fail?
Table 8: Statistics Anomalies the Dataset.
Avg.
Avg.
of Anomaly Seg.
# of Anomaly Seg.
Dataset
of Anomaly Seg.
# of Batches
Anomaly Ratio (56)
Anomaly Len.
/# Total Sample
Anomaly Sample
MBA
33.80
29.48
86
1.14
1.18
Exathlon
12.69
91.94
1091
8911
0.12
1.00
SMD
4.15
47.26
623
7083
0.08
1.00
WADI
4.88
62.19
27
344
0.07
1.00
Table Ablation for the type loss used in Anomaly-Aware Forecasting Network.
Type
MBA
Exathlon
SMD
WADI
Avg. Fl
BCE
66.75
17.91
34.82
64.21
45.92
MSE
67.55
18.64
36.29
64.91
46.84
Table 10: Anomaly Prediction results datasets that excluded in the main paper with Lin Lout 100, averaged over 3 random seeds. best and second-hest. results are highlighted.
Model
Datasct
Avg. Fl
F
AD
MSL
PSM
SWaT
SMAP
AT
41.96++0.97
13.74+10.5
11.29+0.17
14.97+0.16
20.49
P-TST
DC
39.93:11.20
13.8811030
7.2712.09
13.91
18.75
CAD
17.99+0.25
3.26=0004
16.65+1.18
3.76+1011
10.42
AT
39.9111.339
14.04
11.68
14.74:10.67
20.09
MICN
DC
41.05+0.51
13.87+0.51
11.85+0.33
15.14
20.47
CAD
3.82+0005
2.75=0000
6.13+1.33
1.62+00.03
3.58
AT
41.91+2.73
13.89+0046
11.18+0.46
15.34400.73
20.58
GPT2
DC
39.31
10.3115.67
11.00#1.15
9.89
17.63
CAD
2.08
3.65=0.31
6.76+00.1
9.17
5.41
AT
42.3510.75
13.8340.96
11.1810.46
15.87+1024
20.82
iTransformer
DC
39.95+
13.46+00.4
4.92+
15.54+0.33
18.47
CAD
4.49
3.80=0.40
13.10
3.71
6.28
AT
12
13.79+0.32
11.34+0.49
15.35++0.55
20.60
FITS
DC
41.72.11.39
13.65110.61
9.24+1.666
14.21110.34
19.70
CAD
7.5640034
7.87=0.40
16.4740.02
4.67+0.27
9.14
A2P (Ours)
46.87+00.6
15.28-0.009
15.74+0.35
16.31+0.11
23.55
B. Loss Ablation of Anomaly-Aware Forecasting Network
We also ablated the loss term used for training Anomaly-Ave Aware Forecasting Network, as indicated in Table 9. When Binary Cross Entropy loss was used, the performance was suboptimal. The result implies that driving anomaly probability to be continuous (MSE) rather than discrete (BCE) is better learn Anomaly-Aware Forecasting Network effectively. For this reason, finally adopt MSE instead of BCE to learn anomaly probability in AAF.
C. Quantitative Results
C.1. Experiment on other datasets
Aside from the datasets that were included in the main paper, there are datasets mainly used for the evaluation of time series anomaly detection such as MSL, SMAP (Hundman et al., 2018), PSM (Abdulaal et al., 2021), and SWaT (Mathur Tippenhauer, 2016). However, they are not appropriate for the evaluation of anomaly detection task due the soundness
14

---

When Will It Fail?
Table Anomaly Prediction results evaluated using VUS-PR and VUS-ROC with Lout 100, averaged over random seeds. The best and second-best results are highlighted.
Model
Lou!
Avg.
100
200
400
F
AD
V-PR
V-ROC
V-PR
V-ROC
V-PR
V-ROC
V-PR
V-ROC
AT
68.28
71.47
67.87
72.86
66.99
79.54
67.71
74.62
P-TST
DC
68.52
72.11
67.
71.31
67.84
70.25
67.93
71.22
CAD
55.26
68.07
57.98
71.94
56.96
70.55
56.73
70.19
68.20
71.47
67.80
78.79
67.09
80.55
67.70
76.94
MICN
DC
68.55
72.31
67.89
70.93
67.96
71.44
68.13
71.56
CAD
67.30
78.31
67.93
80.12
60.48
73.36
65.24
77.26
AT
68.24
71.85
67.61
76.61
66.95
75.70
67.60
74.72
GPT2
68.37
75.16
67.82
71.95
68.50
74.18
68.23
73.76
CAD
57.73
68.41
55.58
69.02
55.08
65,85
56.13
67.76
AT 67.95
72.87
66.90
80.38
66.72
80.04
67.19
77.76
TTransformer
DC
68.11
71.72
67.67
70.49
67.83
70.61
67.87
70.94
CAD
66.94
77.10
66.21
76.91
67.10
75.62
66.75
76.54
AT
67.98
71.59
68.14
72.30
68.24
72.57
68.
72.15
FITS
DC
68.54
71.82
67.79
70.56
67.98
71.25
68.10
71.21
CAD
68.03
80.37
67.92
80.70
67.43
80.30
67.79
80.46
A2P (Ours)
71.18
83.37
68.17
81.55
69.01
82.52
69.46
82.48
of the datasets as discussed in (Wagner et al., 2023). Though, we demonstrate the results on the datasets in Table 10 for reference.
C.2. Experiment on other evaluation metrics
Table 1l demonstrates the results on anomaly prediction evaluated using VUS-PR and VUS-ROC proposed in (Paparrizos et al., 2022). VUS-PR and YUS-ROC are parameter-Fe free measures that are extended from AUC-based measures. As shown the table, our proposed A2P showed superior performance across various forecasting length, indicating the robustness to predict future anomalies of A2P.
C.3. Experiment on other baselines
To demonstrate the more generalized performance of A2P, the results of additional anomaly detection baseline experiments are summarized Table 12. We combined previously utilized time series forecasting models with time series anomaly detection models such TranAD (Tuli al., 2022), BearGAN (Zhou al., 2019), and DiffusionAD (Zhang et al., 2025). Across these baselines, A2P consistently achieved the highest performance.
C.4. Results various tolerance
In the Anomaly Prediction task, it is crucial to detect the exact time steps of anomalies. In this regard, the general Point Adjustment strategy is not fit to the Anomaly Prediction task. Therefore, define as the number of time steps allow emror in anomaly detection outputs before and after each time step, which is used to control the difficulty of the task. We conducted experiments by varying from 1 to co, where oc is equivalent to the existing point adjustment setting, As shown in Figure& 8, our proposed A2P outperformed on all f, implying that A2P can be used in diverse scenarios, from situations where strict localization time step is required to more relaxed scenarios. In our experiments, we used t = 50 as our default setting.
15

---

Avg. F1 When Will It Fail?
Table Anomaly Prediction results on other baselines using additional anomaly detection models that are excluded in the main paper with Lin Lout 100, averaged over 3 random seeds. The best and second results are highlighted.
Model
Dataset
AD
MBA
Exathlon
SMD
WADI
TranAD
61.38
17.35
34.67
57.12
42.63
P-TST
BeatGAN
64.86
16,85
33.34
57.29
43,08
DiffusionAD
38.79
13.43
22.14
45.98
30.08
TranAD
58.10
18.48
28.97
59.36
41.22
MICN
BeatGAN
65.15
17.29
34.84
62.88
45.04
DilfusionAD
36.14
15.85
25.90
46.28
31.04
TranAD
60.65
17.97
33.12
61.89
43.40
GPT2
BeatGAN
50.82
17.27
30.45
55.07
38.40
DiffusionAD
29.74
13.76
23.88
52.21
29.89
TranAD
62.05
17.54
33.28
63.04
43.97
iTransformer
BeatGAN
63.97
17.35
32.19
59.68
43.29
DiffusionAD
37.60
11.97
23.43
48.80
30.45
TranAD
61.80
18.15
31.73
58.60
42.57
FITS
BeatGAN
61.16
17.32
28.77
53.46
40.17
DiffusionAD
27.79
11.96
21.68
46.95
27.09
A2P (Ours)
67.55
18.64
36.29
64.91
46.84
(Ours)
Exathlon
100
100
100
80
80
80
F1-Score
60-
40
40
00
50
Tolerance
Tolerance
Tolerance
Telerance
Figure 8: The F1-score of anomaly prediction in various tolerance, when Lin Toout = 100.
D. Qualitative Results
We provide additional results forecasting on the state-of-the-art forecasting models in Figure 9. The result showed that the existing forecasting models fail predicting abnormal events, since they consider learn with only normal signals.
E. Hyperparameter Sensitivity
To figure out the effect of various hyperparameters used in A2P, we examined the Fl-scores by varying each hyperparameter, as shown in Figure 10. We conducted experiments with various À coefficients, ranging from 0. to 0.9, to weigh each loss term in the objective function. Our proposed model A2P showed stable performance across various values X. Regarding hyperparameters of Synthetic Anomaly Prompting, we examined the effect of various values of for the number of anomaly pool, M the pool size the anomaly prompt pool, and L, which is the length of an anomaly prompt. While our proposed A2P achieved stable performance for N and L, across datasets, M affects the performance. Specifically, the F1-score the MBA dataset degrades with bigger pool size, indicating that the selection of appropriate pool size considering the size of the dataset is needed to fully leverage the effectiveness of SAP. We also examined the influence of nhAFFN which is the number of heads in Anomaly-Awar Forecasting Network. As shown in the last plot of Figure 10, our proposed A2P performed robustly.
16

---

When Will It Fail?
GT
GT
A2P(Ours)
PatchTST
MICN
AM MMM
-2
60
100
GT
GT FITS
GPT2
Trannformer
Mo MD
-2
3
op
-3-
GT
GT
GT
A2P(Ours)
PatchTST
MICN
20
60
100
60
80
100
20
100
-3
GT
Gt
Gf
GPT2
Transformer
FITS
20
60
100
60
80
100
20
40
100
Figure Comparison result of forecasting the MBA dataset when Lin Loue are Red shaded area indicate steps with anomalies.
17

---

When Will It Fail?
MBA
Exathlom
WADI
Fl E1-Score
0.4
0.6
0.2
0.8
0.2
0.4
AAF
Ap
A
70
Fl -l-ooore
50
30
10
0.2
0.4
0.6
0.8
0.2
0.4
0.6
0.8
2
4
A
À
N
70
F1-Score
.0
10
15
20
4
Lz
nhAAFN
Figure 10: The results on various hyperparameter values when Lyp Toout = 100.
18


Reviews:
[{"review_id": "ZX4qGRsBv1", "reviewer": "Reviewer_K8J2", "summary": "The paper introduces a novel framework called A2P designed to forecast future anomalies in time series data. Unlike traditional forecasting models—typically trained on standard signals and consequently fail to accurately predict abnormal events—the proposed method integrates anomaly-aware components into the forecasting process. A2P is comprised of two key elements:\n\n- **Anomaly-Aware Forecasting (AAF):** This component pre-trains a forecasting network to learn the relationships between past anomalies and future trends, enabling the model to predict signals more accurately and reflect potential abnormal events.\n- **Synthetic Anomaly Prompting (SAP):** This technique employs a learnable Anomaly Prompt Pool (APP) to inject synthetic anomalies at the embedding level during training. This process helps the model simulate and recognize various anomaly patterns.\n\nThe authors validate their approach with extensive experiments on multiple real-world datasets, demonstrating significant improvements in anomaly prediction and forecasting accuracy over existing baselines.", "questions": "", "limitations": "", "rating": 3, "confidence": null, "soundness": null, "presentation": null, "contribution": null, "strengths": "", "weaknesses": "", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "We appreciate your meaningful feedback, and your insights are invaluable as we continue to improve our work!\n\n**Computational Complexity**\n\nPlease refer to the Computational Complexity section in Reviewer ADJk.\n\n**AP Task**\n\nThe only prior work on Anomaly Prediction in time series is [1], which only formulates the problem without proposing concrete solutions. In contrast, our work is the first to introduce practical methods for AP, specifically through SAP and AAF, which directly address the core challenges and advance the field. \n\n[1] You et al. \"Anomaly Prediction: A Novel Approach with Explicit Delay and Horizon.\" ICCP 2024.\n\n**Underspecified Metrics**\n\nThe conventional point adjustment for evaluation, as discussed in [1], has known limitations. Since the goal is to predict anomalies within a reasonable time window rather than at exact points, using raw prediction outputs is not ideal. For instance, medical doctors are more concerned with detecting abnormal symptoms over a time window, rather than at specific seconds or minutes. To address this, we use the F1-score with tolerance, a modified version of the traditional F1 with point adjustment, which allows error tolerance with a set time window around predicted anomalies, offering a more realistic evaluation, as shown in the figure (URL: https://ifh.cc/v-ZLV6Kf). \n\n[1] Kim et al. \"Towards a rigorous evaluation of time-series anomaly detection.\" AAAI 2022.\n\n**Data Augmentation**\n\n||NoAug|Spikes|Context|Flip|Noise|CutOff|Scale|Wander|Avg|**A2P(Ours)**|\n|-|:-:|:-:|:-:|:-:|:-:|:-:|:-:|:-:|:-:|:-:|\n|Avg. across datasets (F1)|38.89|39.18|37.62|39.27|37.60|37.63|39.56|38.94|38.76|**46.84**|\n\nWe compared A2P with data augmentation methods from [1]. While these methods improve prediction to some extent, they are limited by fixed anomaly injection rules. A2P, with context-aware prompts, generates more realistic anomalies, yielding better performance.\n\n[1] Goswami et al. “Unsupervised model selection for time series anomaly detection.” ICLR 2023.\n\n**Unified Framework**\n\nAdditional references on unified and multi-task frameworks, like [1] and [2], will be discussed. However, these models are unsuitable for AP. [2] only focuses on forecasting and simply combining forecasting and anomaly detection modules-such as in foundation models that handle each task independently-performs poorly, as shown in Table 1 baselines. AP requires forecasting anomalies and learning temporal patterns, which existing models lack. In contrast, A2P is specifically built for AP, integrating AAF with a learnable prompt pool to extend unified modeling trends into proactive anomaly handling.\n\n[1] Gao et al. “UniTS: A unified multi-task time series model.” NeurIPS 2024.\n\n[2] Woo et al. “Unified training of universal time series forecasting transformers.” ICML 2024.\n\n**Method Flow**\n\nOur two methods—SAP and AAF—work together in the A2P framework to bridge anomaly detection and forecasting. SAP addresses the challenge of limited abnormal signals in training data by using trainable anomaly prompts to create realistic synthetic anomalies, enhancing the model's anomaly recognition. AAF, in contrast, forecasts anomalies directly, improving predictions in abnormal conditions. Together, SAP and AAF complement each other—SAP enriches training data, while AAF uses this enriched data to enhance forecasting signals with anomalies. This synergy allows A2P to effectively detect and predict anomalies.\n\n**SAP Explanation**\n\nTo clarify the SAP module, we include a figure (URL: https://ifh.cc/v-3dyYJd) that illustrates its mechanism. The Anomaly Prompt transforms normal features into anomalies, and the loss function $L_D$ guides the prompt pool to generate meaningful anomalies.\n\n**Grammatical Errors**\n\nWe will carefully proofread the manuscript to correct any minor grammatical errors, e.g., “we formulate called Anomaly Prediction” or “are jointly pre-train”, and inconsistencies in punctuation, ensuring a more polished and professional presentation.\n\n**Hyperparameter Sensitivity**\n\nPlease refer to the Loss terms and Hyperparameters section in Reviewer Xvbm.\n\n**Extra Anomaly Scenarios**\n\n|Model|Point Global|Point Context|Contextual Global|Contextual Seasonal|Contextual Trend|Avg|\n|:-:|:-:|:-:|:-:|:-:|:-:|:-:|\n|P-TST+AT|2.79|3.04|54.59|59.28|55.80|35.10|\n|**A2P(Ours)**|**8.29**|**8.97**|**75.65**|**72.32**|**61.93**|**45.43**|\n\nWe evaluated A2P on five univariate NeurIPS-TS datasets, covering various anomaly types, as outlined in [1]. A2P outperformed the baseline in F1-score, especially on contextual anomalies. However, it struggles with point anomalies due to their short duration. Future work could explore adding context or using multi-step forecasting to better detect point anomalies.\n\n[1] Lai et al. \"Revisiting time series outlier detection: Definitions and benchmarks.\" NeurIPS 2021.\n\n**Code Provision**\n\nWe provide the reproducible code in anonymous repository https://anonymous.4open.science/r/A2P-E2FC.", "claims_and_evidence": "**Evidence Supporting the Claims:**  \nThe paper provides extensive empirical evaluations on several real-world datasets, including MBA, Exathlon, SMD, and WADI, which strongly support the core claims. The experimental results, including detailed ablation studies, convincingly demonstrate that the proposed A2P framework—through its components of Anomaly-Aware Forecasting (AAF) and Synthetic Anomaly Prompting (SAP)—achieves significant improvements in both forecasting accuracy and anomaly prediction performance compared to established baselines.\n\n**Problematic Aspects:**  \n The integration of AAF and SAP introduces additional computational complexity. The paper does not provide a detailed evaluation of the computational trade-offs or scalability of the proposed approach in large-scale or highly dynamic environments.\n\nIn addition, given that similar work had been done before, the author claims that “we first propose a method to deal with the problems\nof Anomaly Prediction.” is suspect.", "methods_and_evaluation_criteria": "The proposed methods are well-aligned with anomaly prediction in time series data. Integrating Anomaly-Aware Forecasting and Synthetic Anomaly Prompting directly addresses the challenge of forecasting future anomalies—a problem where traditional forecasting methods often fall short. The experimental evaluation, which uses benchmark datasets such as MBA, Exathlon, SMD, and WADI, is appropriate for the application, as these datasets represent diverse real-world scenarios in domains like medical monitoring and industrial systems. Additionally, relevant metrics (e.g., F1-score with tolerance for anomaly detection and Mean Squared Error for forecasting) provide clear quantitative evidence of the framework's performance. The problem is that the author's description of his newly created evaluation index is too brief for the controversial F1-related evaluation criteria. More detailed explanations should be given for the evaluation indicators to avoid confusion among readers.", "theoretical_claims": "The submission primarily focuses on algorithmic innovations and empirical validation rather than on formal theoretical proofs. While the paper does provide mathematical formulations of its loss functions and training objectives (such as LAAF, LD, and LF), it does not include formal proofs for theoretical claims. I verified that the provided formulations are logically consistent with the intended design of the A2P framework; however, since no formal proofs were presented, there was no need to check the correctness of theoretical proofs in a rigorous sense.", "experimental_designs_or_analyses": "**Experimental Design Validity and Analysis:**  \nI reviewed the experimental setups detailed in the submission, which include evaluations of both forecasting and anomaly prediction capabilities. The experiments are conducted on multiple real-world datasets (MBA, Exathlon, SMD, and WADI), ensuring diverse and representative scenarios. The following points summarize my assessment:\n\n- **Soundness of Evaluation Metrics:**  \n  The use of Mean Squared Error for assessing forecasting accuracy and F1-score (with a tolerance window for anomaly detection) is appropriate and well-justified for the tasks at hand.\n\n- **Ablation Studies:**  \n  Comprehensive ablation experiments are presented to isolate the contributions of the two key components: Anomaly-Aware Forecasting (AAF) and Synthetic Anomaly Prompting (SAP). These studies effectively demonstrate the individual and combined benefits of each component.", "relation_to_broader_scientific_literature": "The paper’s contributions build on and extend several key ideas from the broader literature on time series analysis, anomaly detection, and forecasting. Specifically:\n\n- **Integration of Forecasting and Anomaly Detection:**  \n  Traditional time series forecasting methods (e.g., PatchTST, GPT2, iTransformer) are designed to predict normal behavior and, thus, often neglect anomalies. In contrast, this work builds on the observation—also noted in recent studies such as Jhin et al. (2023) and You et al. (2024)—that forecasting models need to account for abnormal signals to be truly effective in real-world scenarios. By embedding anomaly awareness into the forecasting process, the paper extends prior work that typically treats forecasting and anomaly detection as separate tasks.\n\n- **Anomaly-Aware Forecasting (AAF):**  \n  The idea of pre-training a forecasting network to learn the relationship between past anomalies and future trends is novel in its application to anomaly prediction. While earlier studies have focused on detecting anomalies from historical data or near-term forecasts, this approach leverages anomaly-aware pre-training to predict future abnormal events, thereby addressing a gap in the literature.\n\n- **Synthetic Anomaly Prompting (SAP):**  \n  Using a learnable Anomaly Prompt Pool (APP) to inject synthetic anomalies during training is conceptually related to techniques in data augmentation and prompt-based learning seen in other areas of machine learning. However, its application in time series anomaly prediction is innovative. This idea builds on earlier work in synthetic data generation and augmentation but adapts these principles to enhance the representation of anomalies, thereby improving detection accuracy in forecasting future signals.", "essential_references_not_discussed": "The submission provides a solid set of citations for time series forecasting and anomaly detection, including recent works on anomaly prediction. However, some additional related works could further contextualize its key contributions:\n\n- **Prompt-Based Learning Literature:**  \n  The Synthetic Anomaly Prompting component is reminiscent of prompt tuning techniques that have seen significant development in the NLP community [1]. While the paper adapts the concept to time series data, discussing these foundational works could help readers understand the conceptual lineage and justify the design of the learnable Anomaly Prompt Pool.\n\n- **Synthetic Data Generation for Anomalies:**  \n  Although the authors reference anomaly injection schemes (e.g., Darban et al., 2025), other works focus on synthetic anomaly generation and data augmentation in time series that might offer additional insights or alternative approaches. A broader review of such methods could strengthen the rationale for the proposed synthetic anomaly prompting strategy.\n\n- **Unified Architectures for Forecasting and Anomaly Detection:**  \n  The paper contributes by merging forecasting and anomaly detection within a shared architecture. There is an emerging literature on integrated approaches in this space. While the submission cites several relevant studies, additional references that discuss unified or multi-task learning frameworks for time series analysis could further clarify how the proposed method fits into and extends current trends.\n\n[1]Brian Lester, Rami Al-Rfou, and Noah Constant. 2021. The Power of Scale for Parameter-Efficient Prompt Tuning. In Proceedings of the 2021 Conference on Empirical Methods in Natural Language Processing, pages 3045–3059, Online and Punta Cana, Dominican Republic. \nAssociation for Computational Linguistics.", "other_strengths_and_weaknesses": "- **Originality:**  \n  The paper exhibits originality by creatively combining ideas from time series forecasting, anomaly detection, and prompt-based learning. The introduction of Synthetic Anomaly Prompting (SAP) via a learnable Anomaly Prompt Pool (APP) is a novel adaptation of concepts initially developed in the NLP domain. Additionally, integrating Anomaly-Aware Forecasting (AAF) to bridge the gap between regular signal forecasting and anomaly detection provides a fresh perspective on the long-standing challenge of forecasting anomalies.\n\n- **Significance:**  \n  Addressing the problem of forecasting future anomalies has considerable practical significance, particularly in applications such as medical monitoring and industrial system maintenance. The proposed framework demonstrates improved predictive performance over existing baselines and has the potential to influence the design of early-warning systems in critical domains. This application-driven impact underscores the broader importance of the contributions.\n\n- **Clarity:**  \n  The paper is technically rigorous and detailed, clearly describing its methodology and experimental setups. However, the presentation can be dense and highly technical in certain sections, which might impede accessibility for a broader audience. Improving the narrative flow or providing additional intuition behind complex components could enhance clarity without sacrificing depth.\n\n- **Additional Strengths:**  \n  The extensive empirical evaluations across multiple benchmark datasets and comprehensive ablation studies lend strong support to the proposed approach. These experimental results validate the effectiveness of the individual components (AAF and SAP) and demonstrate the unified architecture's benefits in learning robust representations for forecasting and anomaly detection.\n\n- **Additional Weaknesses:**  \nNo code was provided for verification.", "other_comments_or_suggestions": "**Other Comments and Suggestions:**  \nOverall, the paper is well-structured and presents its ideas in a technically detailed manner. Nonetheless, a few minor points could further enhance its clarity and presentation:\n\n- **Typographical and Formatting Consistency:**  \n  Although a search for explicit typographical errors did not reveal any major issues, I observed occasional minor inconsistencies in formatting. For example, there are instances where spacing around mathematical symbols and figure captions could be more uniform. Additionally, the notational switch between “AAF” and “AAFN” (when referring to the anomaly-aware forecasting components) might confuse readers; ensuring consistency in the notation throughout the manuscript would improve readability.\n\n- **Clarity in Complex Sections:**  \n  The technical sections are dense, particularly those describing the Synthetic Anomaly Prompting (SAP) module and its associated loss functions. Consider incorporating additional intuitive explanations or visual aids to help demystify these complex components for a broader audience.\n\n- **Proofreading for Minor Errors:**  \n  A careful proofreading to check for any minor grammatical errors or inconsistencies in punctuation could further polish the manuscript.", "questions_for_authors": "1. Can you elaborate on the sensitivity of the Synthetic Anomaly Prompting (SAP) component to hyperparameter settings (e.g., the size of the anomaly prompt pool and the number of prompts attached)? \n\n2. Could you discuss the integrated A2P framework's computational complexity and scalability, especially compared to standard forecasting methods? \n\n3. Are there specific scenarios or types of datasets where the A2P method underperforms relative to existing baselines? If so, can you provide an analysis of these cases and potential strategies for improvement?\n\n4. This work would be more convincing if a reproducible verification code were provided.", "summary_of_paper": "", "summary_of_recommendation": "", "technical_quality": "", "clarity_of_presentation": "", "potential_impact": "", "robotics_focus": "", "quality_of_limitations": "", "questions_for_rebuttal": "", "reasons_to_accept": "", "reasons_to_reject": "", "questions_to_authors": "", "extra_scores": {}}, {"review_id": "yrPvCKIdPP", "reviewer": "Reviewer_ADJk", "summary": "This paper proposes a novel framework, Anomaly to Prompt (A2P), to address the Anomaly Prediction (AP) task in time series analysis, which aims to predict future anomalies. The framework integrates two key components: Anomaly-Aware Forecasting (AAF) that learns relationships between anomalies and future signals, and Synthetic Anomaly Prompting (SAP) generates synthetic anomalies through signal-adaptive prompting. Experiments on real-world datasets demonstrate A2P’s superiority over SOTA methods.", "questions": "", "limitations": "", "rating": 4, "confidence": null, "soundness": null, "presentation": null, "contribution": null, "strengths": "", "weaknesses": "", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "We are sincerely grateful for giving us positive comments and acknowledging the contribution of our proposed method A2P for tackling the challenges of AP.\n\n**Initialization and Optimization Details**\n\nAll additional parameters introduced for APP are initialized using a standard uniform initialization method in the PyTorch library. We will include this detail in the revision.\n\n**Computational Complexity**\n\n- To investigate the impact of additional computational complexity of our proposed methods, we measured GFLOPs per iteration (including both pre-training and main training) and the total number of parameters of the baseline (combination of PatchTST and AnomalyTransformer) and our proposed A2P. \nAs shown in the figure (URL:https://ifh.cc/v-SRor7L), A2P does require additional computation compared to the baseline. However, since our model unifies both forecasting and anomaly detection within a single framework, it significantly reduces the overall parameter footprint. More importantly, this additional cost is only incurred during training, with no extra overhead at inference time. Despite the modest increase in training complexity, A2P achieved an average 10% improvement in performance over the baseline, demonstrating a favorable trade-off between cost and accuracy. Moreover, the train time consumed is utmost 1 hour in WADI dataset, which is negligible and is not really a heavy burden for A2P to be applied in real-world scenarios. \n- Regarding scalability, the four datasets in Table 1 cover various ranges of dataset scales, as well as dynamic environments. To further validate A2P’s effectiveness, we conducted additional experiments on the KPI dataset (representing large-scale data) and the NeurIPS-TS dataset (characterized by highly dynamic anomaly patterns across all five anomaly types specified in [1]). A2P achieved state-of-the-art F1-score on both datasets, highlighting its robustness and scalability in large and dynamic settings.\n\n|Model|NeurIPS-TS|KPI|\n|:-:|:-:|:-:|\n|P-TST+AT|23.09|24.49|\n|**A2P(Ours)**|**34.18**|**33.46**|\n\n[1] Lai et al. \"Revisiting time series outlier detection: Definitions and benchmarks.\" NeurIPS 2021.\n\n**Existing Method for AP**\n\nTo the best of our knowledge, there are currently no existing methods specifically designed for the AP task. However, a related study [1] conducted AP experiments using existing forecasting models, though these approaches do not directly address the unique challenges of AP.\nFor a fair comparison, we constructed baselines by systematically combining established forecasting and anomaly detection models. This setup allows us to benchmark our method against the most relevant alternatives and highlights its distinct advantages.\n\n[1] You et al. \"Anomaly Prediction: A Novel Approach with Explicit Delay and Horizon.\" ICCP 2024.\n\n**Precursor Detection**\n\nOur proposed model A2P can detect precursors of impending anomalies. Since there are no labels indicating ‘precursor of anomalies’ in the dataset, we cannot measure the numeric performance of detection of precursors explicitly. \nInstead, we visualized the attention map of the cross attention in Anomaly-Aware Forecasting Network, to investigate if the model can relate specific parts of the prior signals when identifying future anomalies, as shown in the figure (URL:https://ifh.cc/v-cQD6Ka). When identifying the future anomalies (red-shaded area), which is the main purpose of AP, the model focuses on specific area of prior signals (circled area). While not perfect, our proposed model can provide a further explainable information to infer which prior time steps contribute to predicting future anomalies. This approach can be effective in many real-world scenarios, for example, medical doctors can scrutinize the normal data of patients to give them appropriate instructions to prevent possible diseases.\n\n\nWe will incorporate the additional details such as initialization and computational costs in the revision, and thank you again for your careful attention.", "claims_and_evidence": "Yes.", "methods_and_evaluation_criteria": "Yes, the proposed method and evaluation criteria makes sense.", "theoretical_claims": "I think the theoretical claims of this paper are correct.", "experimental_designs_or_analyses": "Yes, the experimental designs are reasonable.", "relation_to_broader_scientific_literature": "The key contributions of this paper bridges the gap between time series forecasting and anomaly detection, which provides insights for future study in anomaly prediction rather than the popular anomaly detection tasks.", "essential_references_not_discussed": "No. Related works are well discussed.", "other_strengths_and_weaknesses": "Strengths:\n1. The paper fills a critical gap between traditional anomaly detection (AD) and forecasting by defining Anomaly Prediction (AP) as a distinct task requiring precise localization of future anomalies.\n2. The proposed A2P achieves state-of-the-art F1 scores across different datasets.\n3. The proposed model is easy to follow and codes are provided.\n\nWeaknesses:\n1. The initialization and optimization details of the the proposed APP are unclear. For instance, how are prompts initialized? \n2. Computational costs for pre-training AAF and APP are not quantified, which is critical for real-world deployment.", "other_comments_or_suggestions": "Please refer to the weakness.", "questions_for_authors": "1. Since the anomaly prediction (AP) task fundamentally differs from anomaly detection (AD) methods, the authors construct baselines with combinations of forecasting and anomaly detection models. Could the proposed model be compared with existing models that were specifically designed for AP tasks?\n2. Can the model detect precursors of impending anomalies? For example, before an anomaly occurs (the status of the device is still normal), the model can identify early warning signals in the data, enabling interpretable anomaly prediction.", "summary_of_paper": "", "summary_of_recommendation": "", "technical_quality": "", "clarity_of_presentation": "", "potential_impact": "", "robotics_focus": "", "quality_of_limitations": "", "questions_for_rebuttal": "", "reasons_to_accept": "", "reasons_to_reject": "", "questions_to_authors": "", "extra_scores": {}}, {"review_id": "P70mGceuS8", "reviewer": "Reviewer_Xvbm", "summary": "This paper formulates the abnormal prediction problem in time series, aiming to forecast specific future time points where anomalies will occur. Accordingly, the authors propose Anomaly-Aware Forecasting and Synthetic Anomaly Prompting to address the problem.\n\n## update after rebuttal\nThe authors adequately addressed my concerns, so I raised the score to 3.", "questions": "", "limitations": "", "rating": 3, "confidence": null, "soundness": null, "presentation": null, "contribution": null, "strengths": "", "weaknesses": "", "quality": null, "clarity": null, "significance": null, "originality": null, "strengths_and_weaknesses": "", "was_revised": false, "final_justification": "", "rebuttal": "Thank you for giving us meaningful feedback!\n\n**More Datasets and Baselines**\n\n- TimeSeAD\n|Model|Exathlon-Avg.F1|SMD-Avg.F1|\n|:-:|:-:|:-:|\n|P-TST+AT|14.76|30.58|\n|**A2P(Ours)**|**15.28**|**39.72**|\n\n- TranAD, BeatGAN, TimeMixer, DiffusionAD\n|F model|AD model|Avg.F1|\n|:-:|:-:|:-:|\n|P-TST|TranAD|42.63|\n||BeatGAN|43.08|\n||DiffusionAD|30.08|\n|MICN|TranAD|41.22|\n||BeatGAN|45.04|\n||DiffusionAD|31.04|\n|GPT2|TranAD|43.40|\n||BeatGAN|38.40|\n||DiffusionAD|29.89|\n|iTransformer|TranAD|43.97|\n||BeatGAN|43.29|\n||DiffusionAD|30.45|\n|FITS|TranAD|42.57|\n||BeatGAN|40.17|\n||DiffusionAD|27.09|\n|TimeMixer|AT|42.72|\n||DC|34.40|\n||CAD|17.16|\n||TranAD|41.85|\n||BeatGAN|43.55|\n||DiffusionAD|26.10|\n|**A2P(Ours)**||**46.84**|\n\nOur method outperforms all existing baselines across widely used benchmark datasets, demonstrating its effectiveness and generalizability.\n\n**Numerical Modesty of Results**\n\nAP is challenging as it requires predicting rare anomalies. Even small metric gains are meaningful. Table 1 shows our method consistently outperforms baselines, proving its effectiveness. \n\n**Dataset Splitting**\n\nFollowing prior works [1], we used non-overlapping windows for AP.\n\n[1] Xu et al. “Anomaly transformer: Time series anomaly detection with association discrepancy.” ICLR 2022.\n\n**Dataset Statistics**\n\n|Dataset|Avg.AnomalyRatio(%)|Avg.AnomalyLen|#AnomalySeg|#Batches|AnomalySeg/TotalSample|AnomalySeg/AnomalySample|\n|:-:|:-:|:-:|:-:|:-:|:-:|:-:|\n|MBA|33.80|29.48|86|75|1.14|1.18|\n|Exathlon|12.69|91.94|1091|8911|0.12|1.00|\n|SMD|4.15|47.26|623|7083|0.08|1.00|\n|WADI|4.88|62.19|27|344|0.07|1.04|\n\nThe visualized sample in Fig. 8 typically contains a single anomaly pattern, but our method also handles subtle anomalies effectively, as shown in the table.\n\n**Trajectory Modeling**\n\nAP focuses on forecasting rare anomalies, while trajectory modeling predicts paths under normal conditions [1,2]. Some works [3] focus on anomaly detection, not future predictions, so AP remains underexplored in this context. A2P’s core idea could be explored in trajectory modeling in future research.\n\n[1] Tang et al. “HPNet: Dynamic Trajectory Forecasting with Historical Prediction Attention.” CVPR 2024.\n\n[2] Phan-Minh et al. “CoverNet: Multimodal Behavior Prediction using Trajectory Sets.” CVPR 2020.\n\n[3] D'amicantonio et al. “uTRAND: Unsupervised Anomaly Detection in Traffic Trajectories.” CVPR 2024.\n\n**Cross-attention**\n\nWhile the cross-attention design may seem intuitive, the core contribution of AAF lies not in the architecture itself but in the idea of learning the inherent patterns of prior and posterior signals to predict future anomalies. By modeling the relationship between these signals, AAF captures temporal dependencies that are critical for AP, going beyond traditional forecasting or anomaly detection approaches.\n\n**Loss terms and Hyperparameters**\n\nOur method introduces two unique loss terms, $L_{AAF}$ and $L_{D}$, with others extended from traditional time series loss functions. A2P shows strong robustness across hyperparameter settings,as shown in Section E of the supplementary material. This suggests that they do not significantly complicate the tuning process.\n\n**Anomaly Threshold**\n\nThe anomaly threshold follows the widely accepted protocol from [1], adjusting for a percentage of anomalies in the test data. This approach ensures consistency with established standards for anomaly detection tasks. \n\n[1] Shen et al. \"Timeseries anomaly detection using temporal hierarchical one-class network.\" NeurIPS 2020.\n\n**Trainable Parameters**\n\nIn the pre-training stage, only AAFN and APP parameters are trainable. In the main training phase, only the backbone parameters are trained.\n\n**Simultaneous Training**\n\n|Method|MBA|Exathlon|SMD|WADI|Avg.F1|\n|:-:|:-:|:-:|:-:|:-:|:-:|\n|Simultaneous Training|45.70|17.90|33.26|59.86|39.18|\n|**Ours**|**67.55**|**18.64**|**36.29**|**64.91**|**46.84**|\n\nWe experimented with training all components simultaneously and found it suboptimal as shown in the table. This may be due to the Anomaly Probability output from the Anomaly-Aware Forecasting Network, which, when not fully trained, hinders proper forecasting. By using a two-stage training strategy, we ensure that the anomaly probability is learned first, allowing it to enhance future time series prediction during the main training phase, leading to better performance.\n\n**[CLS] Token**\n\nThe [cls] token is a learnable embedding used to capture global representations, similar to its role in BERT [1]. It helps select the most relevant anomaly prompt in A2P, enabling effective abnormal signal synthesis.\n\n[1] Devlin et al. \"Bert: Pre-training of deep bidirectional transformers for language understanding.\" NAACL 2019.\n\n\nWe greatly appreciate your helpful comments, and we will be sure to include the above-mentioned details in our revision. This will provide a more thorough explanation and address the points you raised in a comprehensive manner, enhancing the overall quality of the paper.", "claims_and_evidence": "I think the results mostly support the claim.", "methods_and_evaluation_criteria": "Yes. The paper employs some commonly used datasets, but more datasets and more baselines are expected.\n\nDataset: \n- TimeSeAD: Benchmarking Deep Multivariate Time-Series Anomaly Detection\n\nBaselines: \n- TranAD: deep transformer networks for anomaly detection in multivariate time series data\n- BeatGAN\n- TimeMixer\n- DiffusionAD:  Imputation-based time-series anomaly detection with conditional weight incremental diffusion models", "theoretical_claims": "There are no theoretical claims. It would be better to include some but not mandatory to me.", "experimental_designs_or_analyses": "Yes, I checked. The numerical results do not seem very high to me. I am not sure if it is caused by the nature of the task, but anyway, the overall gain looks very substantial.\n\nI am curious about how the authors split the datasets. Do they use non-overlapping windows or overlapping windows to generate samples? \n\nI am also curious about the average anomalies for each sample. As shown in Fig.8, it seems only one animal pattern per sample.", "relation_to_broader_scientific_literature": "The paper builds upon prior works in time series forecasting and anomaly detection.", "essential_references_not_discussed": "Yes.", "other_strengths_and_weaknesses": "The Synthetic Anomaly Prompting seems like a retrieve-based approach for anomaly detection, while integrating it in the framework looks novel to me.\n\nMy main concern is that the problem is very naive in real-world applications, and it can be very common in trajectory modeling in automount driving. The cross-attention design is also very intuitive, as one input is a query, and one is a key/value.\n\nAnother limitation is that there are too many loss terms and hyper-parameters, making tuning and optimization more complex.", "other_comments_or_suggestions": "N/A", "questions_for_authors": "- How does the method determine the threshold for the abnormal pattern?\n- Can you clarify at which stage which parameters are trainable? Are AFFN trainable at the second stage?  I feel like all components can be trained simultaneously. If this is not optimal, what is the potential reason for that? \n- What is [cls] token used for? Is there any specific reason for employing it?", "summary_of_paper": "", "summary_of_recommendation": "", "technical_quality": "", "clarity_of_presentation": "", "potential_impact": "", "robotics_focus": "", "quality_of_limitations": "", "questions_for_rebuttal": "", "reasons_to_accept": "", "reasons_to_reject": "", "questions_to_authors": "", "extra_scores": {}}]

Author rebuttal:

Meta-review: This paper tackles the task of Anomaly Prediction in time series, proposing A2P that integrates anomaly-aware forecasting with synthetic prompt–based training. 

Reviewers likes it for address a gap that conventional forecasting and detection methods overlook, since they rarely predict future anomalous time points. The authors’ experiments on real datasets show their method outperforms combined baselines and earlier approaches. Ablations are also good!

 Some noted that the tolerance-based F1 metric needs careful interpretation, but the authors clarified it is stricter than some existing point-adjusted scores. Additional comparisons (e.g., with time-series baseline) further strengthen the claim. 

In sum, we find A2P to be a well-motivated solution to anomaly prediction with solid experimental gains, recommending acceptance.
Decision: Accept (poster)