techlist.io

Kv Cache

5 posts

OpenAI2026-08-244 min readCurated summary

Jalapeño’s first results show industry-leading speed and efficiency in AI inference

OpenAI's first custom inference chip, Jalapeño, delivers more AI work per watt and lower response latency than leading commercial systems in its testing, a combination that existing hardware often forces teams to trade off. The chip and its surrounding system were co-designed around language-model inference, and AI was used throughout development, taking the design from initial concept to tapeout in nine months. OpenAI plans to begin deploying Jalapeño in its own infrastructure by the end of the year. ## Benchmark Results Against Leading Systems - Tests used InferenceX, a public SemiAnalysis benchmark that measures the full process of serving an AI request, across operating points from high-throughput serving to low-latency interactive use. - Across GPT-OSS 120B, DeepSeek R1, and Kimi K2.5 1T, Jalapeño delivered 1.5 to 1.9 times more AI work per watt at peak throughput and 1.7 to 3.6 times lower end-to-end latency than the comparison systems. For highly interactive workloads, it reached 2.1 to 4.1 times higher performance. - Power was normalized to published chip ratings: Jalapeño is rated at 700 W and measured at or below 550 W sustained, compared with 1,200 W for GB200 and 1,400 W for GB300. - The appendix gives per-model figures. On GPT-OSS 120B, peak mixed tokens per second per kW was 85,448 versus 44,960, and end-to-end latency was 1.03 s versus 1.80 s. On DeepSeek R1, latency was 1.65 s versus 5.99 s. On Kimi K2.5, latency was 1.56 s versus 5.31 s. - OpenAI reports that its advantage grew on its internal frontier models, which suggests the gap widens as workloads get larger and more demanding. ## Measuring Performance Per Unit of Power - The team compares systems at a matched user experience: how much useful work each completes per unit of power while meeting the latency that customers and interactive agents need. - Latency matters especially for agents, because delays compound across the many sequential steps of a single task. - The authors argue that performance per unit of power is a more useful standard than performance per chip. ## Architecture Built Around Inference Phases - Prefill, which processes the prompt, is compute-intensive, while decode, which generates tokens one at a time, is limited mainly by memory bandwidth. - Data movement between cores and chips can leave processing units idle, and a system that excels at one phase can lose that advantage while waiting on data. - Jalapeño co-designs the chip, memory, network, software, and rack-scale system to minimize data movement. The KV cache can be explicitly placed and kept local. - A large network domain keeps the whole workload inside one connected system, so requests stay fast from start to finish. - The result is a balanced, flexible accelerator that handles both prefill and decode and adapts as the balance between them shifts, which is typical of agentic workloads. ## Using AI to Design and Program the Chip - AI helped the team move from initial design to tapeout in nine months by exploring implementations, shortening design and verification loops, and optimizing the chip's arithmetic circuits. - Jalapeño was built as a predictable programming target. Engineers describe work through local tensors, explicit communication, and predictable synchronization, and AI then maps, places, and schedules that work across the system. - Using Codex with GPT-Astra, the team brought three open-weight models that were not in the original production plan to high performance within two months. - For selected GPT-OSS attention and mixture-of-experts blocks, AI-generated implementations ran 1.5 to 1.8 times faster than human-written ones. These figures cover individual blocks, not the full model. ## Roadmap and Deployment - Jalapeño enables three new performance tiers: ultra-fast-mode inference at efficiencies previously available only in fast mode, fast-mode inference at batched-mode efficiency, and higher efficiency for batched inference. - OpenAI plans to deploy Jalapeño in its compute infrastructure by the end of the year. Gen 2 is in deep development and Gen 3 is taking shape. - NVIDIA and other partner accelerators will continue to be deployed alongside Jalapeño for training and inference. - Remaining work before scale deployment includes production qualification, software maturation, operational preparation, and validation across more models. For teams evaluating inference hardware, the post's main lesson is to compare systems on performance per watt at a matched latency target, not on per-chip throughput alone.

Cloudflare2026-08-033 min readCurated summary

Smaller, faster, safer: running Kimi and GLM at scale

