Inference /Choosing hardware

Choosing hardware for inference

GPU memory, replicas, context and users: size the workers and the central server before you submit.

What you choose

An inference job runs on GPU workers you pick and one central server the platform picks.

What it isGPUWho picks it
WorkerOne machine with 1–8 GPUs running a copy, or a slice, of your modelyesYou, through the job’s requirements
Central serverReceives requests, checks the API key, routes them to workers. Runs no modelnoThe platform. See Central servers
TermMeaningUse it when
ReplicaOne running copy of the model. More replicas, more requests per secondYou need throughput
Tensor parallel (TP)One copy split across the GPUs of one worker; they talk on every tokenThe model doesn’t fit one GPU
Pipeline parallel (PP)One copy split by layers across several workers on one LANNo multi-GPU machine is free
Data parallelSeveral replicas, one per worker, no traffic between themDefault; the simplest way to scale

1. How much memory the weights take

formula
weights (GB) ≈ parameters (billions) × bytes per parameter
PrecisionBytes / param7B24B70B120B
fp16 / bf16214 GB48 GB140 GB240 GB
fp817 GB24 GB70 GB120 GB
AWQ / GPTQ / MXFP4 (4-bit)~0.554 GB13 GB39 GB66 GB

The exact figure is the size of the model’s weight files on Hugging Face. For Mixture-of-Experts models count every parameter, not the active ones: GLM-4.5-Air has 106B parameters and uses 12B per token, so it needs the memory of a 106B model and runs at the speed of a 12B one.

2. Which GPU fits

Keep the weights at or under ~75% of the card. The rest holds the KV cache and runtime overhead.

formula
min_vram_gb_per_worker ≈ weights ÷ 0.75
WeightsSmallest GPU that works wellCatalog examples
≤ 8 GB (3B fp16, 7–8B 4-bit)12 GBRTX 3060, 4070, 5070
≤ 12 GB (7B fp16, 14B 4-bit)16 GBRTX 5070 Ti, 4080, T4
≤ 18 GB (24B 4-bit, 14B fp16)24 GBRTX 3090, 4090, L4, A10
≤ 24 GB (30B-class 4-bit)32 GBRTX 5090
≤ 36 GB (32B fp16, 70B 4-bit)48 GBA6000, L40S
≤ 60 GB (70B fp8, 120B 4-bit)80–96 GBH100, RTX PRO 6000
≤ 105 GB (235B 4-bit)141 GBH200

When the weights don’t fit one card

OptionSetTrade-off
A 4-bit build of the same modelmodel_sourceUsually the best answer
TP on one multi-GPU workergpus_per_worker = tensor_parallel_size = 2, 4 or 8Identical cards; NVLink for 4+
PP across single-GPU workerspipeline_parallel_sizeHigher latency per token; one LAN

Example: GLM-4.5-Air AWQ (60 GB) runs on 4 × 24 GB with TP=4, or on one 96 GB card. The platform checks GPU memory per card, so a 4-GPU worker with min_vram_gb_per_worker: 84 is checked as 21 GB per card. For TP ≥ 4 set require_nvlink: true.

warn
Pipeline parallel works but isn’t production-proven yet. Prefer TP or more replicas.

3. Context and users at once

The KV cache holds the attention state of every token in flight, across all requests. vLLM frees a request’s blocks when its answer completes. When the cache is full, new requests wait in a queue: an undersized card means waiting, not crashing.

ModelKV per token (fp16)4 GB of KV holds
Qwen2.5-3B~36 KB~110k tokens
Qwen2.5-7B~56 KB~70k tokens
Llama-3.1-8B~128 KB~31k tokens
Qwen3-8B~144 KB~28k tokens

kv_cache_dtype="fp8" halves these and is on in the templates. “Tokens” sums every request in flight: 16 chats × 2k tokens = 32k.

worked example · Qwen2.5-3B fp16 on a 12 GB card
budget  = 0.90 × 12 GB          = 10.8 GB
KV      = 10.8 − 6.2 (weights) − 0.7 (runtime) ≈ 3.9 GB
tokens  ≈ 3.9 GB ÷ 36 KB       ≈ 108k   → 16 users at 8k context fit

Long conversations

A long conversation re-sends its history every turn, so its cost is memory per user, growing with context.

formula
KV per user       = context tokens × KV per token
users per replica = (0.9 × VRAM − weights − ~1 GB) ÷ KV per user
Context per userQwen2.5-7B (fp8 KV)Llama-3.1-8B (fp8)Qwen3-8B (fp8)
8k0.2 GB0.5 GB0.6 GB
32k0.9 GB2.1 GB2.4 GB
128k3.7 GB8.4 GB9.7 GB
256k7.3 GB17 GB19 GB
Card · Qwen3-8B AWQ (5 GB weights)KV budgetUsers at 32kUsers at 128k
16 GB8 GB30
24 GB16 GB61
48 GB37 GB153
96 GB80 GB338

Long context needs VRAM, not compute. What helps, in order:

  • A bigger card, or TP across one worker’s cards (it pools their memory). More replicas only add users at the same context.
  • A long-context model: hybrid-attention families (Qwen3.5, Qwen3-Next) cache only a few layers.
  • Caps that match the card: max_model_len per request and max_num_seqs for concurrency, set from the tables above.
  • Shorter history on the client: summarise or drop old turns.

4. How many replicas

Throughput grows with replicas. Measured on one RTX 5070 Ti 16 GB per replica:

Workload1 replica2 replicas
Qwen2.5-Coder-7B AWQ, 3,200-token prompt → 256 tokens86 completions/min177/min (2.04×)
Same, users under 5 s to first token816
Qwen2.5-VL-7B AWQ, one page per request~4,200 pages/h~8,460 pages/h (2.01×)
Same, real JSON extraction2,283 pages/h4,211 pages/h

Plan for 70% of one replica’s measured ceiling:

formula
num_workers = ceil(your load ÷ (0.7 × one replica's ceiling))

Start with one replica and add workers when the queue shows. Replicas of one job can run on different GPU models; each only has to fit its own card. All measurements: Inference benchmarks.

5. Disk, RAM and CPU per worker

ResourceRule of thumbField
Disk1.3 × checkpoint + 25 GB (image, working dir). With PP, on every workermin_disk_gb_per_worker
Host RAM2 × the GPU’s VRAM (loading and image decoding run there)min_host_ram_gb_per_worker
CPU4 cores per GPU; 8+ for vision and audiocpus_per_worker
DriverR570 or newer (CUDA 12.8 image, Turing to Blackwell)min_driver_version

6. The central server

The platform picks it at submit, and every request passes through it. It runs no model and needs no GPU.

What it handlesWhat that means for sizing
Your public endpoint and the API key checkA missing or wrong key gets 401 here, before any worker sees the request
Every request and response, streamed answers includedIts network matters more than its CPU. Each open stream holds a connection
The request queueRequests wait here when every replica is at max_ongoing_requests; past max_queued_requests it answers 503 (stage 3 under load)
Your scripts, uploaded weights, logs and the serving imageThey land on its disk. Raise the disk minimum by the size of weights you upload with the job
SettingDefaultField (yaml)Submit form
Free RAM≥ 2 GBcluster.central_host.min_ram_gbCentral server RAM
Free disk≥ 10 GBcluster.central_host.min_disk_gbCentral server disk
A whole server for this jobSharedcluster.central_host.dedicated: trueDedicated central server
A server only your jobs useNoneNot in the yamlOrder a central server (workers step or Support)

A server reserved for you is used first; otherwise the platform picks a shared one that meets your minimums. If none does, the launch stops and the wizard offers to order one.

  • Shared is fine for tests and most endpoints under light traffic.
  • Dedicated when the endpoint serves many users or long streams, so no other job shares its network.
  • Reserved for production endpoints: only your jobs run on it, and they use it automatically.
warn
Workers recover on their own: if one drops, its replicas move to the others. The central server has no failover. If it goes down, the endpoint stops and you resubmit the job.

GPU tiers and mixing them

TierVRAMFits on one cardTypical cards
small11–12 GB3B fp16; 7–8B 4-bit; embeddings, rerankers, WhisperRTX 2080 Ti, 3060, 4070, 5070
mid16–24 GB7B fp16; 14–24B 4-bit; 7B vision; RAG bundlesRTX 5070 Ti, 4080, 3090, 4090, L4, A10
large24–48 GB14B fp16; 32B 4-bit; 70B 4-bit on 48 GBRTX 5090, A6000, L40S
frontier80 GB+70B fp8; 120B MoE 4-bit; 235B 4-bit on 141 GBH100, RTX PRO 6000, H200
WhereMixing GPU models
Across replicas of one jobMix freely; the faster card takes more traffic
Inside one TP workerIdentical cards: the smallest sets capacity, the slowest sets speed
Across PP stagesSame class if you can; the slowest stage gates every token

Datacenter cards (A-, L-, H-series, RTX PRO 6000) come with ECC; consumer cards cost less per GB. Pick datacenter cards for regulated workloads.

By model type

“min → rec”: the minimum at the heaviest quantisation and short context, then the size that leaves room for context and users.

Chat and reasoning

ModelWeightsVRAM min → recWorkers
Qwen3-8B AWQ~5 GB10 → 12 GB1 × 12 GB
gpt-oss-20b MXFP4~13 GB14 → 16 GB1 × 24 GB
Mistral Small 24B AWQ~13 GB16 → 24 GB1 × 24 GB
gpt-oss-120b MXFP4~65 GB66 → 96 GB1 × 96 GB, or 4 × 24 GB TP=4
GLM-4.5-Air AWQ~60 GB62 → 96 GB4 × 24 GB TP=4, or 1 × 96 GB
Qwen3-235B-A22B AWQ~125 GB130 → 160 GB2 × 80 GB TP=2, or 1 × 141 GB

Coding assistants

ModelVRAM min → recWorkers
Qwen2.5-Coder-3B fp16 (autocomplete)8 → 12 GB1 × 12 GB
Qwen2.5-Coder-7B AWQ6 → 12 GB1 × 12–16 GB per replica
Devstral Small 24B AWQ16 → 24 GB1 × 24 GB
Qwen3-Coder-30B-A3B AWQ20 → 24 GB1 × 24 GB, or 2 × 12 GB PP=2
Qwen2.5-Coder-32B AWQ20 → 24 GB1 × 24 GB

Coding agents resend the repository context every turn; prefix caching keeps that affordable. One 16 GB replica serves about 8 developers under 5 s to first token.

Vision-language

ModelVRAM min → recWorkers
Qwen2.5-VL-7B16 → 24 GB1 × 16–24 GB per replica
Qwen2.5-VL-32B AWQ36 → 48 GB2 × 24 GB TP=2, or 1 × 48 GB
Qwen2.5-VL-72B AWQ44 → 80 GB1 × 80 GB

A 1-megapixel page is about 1,000–3,000 tokens and counts against context like text. The vision encoder stays fp16 even when the language model is 4-bit.

RAG, adapters and speech

ModelVRAMNotes
Qwen3-Embedding-0.6B, Qwen3-Reranker-0.6B, BGE-M32 → 4 GB eachShare the chat model’s GPU
Qwen3-Embedding-8B fp1616 → 24 GB1 × 24 GB
Base + LoRA adapters (Qwen2.5-7B AWQ)10 → 12 GB8–16 adapters of 10–500 MB fit beside the base
Whisper large-v36 → 10 GB10–30 parallel streams per worker
Whisper large-v3-turbo4 → 8 GB5–8× faster decode

Computer vision and image generation (custom models)

ModelVRAMNotes
YOLO11, SigLIP / CLIP, Grounding DINO2 → 8 GBSeveral share a 12 GB card
DeepLabV3+ segmentation4 → 8 GB
SAM 2.16 → 12 GB
SDXL10 → 16 GB~1–2 s per image on a 24 GB card
FLUX.1-schnell, SD 3.5 Large16 → 24 GB
Qwen-Image 20B40 → 80 GB

For custom models CPU matters as much as VRAM: image decoding runs on the CPU. Give 4–8 cores per GPU.

When load exceeds the plan

Too many requests don’t crash a replica: vLLM reserves the KV cache at start and admits only what fits. The endpoint degrades in a fixed order.

StageWhat happensKnob
1. The card is fullNew requests wait inside vLLM; time to first token climbsmax_num_seqs
2. The replica queue is fullRequests wait at the central server. Measured: 16 s to first token at 2 req/s on one 16 GB replicamax_ongoing_requests
3. The queue limit is reachedImmediate 503. Measured: at 4 req/s one replica dropped 1 in 4; two dropped nonemax_queued_requests
4. An answer outlives 300 sThe stream is cutmax_tokens on the client
5. A prompt exceeds the limitThat request gets 400; nothing else is affectedmax_model_len
  • Plan at 70% of the measured ceiling and watch time to first token: it rises first.
  • Add a replica before the queue does it for you. For vLLM that’s a relaunch with one more worker; custom runtimes can add workers while running.
  • Give batch work its own job, so a 100k-page extraction doesn’t queue ahead of a chat.

Before you submit

The platform checks at submitYou check
VRAM per worker and per cardyesThat it covers your context and users (steps 2–3)
Disk and host RAMyesThe numbers (step 5)
NVLink inside the workeryesSet it for TP ≥ 4
GPU generation and driveryesbf16 needs compute 8.0+; native FP8 needs 8.9+
Central server RAM, disk, dedicatedyes
Model supported by vLLM 0.18noEvery model on this page is
Context × users fit beside the weightsnoStep 3

Worked examples

GoalSizing
Qwen3-8B chat for a 30-person team5 GB of AWQ weights. 30 users × 4k = 120k tokens of KV won’t fit beside them on 12 GB: take one 16 GB card or two 12 GB replicas. Disk 28 GB.
Mistral Small 24B, 32k context, 50 users13 GB weights leave ~6 GB of KV on 24 GB (~100k tokens at fp8): 50 users × 2k fit, 50 × 32k don’t. Two 24 GB replicas, or one 48 GB card.
gpt-oss-120b on your own servers65 GB weights: one RTX PRO 6000 (96 GB), or 4 × 24 GB with TP=4 (min_vram_gb_per_worker: 84, checked as 21 GB per card). Disk 105 GB.
100k document pages a day2,283 real pages/h per 16 GB replica is 55k/day flat out, 38k at 70%. Three 16 GB replicas.
note
Every cluster.* minimum can also be set in the submit form, which overrides the yaml and shows live how many workers and central servers meet it.