Capacity Forecasting

Predict future infrastructure needs with ML-driven capacity forecasting based on historical graph data.

Overview

Capacity forecasting uses machine learning models trained on your historical graph data to predict future infrastructure needs. The system analyzes resource growth patterns, usage trends, and seasonal variations to provide actionable capacity projections.

Forecasting models

ModelUse case
Time series (Prophet)Resource count and growth rate predictions
Linear regressionStorage and compute usage trends
Seasonal decompositionCyclical usage patterns (daily, weekly, monthly)
Exponential smoothingShort-term resource demand forecasting

Resource scaling

The forecasting engine analyzes resource growth across dimensions:

  • Resource count -- how many resources of each type are expected
  • Storage growth -- database, S3, and volume storage trends
  • Compute demand -- EC2, VM, and pod count projections
  • Network throughput -- bandwidth and connection count trends
  • Service expansion -- new service and microservice creation rates
# Query capacity forecast
GET /api/v1/ai/capacity-forecast?scope=production&horizon=90d

{
  "scope": "production",
  "horizon_days": 90,
  "predictions": [
    {
      "resource_type": "aws_ec2_instance",
      "current_count": 42,
      "forecast_90d": 58,
      "confidence_interval": { "lower": 52, "upper": 66 }
    },
    {
      "resource_type": "aws_rds_instance",
      "current_count": 12,
      "forecast_90d": 15,
      "confidence_interval": { "lower": 13, "upper": 18 }
    }
  ]
}

Cost projections

Capacity forecasts are translated into cost projections:

  • Compute costs -- projected EC2/VM costs based on instance type mix
  • Storage costs -- S3, EBS, and database storage cost projections
  • Data transfer -- network egress cost estimates
  • Reserved instance planning -- recommendations for RI/CUD purchases
  • Budget alerts -- proactive alerts when projected costs exceed thresholds

Recommendations

Based on forecasts, the system generates actionable recommendations:

  • Right-sizing -- downsizing over-provisioned resources predicted to remain underutilized
  • Reserved capacity -- purchasing reserved instances for stable, predictable workloads
  • Auto-scaling -- configuring auto-scaling groups for resources with variable demand
  • Deprovisioning -- identifying resources with declining usage for cleanup
Forecast accuracy
Forecast accuracy depends on the quality and duration of historical data. A minimum of 30 days of data is recommended for reliable short-term forecasts, and 90+ days for long-term projections.