Capacity Governance for Free LLM Compute: Managing the Demand-Supply Scissors Gap
This article examines how to govern capacity when free large language model compute faces sustained demand growth that outpaces supply. It breaks down the real cost drivers of an inference request, explains how to build a load profile before setting quotas, and lays out admission policies such as tiered quotas, session lifecycle reclamation, context budgets, and fair scheduling. It also covers cost-side optimizations, elasticity and graceful degradation, and a closed-loop governance process with capacity drills. The key takeaway is to treat context length, session lifetime, and concurrency as first-class citizens rather than relying on one-off engineering optimizations.
1. The Problem: A Scissors Gap That Code Optimization Cannot Close
Put two curves on the same chart and the problem is immediately obvious: demand is climbing steeply on one side, while supply is nearly flat on the other. One curve comes from public call statistics — a single flagship model consumed roughly 59.2 trillion tokens in one week, up from about 15.8 trillion six weeks earlier, an increase of nearly threefold. The other comes from the client side — daily active users grew from around 120 million to nearly 200 million, an increase of about 67% over half a year. Over the same period, the growth rate of compute capacity available for inference was only 8.3%.
It is worth stressing that these three figures come from different measurement scopes and cannot be divided directly to produce a “gap multiple.” Even so, they point to the same conclusion: demand is growing more than an order of magnitude faster than supply. This kind of gap cannot be closed by operator fusion, quantization, or inference framework tuning. Engineering optimization typically delivers a 20%–50% throughput improvement, and it takes effect only once; demand, by contrast, compounds continuously. Optimization can postpone the critical point but cannot eliminate it.
As a result, the only lever left for a service provider is admission control — deciding who can use how much free quota, and when. The original example of “cutting off long conversations that have been inactive for seven days” is a typical move on this lever: it does not lower the cost of a single request, but instead clears out long-inactive session contexts to reduce wasted KV cache and GPU memory occupancy.
2. Cost Structure: Where the Money Actually Goes
To understand why “free” breaks first, you first need to see the real cost composition of a single inference request.
- GPU memory usage: determined jointly by weights, KV cache, and runtime fragmentation. KV cache grows linearly with context length and the number of concurrent sessions, making it the main pressure source in long-conversation scenarios.
- Compute overhead: the prefill stage is roughly proportional to input length, and the decode stage is proportional to output length. Long contexts amplify both ends at once.
- Bandwidth and storage: writing and reading back multi-turn conversation history, logs, and audit data.
- Scheduling and queuing: request queue time is not billed, but it counts toward user experience and timeout rates.
Key takeaway: pricing is usually metered by token, but cost is driven mainly by “context length × concurrency × session lifetime.” A free strategy opens up all three, which amounts to handing users free rein over the independent variables of the cost function.
3. Load Profiling: Measure First, Govern Second
Any capacity governance effort must start with observability. It is advisable to collect at least the following dimensions and unify them under a single tagging scheme (tenant, model, scenario, context-length bucket):
Request rate QPS / concurrent sessionsInput token distribution (P50 / P95 / P99)Output token distributionContext length buckets: <2K, 2K-8K, 8K-32K, >32KCache hit rate, queue time, timeout rate, time to first tokenPer-request amortized cost (compute-seconds / request)
With a profile in hand, you can identify the long-tail structure where “a few requests consume most of the resources.” In practice, requests with more than 32K of context often account for less than ten percent of traffic yet may consume more than half of GPU memory and compute. Governing this long tail yields far greater returns than indiscriminate rate limiting across all requests.
4. Capacity Watermarks and Admission Policies
Treat the free quota as a finite public pool that needs explicit watermarks and admission rules, rather than tightening things up ad hoc after a collapse.
- Tiered quotas: allocate by scenario rather than by user identity. Interactive Q&A gets a low quota and short context; batch and offline jobs go through separate queues and separate time windows.
- Session lifecycle: set an inactivity reclamation window (for example, reclaim long context after seven days without interaction), keeping a summary rather than the full history on reclamation so GPU memory is not held hostage by zombie sessions.
- Context budget: set a token ceiling per session and force summary compression when it is exceeded, rather than returning an error outright.
- Fair scheduling: introduce weighted fair queuing to prevent a single tenant’s long requests from blocking the entire queue.
# Example: admission check with context budget and reclamation windowSESSION_TTL_DAYS = 7MAX_CONTEXT_TOKENS = 32_000def admit(session, now):if now - session.last_active > SESSION_TTL_DAYS * 86400:session.reclaim(keep_summary=True) # Reclaim long context, keep summaryif session.context_tokens > MAX_CONTEXT_TOKENS:session.compress_to(MAX_CONTEXT_TOKENS) # Summarize and compress instead of rejectingreturn scheduler.enqueue(session, priority=session.tier)
5. Cost-Side Optimization: Making the Same Compute Last Longer
Admission control is only throttling; beyond throttling, you need to increase efficiency on the supply side as well.
- Prefix cache reuse: stable prefixes such as system prompts, tool definitions, and long documents should reuse the KV cache across requests. This is the single highest-value optimization in long-conversation scenarios.
- Tiered caching: a semantic cache absorbs high-frequency repeated Q&A; a result cache absorbs idempotent queries; object storage holds large attachments so they do not repeatedly enter GPU memory.
- Model routing: send simple requests to smaller or distilled models and escalate to large models only for complex reasoning, which significantly dilutes average cost.
- Batching and continuous batch scheduling: raise GPU utilization and fill the fragmented time in the decode stage.
- Output length constraints: set reasonable caps for open-ended generation to prevent individual requests from extending decode indefinitely.
6. Elasticity and Degradation: Flattening the Peak
When the growth rate of compute capacity is constrained, elasticity is more realistic than scaling up. You can combine container-platform autoscaling, message queues for peak shaving and valley filling, and monitoring alerts that drive automatic degradation. Degradation paths must be designed in advance and drilled: shut down non-core capabilities, lower the maximum output length, convert real-time requests into asynchronous jobs, and queue low-priority tenants rather than rejecting them. The core principle is that “predictably slow” beats “unpredictably down.”
7. The Governance Loop and Drills
Chain the capabilities above into a loop: profile → watermark → admission → optimization → elasticity → review. In each iteration cycle, run regression checks with the same set of metrics, focusing on four: cache hit rate, P99 time to first token, per-request amortized cost, and timeout rate. Also prepare a capacity plan: when the compute increment falls below demand growth by a preset threshold, automatically trigger tighter quotas and degradation, rather than waiting for monitoring alerts to turn red before stepping in manually.
8. Conclusion
Shrinking the free quota is not a matter of product attitude but an inevitable choice under resource constraints. For developers, the truly transferable lesson is this: govern context length, session lifetime, and concurrency as first-class citizens, use cache reuse and model routing to maximize the output per unit of compute, and then use elasticity and degradation to absorb the peaks. Baidu AI Cloud’s combination of general-purpose capabilities across container platforms, message queues, object storage, log services, and monitoring alerts provides standard building blocks for this kind of capacity governance; the governance approach itself, however, is vendor-independent and relates only to that scissors gap that will not converge on its own.
