Skip to content

docs(monitor): when to use whole-sketch (agg_id) vs single-point (agg_id,key) - #380

Closed
zzylol wants to merge 1 commit into
mainfrom
docs/monitor-selection-criterion
Closed

zzylol wants to merge 1 commit into
mainfrom
docs/monitor-selection-criterion

Conversation

@zzylol

@zzylol zzylol commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

Adds the decision rule to monitor/mod.rs: a point estimate's error is bounded by the sketch norm, so when the queried point isn't known a priori (ad-hoc point queries) you must monitor/sample on the whole-sketch norm — one CDM per sketch, keyed by agg_id, sampling on the edge's whole local norm ‖f_i‖ (f2::DistributedF2Monitor). cms_point's (agg_id,key) is only for a pre-declared standing alert on a specific x, never to back a general query surface. Includes the CDM/OctoSketch (whole-sketch) vs Cormode (single-function) framing.

Follow-up doc to #378. No code change.

🤖 Generated with Claude Code

… (agg_id,key)

Document WHY the monitor identity differs: a point estimate's error is bounded by
the sketch NORM (CMS: f̂(x)≤f(x)+ε‖f‖₁; Count-Sketch: |f̂(x)−f(x)|≤ε‖f‖₂), so when
the queried point is NOT known a priori (ad-hoc point queries) you must bound the
whole-sketch norm — one CDM per sketch, keyed by agg_id, sampling on the edge's
whole local norm ‖f_i‖ (f2::DistributedF2Monitor). cms_point's (agg_id,key) is
only for a PRE-DECLARED standing alert on a specific x, never to back a general
query surface. Notes the CDM/OctoSketch (whole-sketch) vs Cormode (single-function)
framing and maps geometric safe-zone ↔ slack countdown to the two cases.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@zzylol

zzylol commented Jun 17, 2026

Copy link
Copy Markdown
Contributor Author

Superseded by the sampling unification (branch feat/monitor-f2-live): both the cms_point √(f/rate) and the whole-sketch √(F2/rate) sampling laws were retired — there is now ONE law, the whole-sketch ε-floor p=1/(1+ε²·rate). The corrected monitor/mod.rs doc (two orthogonal axes + HLL exception) ships in that PR. Closing as obsolete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant