Analytics Overview

Track usage, costs, performance, and security metrics across all your AI integrations.

What Analytics Does Cencori Provide?

Cencori's analytics dashboard gives you complete visibility into your AI usage:

  • Request volume and trends
  • Cost breakdown by model and provider
  • Performance metrics (latency, success rate)
  • Security incident tracking
  • User behavior patterns

Key Metrics

Total Requests

Number of AI requests processed. Track growth over time and identify usage patterns.

Success Rate

Percentage of successful requests vs. errors. A healthy app should have >95% success rate.

Total Cost

Cumulative spend across all AI providers. Includes provider costs + Cencori markup.

Average Latency

Time from request to response. Lower is better for user experience.

Security Incidents

Count of blocked or flagged requests (PII, prompt injection, content filter).

Charts and Visualizations

Requests Over Time

Line chart showing daily/weekly/monthly request volume. Identify growth trends and seasonal patterns.

Cost Breakdown

Pie/bar chart showing costs by model (GPT-4o, Claude, Gemini). Identify expensive models.

Model Usage

Bar chart showing request distribution across models. See which models are most popular.

Security Dashboard

Donut chart showing incident types (PII, injection, content filter). Monitor threat distribution.

Performance Heatmap

Latency distribution by time of day. Identify peak traffic hours.

Filtering and Segmentation

Slice analytics data by multiple dimensions:

  • Time Range: Last 7/30/90 days or custom range
  • Model: Filter by specific AI models
  • Provider: Compare OpenAI vs. Anthropic vs. Google
  • API Key: Track usage per application/environment
  • Status: Success vs. error requests
  • User: Analyze per-user behavior (if user IDs tracked)

Common Analytics Use Cases

Cost Optimization

Identify which models are driving costs:

  1. View cost breakdown chart
  2. Identify expensive models (e.g., GPT-4 Turbo)
  3. Consider switching to GPT-3.5 or Gemini Flash for simple tasks

Performance Debugging

Find slow requests:

  1. Filter logs by latency >5 seconds
  2. Check which models are slowest
  3. Optimize prompts or switch providers

Capacity Planning

Prepare for growth:

  1. View requests-over-time trend
  2. Extrapolate future volume
  3. Budget for expected costs

Security Monitoring

Track attack attempts:

  1. View security incidents chart
  2. Identify spike in prompt injection attempts
  3. Investigate source and tighten security

Accessing Analytics Programmatically

fetch-analytics.ts

Best Practices

  • Review analytics weekly to catch issues early
  • Set up cost alerts to avoid budget overruns
  • Track success rate—investigate if it drops below 95%
  • Compare model performance before making changes
  • Export data monthly for long-term trend analysis
  • Share analytics with stakeholders (product, finance, security teams)