llm-inference-scaling

Scale LLM inference clusters on Kubernetes using KEDA and GPU metrics.

46|4|Updated Jan 27, 2026
One-click install
npx skills add https://github.com/BagelHole/DevOps-Security-Agent-Skills --skill llm-inference-scaling
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: llm-inference-scaling
Source: https://github.com/BagelHole/DevOps-Security-Agent-Skills/tree/main/infrastructure/local-ai/llm-inference-scaling
Command: npx skills add https://github.com/BagelHole/DevOps-Security-Agent-Skills --skill llm-inference-scaling

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill addresses the challenge of efficiently scaling Large Language Model (LLM) inference workloads on Kubernetes, ensuring high availability and cost-effectiveness.

Core Features & Use Cases

  • Automated Scaling: Dynamically adjusts the number of inference pods based on real-time traffic and resource utilization using KEDA and Prometheus metrics.
  • GPU-Aware Autoscaling: Leverages custom GPU metrics to scale inference clusters effectively.
  • Cost Optimization: Integrates strategies for using spot instances to reduce GPU compute costs.
  • Use Case: A rapidly growing AI startup experiences unpredictable spikes in user requests to their LLM API. This Skill ensures their Kubernetes cluster automatically scales the vLLM inference pods up during peak hours and down during lulls, preventing service degradation and optimizing cloud spend.

Quick Start

Configure KEDA to scale the 'vllm-llama-8b' deployment based on waiting requests and GPU cache usage.

Frequently Asked Questions about llm-inference-scaling

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I scale LLM inference pods on Kubernetes automatically?

To scale LLM inference on Kubernetes, you can use KEDA combined with Prometheus metrics to dynamically adjust pod counts based on real-time traffic and custom GPU utilization. This setup ensures high availability during unpredictable user request spikes.

Can I use KEDA to scale vLLM based on waiting requests?

Yes, you can configure KEDA to scale vLLM deployments by monitoring waiting requests and GPU cache usage via Prometheus. This queue-based scaling mechanism prevents service degradation during sudden traffic spikes.

What's the best way to optimize GPU compute costs for AI workloads?

To optimize GPU compute costs for AI workloads, integrate spot instances into your Kubernetes cluster. This strategy significantly reduces expenses while maintaining dynamic scaling capabilities for your LLM inference pods.

Do I need Prometheus to autoscale LLM inference clusters?

Yes, you need Prometheus configured with GPU metrics to effectively autoscale LLM inference clusters. It provides the real-time resource utilization and queue data required by KEDA to trigger horizontal pod autoscaling.

How does GPU-aware autoscaling work for vLLM on Kubernetes?

GPU-aware autoscaling works by leveraging custom GPU metrics from Prometheus to inform KEDA. Instead of relying solely on CPU or memory, it scales vLLM inference pods based on actual GPU cache usage and waiting request queues.