CounterSnake: A lossless and generalized compression framework for diverse sketches
Xunpeng Liu, Qun Huang, Yaojing Wang, Lihua Miao, Chen Sun
Abstract
Sketches are vital for large-scale stream analytics. However, they often use fixed-size counters, which remain underutilized, especially under skewed data distributions. Prior solutions to address this inefficiency compromise on accuracy, real-time operations, or generality, which limits their applicability. In this paper, we propose CounterSnake, a novel hierarchical compression framework that reduces the memory consumption of sketch counters. Compared with existing efforts, CounterSnake is the first one to fulfill four key requirements: (1) zero counter error, (2) bounded latency, (3) full counter interfaces, and (4) efficient multi-sketch optimization. The key idea is to dynamically link overflowing counters across layers to form variable-size logical counters. Besides, we design techniques such as tag-based linking, d-way mapping, sign-bit encoding, and virtual-counter abstraction to address the four requirements. We also theoretically derive its memory and time complexities under justified assumptions. Experiments against six SOTA solutions demonstrate up to several orders of accuracy improvements and comparable operation throughput. We also thoroughly evaluate CounterSnake and other frameworks, showing that CounterSnake is the only one that fulfills all the requirements.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 9be4ec93-b0b8-46ed-818c-d31feaf8b2b6Builds on20
- WavingSketch: An Unbiased and Generic Sketch for Finding Top-k Items in Data StreamsJizhou Li, Zikun Li, Yifei Xu, Shiqi Jiang et al.KDD 2020 · 96 citations
- Toward Nearly-Zero-Error Sketching via Compressive SensingQun Huang, Siyuan Sheng, Xiang Chen, Yungang Bao et al.NSDI 2021 · 82 citations
- BurstSketch: Finding Bursts in Data StreamsZheng Zhong, Shen Yan, Zikun Li, Decheng Tan et al.SIGMOD 2021 · 58 citations
- Stingy Sketch: A Sketch Framework for Accurate and Fast Frequency EstimationHaoyu Li, Qizhi Chen, Yixin Zhang, Tong Yang et al.VLDB 2022 · 54 citations
- DHS: Adaptive Memory Layout Organization of Sketch Slots for Fast and Accurate Data Stream ProcessingBohan Zhao, Xiang Li, Boyu Tian, Zhiyu Mei et al.KDD 2021 · 47 citations
Related papers
- Sublime: Sublinear Error & Space for Unbounded Skewed StreamsNavid Eslami, Ioana O. Bercea, Rasmus Pagh, Niv DayanSIGMOD 2026
- BitMatcher: Bit-level Counter Adjustment for SketchesQilong Shi, Chengjun Jia, Wenjun Li, Zaoxing Liu et al.ICDE 2024 · 22 citations
- BitSense: Universal and Nearly Zero-Error Optimization for Sketch Counters with Compressive SensingRui Ding, Shibo Yang, Xiang Chen, Qun HuangSIGCOMM 2023 · 25 citations
- Single Update Sketch with Variable Counter StructureDimitrios Melissourgos, Haibo Wang, Shigang Chen, Chaoyi Ma et al.VLDB 2023 · 16 citations
- AlignSketch: A Framework for Aligning Theoretical and Practical Estimation ErrorsCe Zheng, Hanyue Zheng, Jingwei Shi, Xinye Xu et al.ICDE 2026
