Repository navigation
Final TODOs for Greedy optimizer #523
Copy link
Copy link
Closed as not planned
Labels
Description
Non-empirical gaps in the Phase 2 greedy solver (asap-planner-rs/src/optimizer/), separate from plugging in real numbers:
- Costs are param-invariant:
ingest_cost/query_costignore sketch params (CMS depth/width, KLL K, HLL precision, heap size) — the wholecandidate_genparameter grid is cost-invisible today. (Optimizer: param-aware atomic costs from sketch-bench #524) - No accuracy/error-bound modeling:
SketchPropertiestracks mergeable/subtractable/subpopulation_aware but nothing about error guarantees, so greedy can pick the smallest param combo with no accuracy constraint. (Optimizer: CMS accuracy constraint (ACC) using accuracy_sla #526, Optimizer: extend sketch-bench cardinality sweep for empirical Error beyond CMS #566) subpopulation_counthardcoded to1.0in both cost functions — subpop-aware vs non-aware currently behave identically. (Optimizer: auto-infer N_g from Prometheus #525)- No cross-AQE sharing (facility-location) — greedy assigns every AQE independently, deferred to the Phase 3 MIP. (No cross-AQE sharing — greedy deploys one sketch per AQE even when they could share #650, blocked by labels_compatible() is exact-match only, not superset matching #649 label superset matching)
- Multi-statistic AQEs (e.g.
avg= Sum+Count) unsupported — always falls back to EXACT. (planner/optimizer: decide support for multi-statistic AQEs (e.g. avg) #419, Support Avg (and other multi-statistic aggregations) in query engine #463) candidate_gen.rshardcodesaggregation_id = 0, to be replaced by the greedy/MIP solver's assignment. (Optimizer: candidate_gen.rs hardcodes aggregation_id = 0 #564)translator.rs's output structs are empty/stub pending Phase 2/3 sketch configs. (Optimizer: translator.rs output structs are empty stubs #565)
For empirical calibration (tracked separately/later):
- Per-config atomic costs as functions of sketch params (not flat constants) — from sketch-bench. (Optimizer: param-aware atomic costs from sketch-bench #524, CountMinSketchWithHeap still costs at the flat stub — cms-heap wrapper exists but isn't wired up #651 for CountMinSketchWithHeap specifically)
-
CostWeightsfrom real cloud$/byte-sec and $ /cpu-sec. (CostWeights are a self-consistent stub, not real $/byte-sec vs $/cpu-sec #647) -
arrival_rate_hzper (metric, spatial filter) from Prometheus scrape interval × series count. (Optimizer: arrival_rate_hz is a flat placeholder, not derived from Prometheus #563) -
subpopulation_countper config from Prometheus series cardinality. (Optimizer: auto-infer N_g from Prometheus #525)
Reactions are currently unavailable
Activity
[-]Greedy optimizer: TBDs beyond cost calibration[/-][+]Final TODOs for Greedy optimizer[/+]milindsrivastava1997 commentedon Oct 26, 2026
Superseded by the rqe-optimizer MILP (ProjectASAP/sketch-bench#129, #794); the greedy optimizer was removed in #807. Remaining work tracked under #790 / ProjectASAP/sketch-bench#143. Still-open children: #463 (Avg in engine, #790 A3b), #525 and #563 (to be re-scoped to the MILP facts file).