Cloudflare improves the efficiency of serving large, long-context models by optimizing both GPU memory usage and request concurrency. Its approach combines FP8 KV-cache quantization, INT4 weight compression, and integrity checks for shared caches, while using separate prefill and decode pools to apply each optimization where it helps most. These techniques increase throughput and reduce costs without materially affecting model accuracy. ## Quantizing the KV Cache - Long-context models store attention keys and values in a KV cache, which often exhausts GPU memory before model weights do. - Cloudflare stores the cache in FP8 instead of BF16, cutting its size in half. - On Kimi K2.6, this increases available context from roughly 686,000 to 1.37 million tokens. - FP8 is slightly slower at the same concurrency because values must be converted during attention. - However, FP8 supports more concurrent requests: - BF16 runs out of memory at 32 requests. - FP8 reaches 2,192 tokens per second at 64 requests. - Peak throughput improves by about 41%, with roughly 30% lower cost per token. - Cloudflare keeps BF16 for prefill, where workloads are compute-bound. - Evaluation results show FP8 and BF16 produce effectively indistinguishable quality across reasoning, knowledge, tool-calling, and internal benchmarks. ## Compressing Model Weights - GLM 5.2 weights are compressed from FP8 to INT4 for the decode phase. - The checkpoint shrinks from 705 GB to 421 GB, while per-GPU memory in an eight-way deployment falls from about 88 GB to 52 GB. - The freed memory supports approximately 1.18 million tokens of KV cache. - INT4 improves decode performance because generation is memory-bandwidth-bound: - Single-request throughput rises from 60 to 92 tokens per second, a 55% gain. - Gains range from 16% to 27% at higher concurrency. - Prefill becomes slower with INT4 because compressed weights must be expanded before computation: - FP8 prefill: about 10,160 tokens per second. - INT4 prefill: about 8,660 tokens per second. - Cloudflare therefore uses FP8 for prefill and INT4 for decode. - Accuracy remains within 0.8 percentage points of the FP8 model across tested benchmarks. ## Protecting a Shared KV Cache - Greater memory efficiency allows hundreds of requests to share physical KV-cache pages, increasing the risk of page-allocation or bookkeeping errors. - Cloudflare assigns each cache page a changing tag whenever it is reallocated. - Requests record the pages and tags they expect, and the server validates these mappings before supported decode operations. - If a mismatch occurs, the request is aborted instead of reading incorrect data. - In production-style tests, integrity checking caused: - Less than 1% throughput reduction. - Less than 1% increase in p95 latency. - Validation runs as a separate batch check rather than inside the attention kernel, avoiding GPU synchronization races. - The feature is enabled per deployment, while deployments that do not use it incur no measurable overhead. ## Future Work - Cloudflare is expanding FP8 KV caches across its fleet. - It is testing NVFP4 weight compression on NVIDIA Blackwell GPUs. - The company is also working toward making cache integrity checks universally enabled at negligible cost. Together, these optimizations let Cloudflare serve larger models with more concurrent users, lower inference costs, and essentially unchanged model quality. Separating prefill and decode workloads is central to applying each precision choice where it delivers the best trade-off.

OpenAI2026-08-025 min readCurated summary

How we built a realtime system for responsive voice AI in six months

