This paper, a collaboration between Google Research and UC Berkeley, provides a comprehensive theoretical framework for privately counting distinct and $k$-occurring items in streaming data. By establishing nearly tight upper and lower bounds, the authors solve a decade-old open problem and clarify the fundamental privacy-utility trade-offs in time-varying datasets.
Introduction
In many real-world applications—like measuring the "reach" (distinct users) and "frequency" (users seen $k$ times) of an ad campaign—data arrives as a stream over time. Analysts often need to query this data over specific intervals:
- Cumulative: From the beginning of time to now.
- Fixed-Window: The last $W$ time steps (a sliding window).
- Time-Window: Any arbitrary interval $[t_1, t_2]$.
The challenge is providing accurate counts while satisfying Differential Privacy (DP). The paper distinguishes between two privacy "neighboring relations": Event-level DP, which protects a single occurrence of an item at a specific time, and Item-level DP, which protects all occurrences of a specific item across the entire time horizon. While cumulative counting was relatively well-understood, sliding windows and arbitrary time windows lacked tight bounds until this work.
Methodology
The core technical contribution lies in reductions to the Range Query problem. Instead of building a "distinct counter" from scratch, the authors show how to transform the streaming problem into a geometric one:
- Cumulative Queries $\rightarrow$ 1D Range Queries: An item is counted if its $k$-th occurrence happens before time $t$. This maps directly to counting points in a 1D interval.
- Time-Window Queries $\rightarrow$ 2D Range Queries: To avoid double-counting items that appear multiple times, the authors use a "complement" perspective. They count "gaps" between occurrences; if the gap between the $\ell$-th and $(\ell+k)$-th occurrence spans the entire query window, the item is not $k$-occurring in that window.
- Fixed-Window Queries: The authors show that for a fixed window of size $W$, the problem can be simplified back to 1D range queries by partitioning the time horizon into sub-instances of size $2W$.
For Item-level DP, where one user's change affects many time steps, they employ advanced privacy composition theorems to manage the privacy budget across these overlapping windows.
Key Results and Insights
The paper provides a comprehensive "menu" of bounds, establishing the first nearly tight error bounds for counting distinct and $k$-occurring items across various time-window models.
Solving the Bolot et al. (2013) Open Question
Previous work suggested that sliding window error might have to grow polynomially with $W$. This paper proves that for event-level DP, the error is only polylogarithmic in $W$ ($O(k \log^{1.5} W)$). This demonstrates that high-utility sliding window queries are possible under event-level privacy.
The Event vs. Item Gap
A critical insight is the massive jump in difficulty between privacy levels. Under event-level DP, error is polylogarithmic. However, under item-level DP, the error must grow polynomially (e.g., $\sqrt{T}$ or $T/W$), meaning "user-level" privacy is fundamentally much "noisier" in a streaming context. The authors provide matching (or nearly matching) lower bounds, showing that these errors are essentially the best achievable.
Limitations and Future Work
While this work establishes fundamental limits, several avenues for future research remain:
- Tightening Polylog Factors: There are still small gaps in the polylogarithmic factors (e.g., $k \log^{1.5} W$ vs. $k + \log^{1.5} W$).
- "White-box" Algorithms: The current results rely on reductions to range queries. Direct algorithms specifically designed for counting might yield better constants or simpler implementations.
- Memory Constraints: This work focuses on the privacy-utility trade-off. Combining these DP bounds with space-efficient sketches (like HyperLogLog) is a natural next step for high-speed streaming applications.
Summary updated