Repository navigation
Closed
Description
Goal
Run ASAP's plans from the AutoSketch vs. ASAP evaluation (ProjectASAP/ASAPQuery#777, results in #203) end to end with ASAPQuery's experiment_run_e2e. ASAPQuery converts a saved plan into StreamingConfig / InferenceConfig; it does not re-solve. This issue covers what sketch-bench has to emit for that.
ASAPQuery side: ProjectASAP/ASAPQuery#824
Why the current outputs aren't enough
autosketch_vs_asap --no-chosendrops the plans. Even withchosen, a per-RQE entry has the sketch, params, window and slide, but not the deployment's capability, metric or grouping (deployment_groupingappears only on roll-ups and Hydra).- The workload tables (
inputs/tables/*.json,scripts/export_autosketch_eval_table.py) have no PromQL. Grouping is shorthand instream(job/value,label_0/increment,series/dist), and the metric's label schema isn't written anywhere.
TODO
- P1. Plan file (done in eval: AutoSketch vs. ASAP with Hydra candidates and a roll-up ablation (§6.3) #203:
rqe-optimizer/results/autosketch-vs-asap-hydra/plans/<table>.plans.json.gz, hand-written JSON; see the README's "Plans" section)autosketch_vs_asapwrites one self-contained plan per exported point: adeploymentslist (capability, metric, grouping labels, spatial filter, sketch,sketch_config,window_ms,slide_ms) plus an RQE id → deployment index map.- Prefer
#[derive(Serialize, Deserialize)]on the rqe-optimizer types the plan already uses (Deployment,PlannedDeployment,PlannedRaqe) over a hand-written JSON shape, so ASAPQuery reads the same types it already depends on. - Points to export: ASAP's cheapest plan per weight setting; SLA points optional (see Decisions).
- P2. PromQL and labels in the workload table (done in eval: PromQL and metrics for end-to-end runs in classic tables (#204 P2) #208:
workloads[0].e2ein the four classic tables)export_autosketch_eval_table.py --syntheticadds one workload-level block,e2e, that the runner does not read. The rest of the table stays byte-identical, so the committed plans inplans/still match it. (The existingschemasand per-RQEgroupingfields are not reused for classic:autosketch_vs_asapreads them, and filling them puts a stream's groupings on one metric, which allows roll-ups and changes the plans.)e2e.queries: [{promql, interval_secs, rqes: [ids]}]. A list because a binary query (template 10) reads two RQEs and has no ids of its own (it is deduplicated into template 5's p0.9 and p0.5). This is also the query → aggregations shape the inference config wants.e2e.metrics:data(gauge) anddata_total(counter), each with labels in theschemasformat:job(cardinality 10) andlabel_0(cardinality 1000,child_of: job, so 1e4 series), plus 200 samples/s per series and the value shape (Zipf 1.1 keys, Pareto a = 2).- No per-RQE grouping is needed: ASAPQuery reads each query's grouping, statistic and top-k key from the PromQL with its existing extractor, given
e2e.metrics' labels. - Check: the regenerated classic tables minus
e2eequal the committed ones. - Templates 1–10 (classic) first; the PromQL is listed in ASAPQuery#777 §6.
- Query id → PromQL (
wfromrange,qfrom the_p{q}suffix):query_idPromQL sum_by_jobsum by (job) (data)quantile_by_job_p{q}quantile by (job) (q, data)topk32_sum_by_label0_sum_over_timetopk(32, sum by (label_0) (sum_over_time(data[w])))sum_over_timesum_over_time(data[w])quantile_over_time_p{q}quantile_over_time(q, data[w])raterate(data_total[w])sum_by_job_ratesum by (job) (rate(data_total[w]))sum_by_job_sum_over_timesum by (job) (sum_over_time(data[w]))topk32_sum_by_label0_ratetopk(32, sum by (label_0) (rate(data_total[w])))(template 10) quantile_over_time(0.9, data[w]) / quantile_over_time(0.5, data[w])→ the p0.9 and p0.5 RQEs
- P3. Rerun and commit plans (done in eval: AutoSketch vs. ASAP with Hydra candidates and a roll-up ablation (§6.3) #203: every table in
plan.tsv, cheapest and SLA plans per method and weight setting)- Rerun without
--no-chosen, classic r = 1, m = 1 first, then the rest ofplan.tsvas needed. - Commit the plan files next to the results in
rqe-optimizer/results/autosketch-vs-asap-hydra/.
- Rerun without
Decisions
Settled 2026-10-11:
- Arrival rate. e2e runs at the eval's 2e6 samples/s, so the committed plans are used as is.
- Where PromQL lives. sketch-bench's export script, next to the templates (P2). ASAPQuery does not keep its own copy.
- Template 10 is included. In the classic ASAP plan its two operands share one deployment. If a plan splits them, ASAPQuery's converter refuses the query (
QueryOnTwoDeployments), which is acceptable. - Gauge and counter are split.
datais a gauge (value and dist streams: sums, quantiles, top-k by sum);data_totalis a counter (increment stream:rate). The RQEs already put these on different streams, so sharing and the plans don't change. e2e ingests both, each at 2e6 samples/s. - Spatial templates stay
sum by (job) (data). We assume every series has a sample at every scrape, so the instant query and the eval's 1 s window agree.
Open (none left):
Which points to export: cheapest plan only, or also SLA points.Settled: eval: AutoSketch vs. ASAP with Hydra candidates and a roll-up ablation (§6.3) #203 exports both (kind: "cheapest"andkind: "sla"); ASAPQuery#824 B2 picks one with--kind.
Out of scope: roll-up and Hydra plans. The engine can't serve them yet (ASAPQuery#814), so multi-grouping and all are not exported for now.
Metadata
Metadata
Assignees
Labels
No labels
Activity
eval: PromQL and metrics for end-to-end runs in classic tables (#204 …
milindsrivastava1997 commentedon Oct 11, 2026
P1 and P3 done in #203, P2 in #208. The ASAPQuery side continues in ProjectASAP/ASAPQuery#824.
eval: e2e block for multi-grouping and all tables (#209)
eval: drop classic templates 7 and 9 (rates by job, top-k by rate) (#210
eval: §6.3 workloads re-planned at 10 samples/s for the end-to-end run (