# How OpenAI Built GPT‑Live: A Realtime Voice System Engineered Around Continuous Audio OpenAI's GPT‑Live replaces the turn-based design of earlier voice assistants with a full-duplex voice model that listens and speaks at the same time, with no separate turn detector in the audio path. Frontier models such as GPT‑5.5 are consulted asynchronously for deeper reasoning and tool use, so the conversation never pauses for them. Delivering this required rethinking inference, context management, delegation, transport, and session startup so that every layer keeps audio flowing on schedule. ## Why Turn-Based Voice Fell Short - Earlier systems used small turn detectors to decide when the user had finished speaking. Guessing too early cut users off, and guessing too late made responses feel sluggish. - Cascaded pipelines ran speech-to-text, the LLM, and text-to-speech in series, adding latency and discarding cues like tone and pacing. - Speech-to-speech models improved fidelity, but they still waited on a turn detector, so the interaction remained turn-based. ## Streaming Inference and Continuous Media - Audio streams into the voice model and speech streams back out, rather than being handled as discrete request-response blobs. - A dedicated fast path carries media, while delegation, tool calls, and persistence run behind an asynchronous RPC boundary. A slow tool can delay its own result but cannot stall audio. - The media frontend and inference logic were rewritten from Python asyncio to Go, bringing the p95 frame delivery time in line with the previous system's p50. - WebRTC handles transport. Under late packets it stretches audio to avoid gaps, then briefly speeds playback to catch up to real time. ## Stateful Handoffs and Context Compaction - Long sessions outgrow context limits, and model instances scale up and down with demand. To handle this, a replacement instance is warmed and prefilled with current session context, runs in parallel with the original, and takes over once ready. - Compaction is treated as another managed transition. Shrinking context invalidates the KV cache, which would normally force a costly re-prefill. Instead, the system prepares a compacted replacement in the background and switches over without interrupting media. ## Delegation Without Blocking the Conversation - The frontier model's session is created and prefilled with initial context when the voice session starts, so the prompt is already processed when the first delegated request arrives. - Session affinity and prompt caching keep latency low, and worker failures remain recoverable. - Reasoning effort, output limits, tool schemas, and model-tool round trips were tuned to shorten the time until a useful result returns. - Because the rest of ChatGPT expects discrete messages, the application server converts continuous speech into turns. It uses partial transcripts and timing signals to infer the speaker, keeps the newest message provisional, and finalizes it once attribution is reliable. - Two views are maintained: a speculative view for the live UI and an authoritative transcript for analytics and safety logging. Brief acknowledgments like "mm hmm" are generally not promoted to their own messages, while substantive interjections often are. ## Faster Session Startup with WARP and Instant Connect - A vanilla WebRTC session needs several handshakes and round trips before media flows. WARP (WebRTC Abridged Roundtrip Protocol) cuts media and data startup from six round trips to one. It does this by piggybacking DTLS on ICE (SPED), using DTLS 1.3, pre-negotiating SCTP (SNAP), and pre-negotiating data channels instead of using DCEP. - These are open specifications, being advanced through the IETF TSVWG working group. WARP support has been added to libwebrtc and Pion. - Instant Connect negotiates SDP parameters ahead of time without reserving server capacity. The server materializes the session on the first media packet if the parameters are valid, and falls back to the standard signaling flow with no added latency if they are stale. - Together, these let a client start a session with a single UDP packet. ## Testing in Production Before Launch - A silent shadow test routed a growing share of real ChatGPT Voice sessions to GPT‑Live, which ran read-only while Advanced Voice Mode continued serving users. This exposed the system to real networks, session lengths, and geographies without changing what users heard. - Capacity could not be measured by GPU throughput alone. CPU-side stream handlers, queues, and network paths saturated earlier than load tests predicted. The capacity question became how many concurrent sessions could keep every frame on schedule. - Geography mattered. Routing sessions to distant capacity added delay at several points, so rollouts were validated alongside regional capacity and traffic-steering configuration. - Long sessions, reconnects, and client disconnects surfaced memory pressure, state-restoration issues, and shutdown races that short load tests missed. - The team added finer-grained telemetry, validated configurations against known-good baselines, ramped traffic in stages, and built the ability to isolate or disable individual paths quickly. ## Conclusion The central lesson is that voice responsiveness depends on every component in the path, not just the model. Streaming inference, a dedicated media path, asynchronous delegation, and optimized transport work together to keep conversation feeling live. The same architecture is expected to underpin the forthcoming GPT‑Live API and broader agentic voice experiences.

OpenAI2026-07-283 min readCurated summary

How GPT-5.6 fuses frontier intelligence with frontier efficiency

# How OpenAI Built GPT‑5.6 to Balance Frontier Intelligence and Efficiency OpenAI designed the GPT‑5.6 model family to deliver top-tier capability at lower cost across the range of tasks people use its models for. The flagship GPT‑5.6 Sol outperforms Claude Fable 5 on the Artificial Analysis Coding Agent Index at less than half the cost, while the mid-tier Terra matches GPT‑5.5 on intelligence benchmarks at half the price. The gains come from optimizing every layer of the stack: the models themselves, inference, and the agentic harness that powers Codex and ChatGPT Work. ## Efficiency as a System-Wide Goal - OpenAI reports serving 1 billion active users and more than 2 million businesses, which makes efficiency central to distributing intelligence broadly. - GPT‑5.6 is trained to get more work done per token, optimizing for both task success and efficiency so the model takes a more direct path through a task. - The family spans three price points: Sol (flagship), Terra (mid-tier, half the price of GPT‑5.5 with similar benchmark results), and Luna (fastest and cheapest, priced 80% below Sol). ## Accelerating Inference with GPT‑5.6 Sol Inference is optimized as a whole system, since a efficient model can still be costly to serve if requests are routed poorly or hardware sits idle. GPT‑5.6 Sol, running in Codex, helped with much of this work. - **Load balancing:** Requests are routed globally by geography, available capacity, and accelerator type, then distributed within clusters by load, context length, and cache availability. Sol analyzed production traffic, found overlooked imbalances, and tested routing strategies. These changes alone significantly reduced serving costs. - **Kernel optimization:** Sol rewrote and optimized production GPU kernels in Triton and Gluon, reducing end-to-end serving costs by 20%. OpenAI used its open-source FpSan (Floating-Point Sanitizer) to verify kernel correctness. - **Speculative decoding:** Sol redesigned its own draft model through hundreds of experiments on size, structure, and features. It also launched and monitored the speculator training run, handling hardware failures and training instability on its own. Token-generation efficiency improved by more than 15%. - **Workload-specific configuration:** Batching, sharding, and KV cache management depend on prompt length, output length, batch size, and cache hit rate. Sol generated and evaluated candidate configurations against production workloads, which made per-scenario tuning practical. ## Reducing Repeated Work in the Agentic Harness A single user turn in Codex or ChatGPT Work can involve dozens of model requests and tool calls, so any overhead in the repeated loop gets multiplied. The harness, a Rust orchestration layer, addresses this in two main ways. - **Avoiding context bloat:** Deferred discovery surfaces integrations, custom MCP tools, skills, and plugins only when needed. Tool output is capped at 10,000 tokens by default unless the model requests more. - **Preserving prompt-cache prefixes:** Model-visible history is append-only, so new messages and tool results go at the end rather than into earlier context. Tools are presented in a deterministic order, and runtime settings such as approval policies are applied during execution rather than embedded in tool definitions. This design contributes to high prompt-cache hit rates in both products. OpenAI describes these efficiency gains as the product of compounding improvements across research, inference, and the harness. It expects the pace of optimization to accelerate as GPT‑5.6 takes on more of this engineering work itself.

