arXiv:2608.28318cs.DBAug 2026

Manuscript Offprint

arXiv:2608.28318

VeriTS: Verifiable Model-Enhanced Time-Series Queries on Blockchain Systems

Zhongming Yao, Jun Pang, Chenxu Wang, Qian Ma, Peiyuan Guan, Shiliang Zhang

1st1^{st} Zhongming Yao ∗^{*}

College of Computer Science and Technology

Zhejiang University

Zhejiang, China

yaozzzm@gmail.com

2nd2^{nd} Jun Pang

College of Computer Science and Technology

Wuhan University of Science and Technology

Hubei, China

pangjun@wust.edu.cn

3rd3^{rd} Chenxu Wang

School of Software Engineering

Xi'an Jiaotong University

Xi'an, China

cxwang@mail.xjtu.edu.cn

4th4^{th} Qian Ma

Information Science and Technology College

Dalian Maritime University

Dalian, China

maqian@dlmu.edu.cn

5th5^{th} Peiyuan Guan

School of Computer Science & School of Software

Nanjing University of Information Science & Technology

Nanjing, China

peiyuang@nuist.edu.cn

6th6^{th} Shiliang Zhang

Department of Informatics

University of Oslo

Oslo, Norway

shilianz@ifi.uio.no

Abstract—Blockchain data is temporal. Every transaction carries a timestamp and the chain imposes a total order, so on-chain data forms per-source time-series streams. However, existing systems support only basic lookups on blocks and transactions, and cannot answer time-series queries such as time-range retrieval and windowed aggregation. Offloading queries off-chain restores expressiveness, but the off-chain query layer is untrusted, so results must be verifiable. To this end, we propose VeriTS, the first verifiable time-series query framework for blockchain systems. It supports efficient range and aggregation queries without altering blockchain storage structures. VeriTS maintains an off-chain query layer that represents each stream through an authenticated aggregate interval tree. The tree serves as the query index and as the authenticated data structure at once, so a windowed aggregate is answered by folding a logarithmic number of node aggregates. VeriTS verifies completeness through a minimum covering set and soundness through aggregate folding. It extends both guarantees to an approximate path over model segments, redefining completeness and soundness under bounded error. Miners validate a model's residual rather than replay its computation, so even an adversarial encoder can inflate proof size and answer width but never correctness. Experiments offer evidence that on windowed aggregation, VeriTS improves verification efficiency by more than two orders of magnitude over per-record proofs. Range-query proofs shrink by up to 14.5×14.5\times.

Index Terms—time series, learned representation, verifiable query, completeness and soundness, blockchain

I. INTRODUCTION

Blockchain is a decentralized, distributed ledger technology. Through hashed data structures, cryptographic primitives, and consensus mechanisms, it keeps data secure, transparent, and immutable. It is now used widely in finance [1], healthcare [2], and energy [3]. Beyond its role as a ledger, blockchain data is inherently temporal. Every transaction carries a timestamp, and the chain imposes a total order. On-chain data thus forms time-series streams appended block after block, such as an account's transfer amounts, a trading pair's successive prices, or a contract's gas consumption. These ordered streams constitute the temporal view of on-chain data. Concretely, the record or=(tr,vr)o_r = (t_r, v_r) extracted from a transaction in block BrB_r carries a timestamp trt_r and a value vrv_r, such as a transferred amount. Grouped by source and ordered by time, such records form time-ordered streams.

Applications continuously query such streams. A regulator audits the sum of an account's transfers over a reporting window. A trader requests the min/max trade price in an interval. A protocol monitor asks for the average gas price over a sliding range. These reduce to two primitives, time-range retrieval and windowed aggregation over SUM, COUNT, MIN, MAX, and AVG. However, blockchains support only block-and transaction-level lookups [4]. Under sequential storage, even a single windowed aggregate forces a scan of every block in the window. As the chain grows to millions of blocks, every such query degrades to a full range scan.

We aim to enable expressive time-series queries on blockchains. This raises three challenges.

