arXiv:2611.04482cs.CLNov 2026

Manuscript Offprint

arXiv:2611.04482

TEMPO: Time Series Understanding via Discrete Tokenization

Riccardo Maggioni

Abstract

Time-series interpretation often requires both numerical observations and textual context. Integrating these inputs into a pretrained language model raises a representation question: how should a signal enter the model's token sequence? We present TEMPO, which extends an LLM's vocabulary with discrete codes from a context-aware Transformer tokenizer using finite scalar quantization. A frozen tokenizer maps four-step patches to a 625-code vocabulary; signal tokens, scale statistics, and text are then processed by the LLM's existing self-attention layers. Adaptation updates the new token embeddings and DoRA adapters. With a Qwen3-4B backbone and task-specific fine-tuning, TEMPO achieves macro-F1 scores of 89.0% on activity recognition, 85.0% on sleep staging, and 86.0% on bearing-fault diagnosis. Time-series question answering and qualitative bearing-diagnosis examples further illustrate how this interface combines signal representations with textual context. Together, these results demonstrate the utility of discrete vocabulary extension for time-series understanding.

1. Introduction

Time-series data record how a system evolves, while text describes the conditions under which those observations should be interpreted. A vibration trace, for example, may have different implications during commissioning and during routine operation. An interpretation therefore often needs to combine temporal patterns with operating conditions, maintenance history, and a user's question.

Task-specific classifiers provide useful predictions, but their output interface is usually a fixed label set. Language models offer a complementary interface: users can ask questions and receive descriptions or explanations. The central challenge is to give a pretrained LLM access to the signal itself.

Numerical text serialization, continuous encoder embeddings, and learned discrete tokens make different trade-offs in sequence length, representation, and integration with the language model.

TEMPO studies a discrete interface. A separately pretrained tokenizer converts a normalized signal into contextual codes. These codes become additional vocabulary entries, so text and time-series tokens occupy one input sequence and use the same self-attention layers. Per-channel mean and standard deviation accompany the codes as text. This separates waveform shape from scale information while retaining both as model inputs.

Our contribution is the combination of a context-aware FSQ tokenizer, direct vocabulary extension, and a two-stage adaptation recipe for time-series tasks. The tokenizer attends over the full observed window before quantization, and the LLM is adapted through new embeddings and DoRA adapters. We evaluate this design on activity recognition, sleep staging, bearing-fault diagnosis, and time-series QA, and analyze the tokenizer encoder representations on UCR datasets.

References (24)