Cloudflare2026-04-163 min readCurated summary

Building the foundation for running extra-large language models

Cloudflare is building infrastructure for serving extra-large open-source language models efficiently, especially for agentic applications with long prompts and frequent tool calls. Its approach combines specialized hardware configurations, prefill/decode disaggregation, prompt caching, distributed KV-cache management, and speculative decoding. These optimizations substantially improve latency, throughput, and cost efficiency without requiring more GPUs. ## Hardware Configurations for Agent Workloads - Different applications stress models differently: - Content generation sends fewer input tokens but produces many output tokens. - Summarization sends very large inputs and generates relatively short outputs. - Agent workloads typically involve: - Large system prompts - Tool and MCP definitions - Accumulated conversation history - Generated code and previous interactions - Workers AI therefore prioritizes fast input processing and tool-calling performance. ## Prefill-Decode Disaggregation - LLM inference has two stages: - **Prefill:** Processes input tokens and populates the KV cache; generally compute-bound. - **Decode:** Generates output tokens; generally memory-bound. - Running both stages on one server can underutilize GPUs because they stress different resources. - Cloudflare separates them across dedicated inference servers: - A prefill server processes the request and stores its KV cache. - A decode server retrieves the cache and generates the response. - This enables independent tuning, scaling for input- or output-heavy traffic, and use of heterogeneous hardware. - The architecture requires a sophisticated load balancer that: - Transfers KV-cache metadata between stages. - Rewrites streaming SSE responses. - Handles different inference-server protocols. - Balances traffic based on estimated in-flight prefill and decode tokens. - After adopting this design, Cloudflare saw: - Lower p90 time to first token and reduced tail-latency variance. - Intertoken latency fall from roughly 100 ms to 20–30 ms. - About a threefold improvement while using the same number of GPUs. ## Prompt Caching and Session Affinity - Long agent conversations repeatedly reuse the same context, making prompt caching essential. - The `x-session-affinity` header routes requests toward regions containing previously computed input tensors. - Cloudflare added support for this header to agent harnesses such as OpenCode. - Cached prompts improve: - Overall throughput - Interactive response times - Pricing, with discounted cached tokens - GPU efficiency - Adoption by heavy internal users increased peak input-token cache hit rates from 60% to 80%. ## Distributed KV-Cache Optimization - Larger models span multiple GPUs, requiring KV caches to be shared across devices and nodes. - For Kimi, Cloudflare uses Moonshot AI’s: - **Mooncake Transfer Engine** for high-speed memory transfers using RDMA technologies such as NVLink and NVMe over Fabric. - **Mooncake Store** to extend cache storage beyond GPU VRAM onto NVMe. - Combined with LMCache or SGLang HiCache, the system can: - Reuse cached prompts from any node in a cluster. - Reduce reliance on session-aware routing. - Balance traffic more evenly. - Keep sessions cached longer. - Increase cache hit rates and supported throughput. ## Speculative Decoding - The post begins introducing speculative decoding as another optimization. - It describes the basic LLM process of predicting successive tokens, but the provided text ends before explaining the technique or its results. Cloudflare’s overall strategy is to match infrastructure to real usage patterns rather than rely on a single hardware configuration. Separating inference stages, maximizing cache reuse, and distributing KV caches are practical ways to make large-model hosting faster and more economical.