SPEAR: Soft Prompt Enhanced Anomaly Recognition for Time Series Data

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Wei, Hanzhe, Wu, Jiajun, Yang, Jialin, Leung, Henry, Drew, Steve
Format: Preprint
Veröffentlicht: 2025
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866912629809741824
author Wei, Hanzhe
Wu, Jiajun
Yang, Jialin
Leung, Henry
Drew, Steve
author_facet Wei, Hanzhe
Wu, Jiajun
Yang, Jialin
Leung, Henry
Drew, Steve
contents Time series anomaly detection plays a crucial role in a wide range of fields, such as healthcare and internet traffic monitoring. The emergence of large language models (LLMs) offers new opportunities for detecting anomalies in the ubiquitous time series data. Traditional approaches struggle with variable-length time series sequences and context-based anomalies. We propose Soft Prompt Enhanced Anomaly Recognition (SPEAR), a novel approach to leverage LLMs for anomaly detection with soft prompts and quantization. Our methodology involves quantizing and transforming the time series data into input embeddings and combining them with learnable soft prompt embeddings. These combined embeddings are then fed into a frozen LLM. The soft prompts are updated iteratively based on a cross-entropy loss, allowing the model to adapt to time series anomaly detection. The use of soft prompts helps adapt LLMs effectively to time series tasks, while quantization ensures optimal handling of sequences, as LLMs are designed to handle discrete sequences. Our experimental results demonstrate that soft prompts effectively increase LLMs' performance in downstream tasks regarding time series anomaly detection.
format Preprint
id arxiv_https___arxiv_org_abs_2510_03962
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle SPEAR: Soft Prompt Enhanced Anomaly Recognition for Time Series Data
Wei, Hanzhe
Wu, Jiajun
Yang, Jialin
Leung, Henry
Drew, Steve
Machine Learning
Artificial Intelligence
Time series anomaly detection plays a crucial role in a wide range of fields, such as healthcare and internet traffic monitoring. The emergence of large language models (LLMs) offers new opportunities for detecting anomalies in the ubiquitous time series data. Traditional approaches struggle with variable-length time series sequences and context-based anomalies. We propose Soft Prompt Enhanced Anomaly Recognition (SPEAR), a novel approach to leverage LLMs for anomaly detection with soft prompts and quantization. Our methodology involves quantizing and transforming the time series data into input embeddings and combining them with learnable soft prompt embeddings. These combined embeddings are then fed into a frozen LLM. The soft prompts are updated iteratively based on a cross-entropy loss, allowing the model to adapt to time series anomaly detection. The use of soft prompts helps adapt LLMs effectively to time series tasks, while quantization ensures optimal handling of sequences, as LLMs are designed to handle discrete sequences. Our experimental results demonstrate that soft prompts effectively increase LLMs' performance in downstream tasks regarding time series anomaly detection.
title SPEAR: Soft Prompt Enhanced Anomaly Recognition for Time Series Data
topic Machine Learning
Artificial Intelligence
url https://arxiv.org/abs/2510.03962