avantgardnerio opened a new pull request, #2180:
URL: https://github.com/apache/datafusion-ballista/pull/2180

   ## Summary
   
   - New module `ballista_core::kll::KllSketch<T: Ord + Clone>` — native Rust 
KLL quantile sketch, generic over ordered items, composes with 
`arrow::row::OwnedRow` for the full ORDER BY grammar (multi-column, nullable, 
per-column ASC/DESC).
   - Design ported from Apache DataSketches C++ (`kll_helper.hpp`): shrinking-k 
per level so total retained items is bounded ~`3k` regardless of stream size, 
keep-smallest odd-length compaction preserves the total-weight invariant, 
min/max side-tracked for exact `quantile(0.0)` / `quantile(1.0)`, 
walk-all-levels compaction driver so `merge` folds cleanly when several levels 
land over their (shrinking) capacities at once.
   - Standalone — not wired into any caller yet. `RuntimeStatsExec` swap (per 
its existing TODO on `runtime_stats.rs:39`) is a follow-up PR.
   
   ## Test plan
   
   - [ ] `cargo test --lib -p ballista-core kll::` — 11 tests passing locally
   - [ ] `cargo clippy --all-targets` and `cargo fmt --check` clean
   - [ ] Follow-up PR: wire into `RuntimeStatsExec::quantile_sketch()` and 
`merged_quantile_sketch()`, replacing the TDigest
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to