You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Pass 1 offers CountSketch for a count, but the executor cannot evaluate a CountSketch total #727
Stage 3 marks P3 valid ("accepted absolute_stream_l2 (CountSketch)", cost 0.00254/s, against 0.0000733/s for exact P1). P3 is only rejected because it costs more.
If P3 were selected (for example, if the exact plan were priced higher), lowering would fail. validate_sketch_evaluation (crates/asap-physical-operators/src/capability.rs) accepts a bare PointCount { value: None } only for Count-Min, Hll, Kmv, DDSketch and UnivMon; for CountSketch it returns "evaluation is not implemented for this summary family".
Expected: no CountSketch candidate for a count, or a CountSketch total the executor can evaluate.
Cause
realizations_for_intent (crates/asap-aware-mapping/src/realization.rs) maps AggIntent::Count to [Cms, CountSketch, UnivMon].
The CountSketch accuracy model (count_sketch_l2_median_binomial_v1) then gives the total a single-item point-query bound, ε‖f‖₂, which is not a contract for a total.
The family-capability table has no (Total, …) row for CountSketch. Its merged_error keeps a fallback default for unanswered statistics only so that this candidate's paned guarantee stays as it was.
Proposal
Drop CountSketch from AggIntent::Count. A CountSketch's signed counters don't add up to the total, and Count-Min and UnivMon already cover counts. Then remove the merged_error fallback, so a statistic the family doesn't answer fails closed (None).
The alternative is an executor kernel plus an accuracy contract for a CountSketch total, and then a (Total, AsIfBuiltOverUnion) row.
Scope / acceptance
The example above lists no CountSketch candidate.
merged_error returns None for any statistic outside the family's row, and the family_capability_table test asserts it for every row.
Examples 1–4 select the same plans at the same costs.
Status / related
Found while reviewing #724, which keeps the fallback so behaviour is unchanged. Related: #696, #707.
Activity