Posts

Showing posts from July, 2026

Stop Wasting GPU Compute: Why SGLang is the Best Engine for LLM Agents

Image
  If you are running RAG pipelines, AI agents, or multi-turn chatbots on a dedicated GPU server, standard LLM serving engines are wasting your VRAM. In a standard setup, the key-value (KV) cache is discarded after every request. If your agent sends the same massive system prompt over and over, the engine recomputes it from scratch every time. Enter SGLang and RadixAttention. SGLang (developed out of UC Berkeley) solves this by organizing all cached KV states into a radix tree. It automatically finds the longest matching prefix and only computes attention for the new tokens. This drastically reduces the Time-to-First-Token (TTFT) for any workload with repeated context. Hardware VRAM Rule of Thumb for SGLang: Before deploying, you need to ensure your server has the right baseline: 8B Models (Llama 3.1): 16–24 GB VRAM (RTX 4090, A100 40GB) 32B Models: 48–64 GB VRAM (A100 80GB, H100) 70B Models: 140+ GB VRAM (Requires Tensor Parallelism across multiple GPUs) How to Deploy It Get...

Maximizing GPU ROI: How to Partition NVIDIA A100 & H100 with MIG

Image
  Most AI teams provision GPUs the way they provision servers: one workload, one full device. But running a 7B-parameter inference endpoint or a batch embedding job doesn't require a massive 80GB of HBM3 memory. When you run lightweight workloads on a full A100 or H100, most of the silicon sits idle—while your budget burns away. NVIDIA’s Multi-Instance GPU (MIG) technology solves this by physically dividing a single GPU into up to 7 independent, hardware-isolated instances. Here is a quick breakdown of how it works and how you can implement it to maximize your hardware ROI. Why Choose MIG Over Time-Slicing? Unlike software-based sharing methods (like CUDA MPS or time-slicing) where processes cooperatively share resources, MIG offers true hardware-level isolation . Dedicated Resources: Each MIG instance gets its own assigned Streaming Multiprocessors (SMs), memory, and L2 cache. Zero Resource Contention: A massive, memory-heavy request on one instance cannot starve, slow down, or...

Why Network Latency is Killing Your AI App in Europe

Image
  Every millisecond between a user's request and your AI model's response is a design decision. For live applications like chatbots, recommendation engines, or real-time fraud detection network latency is often the difference between a product that feels instant and one that feels broken. If your GPU infrastructure sits in the wrong place, you are fighting a losing battle against physics. Here is what you need to know about optimizing AI inference for the UK and Europe. 1. Training Latency vs. Inference Latency Are Not the Same It is easy to lump "AI performance" into one bucket, but they have completely different tolerances for delay: Training jobs running for 12 hours do not care if a data batch takes an extra 200 milliseconds to load. Live inference is synchronous. A user is actively waiting on the other end. If your pipeline involves multiple steps (API gateway → database context → GPU compute → response), a poorly optimized network will ruin the user experience...