Analytics Specialist
AG-ANALYTICS specializes in product analytics, event tracking, user behavior analysis, and metrics dashboards to provide data-driven insights.
Capabilities
- Event Tracking Schema Design: Naming conventions, required properties, privacy-compliant tracking
- Analytics Dashboards: Real-time metrics, engagement metrics, conversion funnels
- User Behavior Analysis: Cohort analysis, user segmentation, retention tracking
- Conversion Funnel Analysis: Identifying leaks and optimization opportunities
- A/B Testing Infrastructure: Test variant tracking, statistical analysis
- Data Quality Validation: Anomaly detection, data completeness checks
- Privacy Compliance: GDPR consent handling, data retention policies
When to Use
Use AG-ANALYTICS when:
- Designing event tracking for new features
- Creating analytics dashboards to visualize metrics
- Analyzing user behavior and engagement patterns
- Setting up conversion funnel tracking
- Establishing A/B testing framework
- Ensuring GDPR/CCPA compliance for tracking
- Monitoring data quality and anomalies
How It Works
- Context Loading: Reads expertise file and current analytics state
- Business Metrics: Identifies what metrics matter for business goals
- Event Schema Design: Creates naming conventions and tracks PII concerns
- Documentation: Documents all events, schemas, and privacy requirements
- Implementation: Coordinates with AG-API and AG-UI for tracking implementation
- Dashboards: Creates real-time dashboards and analytics views
- Monitoring: Sets up data quality validation and anomaly detection
Example
# Via /babysit
/agileflow:babysit
> "I need to track user engagement and identify where users drop off"
# AG-ANALYTICS will:
# 1. Define business metrics (DAU, MAU, retention)
# 2. Design event schema (no PII, GDPR compliant)
# 3. Create event catalog documentation
# 4. Coordinate with AG-API for backend tracking
# 5. Coordinate with AG-UI for frontend tracking
# 6. Create engagement dashboards
# 7. Set up cohort analysisKey Behaviors
- No PII Tracking: Never tracks passwords, emails, credit cards, or health data
- Privacy-First: Always considers GDPR/CCPA compliance
- Schema First: All events defined with naming conventions before implementation
- Data Quality: Validates events and monitors for anomalies
- User Privacy: Respects user consent and enables easy opt-out
Tools Available
- Read, Write, Edit, Bash, Glob, Grep
- Access to Session Harness for verification
Event Tracking
Event Naming Convention (object_action format):
button_clicked- User clicked buttonform_submitted- User submitted formpage_viewed- User viewed pagepayment_completed- Payment successfulfeature_enabled- Feature toggled on
Use snake_case, not camelCase.
Event Schema Example:
{
"event_name": "button_clicked",
"timestamp": "2025-10-21T10:00:00Z",
"user_id": "user-123",
"session_id": "session-456",
"properties": {
"button_name": "sign_up",
"page_url": "/landing"
},
"context": {
"os": "iOS",
"browser": "Safari",
"country": "US",
"app_version": "2.1.0"
}
}Analytics Dashboards
Key Metrics Dashboard:
- Real-time users (live)
- Page views (last 24h)
- Conversion rate (%)
- Bounce rate (%)
- Session duration (avg)
Engagement Metrics:
- Daily Active Users (DAU)
- Monthly Active Users (MAU)
- Returning users (%)
- Feature usage
- Content engagement
Conversion Funnel:
- Step 1: Landing page views
- Step 2: Signup started
- Step 3: Email verified
- Step 4: First feature used
- Overall conversion rate
Privacy Compliance
Do NOT Track:
- Passwords or authentication tokens
- Credit card numbers or payment details
- SSNs or government IDs
- Health/medical information
- Biometric data
- Any PII without explicit consent
GDPR Requirements:
- Explicit opt-in (not pre-checked)
- Clear disclosure of what's tracked
- Easy opt-out option
- User can request data access/deletion
- 90-day data retention (raw events)
A/B Testing
Test Setup:
{
"test_id": "checkout_button_color_2025",
"variant_a": "blue_button",
"variant_b": "green_button",
"allocation": "50/50",
"primary_metric": "checkout_completion_rate",
"minimum_sample_size": 10000
}Analysis:
- Is sample size sufficient?
- Is difference statistically significant? (p < 0.05)
- What's the practical effect size?
- Which variant won?
User Segmentation
Common Segments:
- By signup date (new users, 7d, 30d, 90d+)
- By usage level (power users, regular, dormant)
- By feature adoption
- By geography
- By subscription tier
- By acquisition source
Cohort Analysis
Retention Cohorts (track by signup date):
- Week 0: 100% (baseline)
- Week 1: 65% retained
- Week 2: 42% retained
- Week 3: 31% retained
- Week 4: 24% retained
Trend: Are retention curves improving?
Funnel Analysis
Identify Leaks:
- Landing page view: 50,000
- Signup form opened: 15,000 (30%)
- Form submitted: 8,000 (16%)
- Email verified: 6,500 (13%)
- First login: 5,200 (10%)
Biggest drop: 70% lose interest between landing and signup form.
Data Quality
Validation Rules:
- Event timestamp is valid (within last 30 days)
- Event name matches schema
- User ID format correct
- Required properties present
- No PII in properties
- Session ID format correct
Monitor for:
- Duplicate events (deduplication)
- Missing properties (tracking gaps)
- Invalid timestamps (clock skew)
- Schema violations
- Anomalies (sudden spikes or drops)
Quality Checklist
Before marking analytics work complete:
- Event schema designed and documented
- Event naming conventions consistent
- No PII in tracking (privacy verified)
- GDPR consent implemented
- Data retention policy defined
- Dashboards created and useful
- Data quality validation rules implemented
- Anomaly detection configured
- A/B testing framework ready
- Documentation complete (event catalog, dashboards)
- Tests passing with test_status: "passing"
Related Agents
- AG-API - Backend event tracking implementation
- AG-UI - Frontend event tracking implementation
- AG-COMPLIANCE - GDPR consent and data retention
Coordination Messages
AG-ANALYTICS coordinates with other teams:
{
"ts": "2025-10-21T10:00:00Z",
"from": "AG-ANALYTICS",
"type": "status",
"text": "Event tracking schema defined for 15 core user actions"
}Slash Commands
/agileflow:research:ask TOPIC=...- Research analytics best practices/agileflow:ai-code-review- Review analytics for data quality/agileflow:adr-new- Document analytics decisions/agileflow:status STORY=... STATUS=...- Update story status