Challenge 1: How to organize blockchain time-series data for efficient querying. Existing studies offload blockchain data to high-performance external databases [5]–[9], but they target relational or graph workloads. A relational scheme flattens transactions into rows and tables, so a windowed aggregate either scans the window or maintains auxiliary indexes. A graph scheme serves topology traversals and has no native index over an ordered time interval. An on-chain stream moreover keeps appending block after block, and this write-heavy workload demands an index that keeps up with appends cheaply. Neither line of work indexes windowed aggregation over an ordered interval, the dominant time-series access pattern, without auxiliary scans.

Challenge 2: How to achieve efficient light-client verification of time-series query results. Whatever the off-chain scheme, data managed by the query layer is not trustworthy, for two reasons. First, unlike a blockchain, an off-chain store lacks

∗^{*}Corresponding author.

tamper-proof structures, so its data can be silently altered. Second, the query-layer operator is outside the blockchain consensus and may behave dishonestly, compromising completeness or soundness. Hence results must be verified. For an aggregate, verification means two things. Completeness requires that no in-range point is missing, so that the aggregate covers exactly the queried window. Soundness requires that every returned point lies on-chain and in-range. Re-downloading the window and recomputing [8] defeats the purpose for a light client. Without an authenticated structure, the client cannot detect a dropped or fabricated in-window record.

Challenge 3: How to make approximate answers from model representations verifiable. Time series also offer an opportunity absent from the graph and relational settings. Monitoring queries, such as the sliding-window gas average above, tolerate a bounded error yet are issued continuously and demand low latency. Time-series mining [10]–[13] in turn increasingly runs on compact model-based representations, from piecewise-linear approximation [14] to the representations learned by today's time-series models. Answering such queries from model parameters instead of records is orders of magnitude cheaper. Two obstacles stand in the way. The first is verification semantics. An answer computed from a representation carries no evidence that it reflects the data it claims to summarize. No prior verifiable-query system defines what completeness and soundness even mean when a value is reconstructed within an error bound rather than retrieved. The second obstacle, more fundamental once learned representations enter the picture, is trust. A model is an opaque, expensive, and often non-deterministic artifact [15]. Admitting one into a verifiable pipeline normally means enlarging the trusted computing base or asking a light client to re-run inference. Neither is acceptable.

To address these three challenges we propose VeriTS. For the first, VeriTS establishes an off-chain query layer that models on-chain data as ordered streams, where each record carries a timestamp, a value, and tags. This is the native model of production time-series databases [16], [17], and it enables logarithmic range and aggregation queries. For the second, VeriTS introduces a layered verification mechanism. The query layer answers queries. Miners on the blockchain layer authenticate the supporting structure and anchor its digest on-chain, so a light client verifies with a succinct verification object. For the third, VeriTS adds a verifiable approximate path that answers error-tolerant queries from authenticated model segments. Their digest is likewise anchored on-chain. The approximate path is an addition, not a replacement. The regulator's audit still demands a bit-exact sum. Heavy-tailed event streams compress too poorly for segments to pay. VeriTS therefore maintains both paths and lets the client choose per query. Concretely, the main contributions are summarized as follows.

• We present VeriTS, to our knowledge the first framework for verifiable time-series queries on blockchains. It alters no storage structure of the underlying blockchains.

• VeriTS represents blockchain data as per-source ordered streams over an authenticated aggregate interval tree. One structure serves as both the query index and the authenticated data structure, answering and certifying windowed aggregates in the same logarithmic bound.

• VeriTS verifies completeness through a minimum covering set with boundary proofs and soundness through subtree-embedded aggregate folding. Both extend to range and tag-constrained queries and to sliding windows.

• VeriTS further adds a verifiable approximate path over model segments authenticated by a segment-interval tree, redefining completeness and soundness under bounded error. The path is encoder-independent, so an untrusted encoder affects proof size and answer width but never correctness.

• An experimental study offers evidence that VeriTS is capable of outperforming baselines in terms of verification efficiency by more than two orders of magnitude and of reducing range-query proofs by up to 14.5×14.5\times.

Section II reviews related work. Section III gives preliminaries. Section IV presents the framework. Section V details verifiable query processing. Section VI presents the verifiable approximate path over model segments. Section VII analyzes security. Section VIII reports the experimental results. Section IX concludes.

References (34)