[论文解读] TEST: Text Prototype Aligned Embedding to Activate LLM's Ability for Time Series
TEST 提出了一种 TS-for-LLM 框架,它将时间序列进行分词、学习实例级、特征级以及文本原型对齐的嵌入,并使用软提示使 LLM 能够在不丧失语言能力的情况下执行时间序列分类和预测。
This work summarizes two ways to accomplish Time-Series (TS) tasks in today's Large Language Model (LLM) context: LLM-for-TS (model-centric) designs and trains a fundamental large model, or fine-tunes a pre-trained LLM for TS data; TS-for-LLM (data-centric) converts TS into a model-friendly representation to enable the pre-trained LLM to handle TS data. Given the lack of data, limited resources, semantic context requirements, and so on, this work focuses on TS-for-LLM, where we aim to activate LLM's ability for TS data by designing a TS embedding method suitable for LLM. The proposed method is named TEST. It first tokenizes TS, builds an encoder to embed TS via instance-wise, feature-wise, and text-prototype-aligned contrast, where the TS embedding space is aligned to LLM embedding layer space, then creates soft prompts to make LLM more open to that embeddings, and finally implements TS tasks using the frozen LLM. We also demonstrate the feasibility of TS-for-LLM through theory and experiments. Experiments are carried out on TS classification, forecasting, and representation tasks using eight frozen LLMs with various structures and sizes. The results show that the pre-trained LLM with TEST strategy can achieve better or comparable performance than today's SOTA TS models and offer benefits for few-shot and generalization. By treating LLM as the pattern machine, TEST can endow LLM's ability to process TS data without compromising language ability. We hope that this study will serve as a foundation for future work to support TS+LLM progress.
研究动机与目标
- 将 TS-for-LLM 范式总结为一种使 LLM 能处理时间序列数据而无需从头预训练 LLM 的方法。
- 提出并验证 TEST,一种通过基于原型的对比学习将 TS 令牌与 LLM 文本空间对齐的嵌入方法。
- 在多种 LLM 和数据集上展示 TEST 在时间序列分类和预测方面的有效性。
- 分析文本原型和提示如何影响 TS 嵌入在 LLM 内的性能与可解释性。
提出的方法
- 通过随机长度的片段将多变量时间序列分割成标记,并使用指数膨胀因果卷积网络对其进行编码。
- 应用实例级对比学习(MoCo 风格)来学习 TS 令牌嵌入。
- 引入特征维对比,以在一个小批量中对齐并区分特征列。
- 通过将 TS 嵌入映射到所选文本原型嵌入并与 LLM 文本空间对齐,实现文本原型对齐对比。
- 使用可学习的软提示来指导 LLM 进行下游时间序列任务,保持 LLM 冻结,并可选微调用于分类或预测的解码器/头部。
- 提供一种将编码器、提示和任务特定头部结合的算法训练过程(TEST Training Method)。
实验结果
研究问题
- RQ1TEST 是否能够通过 TS 嵌入使 LLM 处理时间序列数据,同时保留其语言能力?
- RQ2实例级、特征级和文本原型对齐对嵌入质量和下游时间序列任务的贡献是什么?
- RQ3文本原型和提示对不同 LLM 架构下的时间序列分类与预测性能的影响是什么?
- RQ4在标准数据集上,使用 TEST 的 TS-for-LLM 能达到多大程度并超越传统的时间序列基线?
主要发现
- TEST 提升了 LLM 在 128 个单变量时间序列数据集和 30 个多变量时间序列数据集上的分类准确性,相较于基线 LLM 的问答方法有显著提升。
- GPT2-117M 在使用 TEST 时,单变量时间序列至少提升 18%,多变量提升 25%。
- 在较大模型(~200M+)下,TEST 可以超越 DWT,在约 700M+ 时超越 DWTD 的分类任务。
- 消融实验显示文本原型和提示显著影响性能,正交/自适应原型和非随机提示初始化表现更好。
- 提示设计(软提示)对结果影响显著,对足够大模型来说,较短的提示也足以。
- 在 TSER 数据集上的预测实验表明 TEST 提升了 LLM 的预测准确性,并在基线方法中具备竞争力的结果。
更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。