Search arXiv⌕ Search

arXiv · 2610.30593

TT-SAX: A Two-Track Time Series Symbolization for Natural Language Shape Querying

Abstract

Natural language querying for time series databases aims to let users find what they need in long histories of data by asking in plain language. Shape queries ask how a series moves. They are the main challenge of this task. Recent work makes them feasible by using symbolization as a bridge between the query and the long history. However, existing symbolizations were designed for compression, similarity indexing, or classification. What a symbolization should provide for natural language querying has not been systematically studied. We therefore examine the definitions of six classical symbolizations against this task and identify three limitations. (1) Direction is missing from the string, (2) direction is measured at too small a scale, and (3) the letters are arbitrary. Three design principles follow. We follow these principles and make a minimal redesign of SAX called TT-SAX (two-track SAX). The level letters stay. Each segment gains a trend letter. It is measured across neighboring segments rather than inside one, and graded to match the adjectives that queries use. We conduct extensive experiments on the public NLQTSBench benchmark, comparing TT-SAX with the six classical symbolizations across six LLMs. TT-SAX outperforms all six on shape queries, and ablations trace its gains back to the three limitations one by one. This paper is the first systematic study of time series symbolization with natural language querying as the design goal. It provides a foundation for future research on this task. Our code is available at https://github.com/Atlamtiz/tt-sax.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Zhao Tan, Xianglong Bao, Zhipeng Xi, Ming Jin. 2026-10-22. TT-SAX: A Two-Track Time Series Symbolization for Natural Language Shape Querying. https://arxiv.org/abs/2610.30593

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related papers

An Agentic Approach to Metadata Reasoning

As autonomous LLM agents evolve to perform complex analytical tasks that require integrating multiple datasets, the problem of discovering relevant data sources becomes a key bottleneck. Beyond the challenge posed by the sheer volume of available data sources, data-source selection is difficult because the semantics of data are nuanced and require considering many aspects of the data. To address this challenge, we introduce Metadata Reasoner, an agentic approach to metadata reasoning that identifies a small set of data sources that are both sufficient and minimal for a given analytical task. Metadata Reasoner leverages a table-search engine to retrieve candidate tables, and then autonomously consults various aspects of the available metadata to determine whether the candidates fit the requirements of the task. We demonstrate the effectiveness of Metadata Reasoner through a series of empirical studies. Evaluated on the real-world KramaBench datasets for data selection, our approach achieves an average F1 score of 88.63%, outperforming the strongest baseline by 10.73 percentage points. Furthermore, evaluations on a newly created synthetic benchmark based on the BIRD dataset reveal that Metadata Reasoner is highly robust against redundant and low-quality tables that are in the data lake. In this noisy environment, Metadata Reasoner maintains a 93.5% average F1 score for selecting the right datasets and demonstrates a 100% success rate in avoiding low-quality data. Finally, we extend Metadata Reasoner to support the interleaving of table selection with the execution of partial queries. Compared with a single pass of table selection, such interleaving improves table-selection F1 score on runtime-dependent tasks by 4.8 percentage points and end-to-end task accuracy by 5.3 points.

cs.DB↗

Resilience for Regular Path Queries: Towards a Complexity Classification

The resilience problem for a query and an input set or bag database is to compute the minimum number of facts to remove from the database to make the query false. In this paper, we study how to compute the resilience of Regular Path Queries (RPQs) over graph databases. Our goal is to characterize the regular languages L for which it is tractable to compute the resilience of the existentially-quantified RPQ built from L. We show that computing the resilience in this sense is tractable (even in combined complexity) for all RPQs defined from so-called local languages. By contrast, we show hardness in data complexity for RPQs defined from the following language classes (after reducing the languages to eliminate redundant words): all finite languages featuring a word containing a repeated letter, and all languages featuring a specific kind of counterexample to being local (which we call four-legged languages). The latter include in particular all languages that are not star-free. Our results also imply a dichotomy on all languages with a so-called neutral letter. We last show tractability for some classes of non-local languages, namely the so-called bipartite chain languages and one-dangling languages, and highlight some remaining obstacles towards a full dichotomy.

cs.DB↗

Efficient Path Query Processing in Relational Database Systems

Path queries are crucial for property graphs, and there is growing interest in queries that combine regular expressions over labels with constraints on property values of vertices and edges. Efficient evaluation of such general path queries requires that intermediate results be eliminated early when there is no possible completion to a full result path. Neither state-of-the-art (SOA) graph DBMS nor relational DBMS currently can do this effectively for a large class of queries. We show that this problem can be addressed by giving a relational optimizer ``a little help'' by specifying early filtering opportunities explicitly in the query. To this end, we propose ReCAP, an abstraction that greatly simplifies the implementation of early filtering techniques for any type of property constraint for which such early filtering can be derived. No matter how complex the constraint, one only needs to implement (1) an NFA-style state transition function and (2) a handful of functions that mirror those needed for user-defined aggregates. We show that when using ReCAP, a standard relational DBMS like DuckDB can effectively push property constraints deep into the query plan, beating the SOA graph and relational DBMS by a factor up to 400,000 over a variety of queries and input graphs.

cs.DB↗