-
Notifications
You must be signed in to change notification settings - Fork 1
Closed
Labels
priority:mediumMedium priorityMedium prioritysource:backlog-stewardAuto-created by Backlog Steward skillAuto-created by Backlog Steward skillstatus:in-progressTask is in progressTask is in progresstask:implementationImplementation workImplementation work
Description
Source
- Type: ROADMAP
- Location:
ROADMAP.md:294(Phase 10 — Structured Storage Backend) - Original text: Aggregation queries for analytics (replace in-memory
loadAllEvents()pattern)
Task Description
Implement aggregation queries in the SQLite storage backend that replace the current in-memory loadAllEvents() pattern used by src/analytics/. Today, the analytics engine loads all events from JSONL files into memory before computing aggregations — this does not scale as session count grows.
With the SQLite backend (see #169, #170), aggregation queries should run directly in the database:
- Violation counts grouped by invariant, action type, or time window
- Escalation frequency by session
- Blast radius distribution histograms
- Top-N most denied actions across sessions
This enables the analytics engine (src/analytics/engine.ts, src/analytics/aggregator.ts) to delegate heavy computation to SQLite rather than loading entire event histories into memory.
Depends on: #169 (SQLite adapter), #170 (schema design)
Labels
Created automatically by the Backlog Steward skill.
Discovered by backlog-steward on 2026-03-10T00:00:00Z
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
priority:mediumMedium priorityMedium prioritysource:backlog-stewardAuto-created by Backlog Steward skillAuto-created by Backlog Steward skillstatus:in-progressTask is in progressTask is in progresstask:implementationImplementation workImplementation work