Forecasting
AuraScore 81/100

Multimodal Inference Capacity and GPU Cluster Provisioning Simulation Script

Generate an automated capacity forecasting and discrete-event GPU simulation script for multimodal diffusion workloads.

Use this template when planning infrastructure scale for text-to-image generation endpoints under fluctuating prompt concurrency. It produces a production-ready Python simulation and capacity planning script.

Template

Role: Principal MLOps Data Scientist with 12+ years optimizing high-throughput distributed diffusion inference clusters.

Context

  • Cluster Infrastructure: {{inference_cluster_config}}
  • Historical Ingestion Metrics: {{historical_prompt_traffic_log}}
  • Sampling Profiles: {{diffusion_step_parameters}}
  • Target Thresholds: {{peak_sla_latency_target}}
  • Forecasting Window: {{forecast_horizon_weeks}}
  • Demand Trajectory: {{target_concurrency_growth_rate}}

Task

Develop an enterprise-grade Python predictive modeling and discrete-event simulation script that forecasts GPU node exhaustion, cold-start queuing bottlenecks, and dynamic autoscaling thresholds for text-to-image and multimodal generation endpoints over {{forecast_horizon_weeks}}.

Method

  1. Ingest {{historical_prompt_traffic_log}} to fit a non-homogeneous Poisson process capturing prompt arrival spikes and diurnal seasonality.
  2. Parameterize GPU memory allocation, KV-cache behavior, and step execution time across hardware nodes defined in {{inference_cluster_config}}.
  3. Model prompt complexity variances (aspect ratios, batch sizes, guidance scales) using the distribution in {{diffusion_step_parameters}}.
  4. Apply compound growth over {{forecast_horizon_weeks}} based on {{target_concurrency_growth_rate}}.
  5. Run a Monte Carlo discrete-event simulation tracking queue formation, GPU VRAM fragmentation, and TTFT (time-to-first-token/tile).
  6. Compute SLA violation likelihood against {{peak_sla_latency_target}} across P50, P95, and P99 intervals.
  7. Generate dynamic autoscaler rules providing optimal scale-out triggers that minimize under-provisioned dropouts and idle compute costs.
  8. Export summary capacity tables, confidence intervals, and JSON configuration payloads for orchestrator deployment.

Constraints

  • Code MUST be written in executable, modular Python 3.11+ using standard scientific libraries (NumPy, SciPy, SimPy, Pandas).
  • The script MUST output parameterized CLI arguments and include structured docstrings for all mathematical formulations.
  • MUST NOT use stubbed mock algorithms or truncated placeholder functions.
  • Hardcode fallback thresholds if empirical distributions fail convergence checks.

Output format

Executable Python script organized into:

  1. Configuration and Data Ingestion Classes
  2. Statistical Arrival and Workload Engine
  3. Discrete-Event Simulation Pipeline
  4. Capacity Reporting & SLA Violation Forecaster
  5. CLI Interface and Main Execution Block (150-250 lines total code structure)

Self-review

  • Confirm that all formulas account for variable denoising step latencies in {{diffusion_step_parameters}}.
  • Verify that the simulation monitors both GPU compute saturation and VRAM ceiling limits from {{inference_cluster_config}}.
  • Check that P95/P99 latency calculations strictly reflect the constraints in {{peak_sla_latency_target}}.
AuraScore breakdown
81/100Provisional
Instruction clarity15/15 · Strong

Explicit role, a named task, and discrete steps the model can follow.

Context architecture12/12 · Strong

Background, inputs and variables the model needs before it starts.

Constraint engineering10/12 · Adequate

Hard boundaries — what the model must and must not do.

Output specification6/14 · Thin

A named, field-level shape for the response.

Reasoning structure10/10 · Strong

Ordered work items that force analysis before an answer.

Model compatibility10/10 · Strong

Length and structure that travel across frontier models.

Token efficiency5/10 · Thin

Signal density — instruction weight without padding.

Reusability7/7 · Strong

Documented variables so the scaffold adapts to new inputs.

Robustness5/5 · Strong

Quality bar, assumptions and behaviour when inputs are thin.

Observed performance1/5 · Thin

How much real usage the template has behind it.

data-analytics
data-forecasting
image-multimodal-prompting
capacity-planning
diffusion-inference
gpu-forecasting