What problem does it solve?
Web analytics breakdowns fragment across thousands of near-identical URLs when teams never configure path cleaning. This Skill runs the automated health check that samples a team's real paths, asks an LLM for regex/alias cleaning rules, validates them against actual data, and stores them as reviewable suggestions.
Core Features & Use Cases
- Automated suggestion generation: Runs the
suggest_path_cleaning_rules management command or weekly health check across the web-analytics precompute cohort, with per-team gating for inactivity, existing configuration, and low path cardinality.
- Validation before storage: Compiles each suggested regex with re2 and test-applies it to sampled paths, dropping rules that fail to compile or match nothing.
- Review and apply workflows: Surfaces suggestions via a settings banner, onboarding step, health-issues API, and PostHog AI (Max) MCP tools, with manual apply that merges rules without overwriting.
- Use Case: A team with 5,000 distinct URL paths runs
python manage.py suggest_path_cleaning_rules --teams 2 --no-store to preview AI-suggested rules like /products/\d+ → /products/:id before deciding to apply them.
Quick Start
Ask the AI to run the path-cleaning suggestion check for a specific team and show the suggested regex rules with their match counts.