TL;DR: Fifty barely-used models on fifty endpoints is a $4,000+/month bill for idle RAM. A Multi-Model Endpoint is an LRU cache for models: all fifty live in one S3 prefix, requests name their model (TargetModel), hot ones stay loaded, cold ones load from S3 in 5–20 s when called. Two shared instances replace the fleet — typically 85–95% off — and adding model #300 is just an S3 upload.
The numbers
- 50 models × ml.m5.large endpoints ≈ $4,140/month; the same 50 on one MME with 2× ml.m5.xlarge ≈ $331/month (−92%)
- Field examples: a 300-customer SaaS (≈50 active at any moment) went from $15k+/month, growing linearly per signup, to $500–800/month flat; a 40-category recommender consolidated to 3–4 instances at −85–90% with the top 5 categories permanently warm
- Memory is the sizing knob: ~14 × 500 MB models fit in an 8 GB instance, ~120 in a 64 GB one — size for the working set, not the catalog
Do this
-
Group models by container: every model on an MME must share the same inference container (one framework per MME — no PyTorch+TensorFlow mixing). Groups of 5+ same-framework endpoints are your candidates.
-
Deploy one endpoint over an S3 prefix, invoke with the model name:
predictor.predict(data, target_model="customer-1234.tar.gz")Adding/removing a model is an S3 upload/delete — zero infrastructure change.
-
Size RAM to the working set and watch
ModelCacheHit— 90%+ means sized right; sliding lower means more memory (the fix is RAM, not CPU). -
Pre-warm the VIPs: a scheduled Lambda pinging top-customer/hot-category models every few minutes keeps them off the cold path for pennies.
-
Stack a Savings Plan on the consolidated instances — a small, steady fleet is exactly what's safe to commit on; combined with consolidation that's routinely 90–95% off the naive baseline.
-
Auto-scale instance count on
InvocationsPerInstancelike any endpoint — capacity scales elastically while the model catalog just sits in S3.
Gotchas
- Cold loads are 5–20 s for a model not in RAM. Invisible for internal tools and async flows; unacceptable for a hot user path — keep those models on dedicated endpoints and put the long tail on the MME.
- One container per MME — mixed frameworks means one MME per framework.
- GPU support is weak — multi-GB GPU models belong on dedicated endpoints.
ModelLoadingWaitTimespiking = requests queuing behind loads = undersized instance.- A/B testing is a hidden bonus fit: all variants on one endpoint, routed by
TargetModel, promoted by config change.
Skip this if
- You run 1–3 models — the operational surface isn't worth it; dedicated endpoints (or serverless for the sporadic ones) are simpler.
- One model dominates all traffic — that's an auto-scaled single endpoint, not a cache problem.
- Every request needs strict uniform latency — the LRU trade is the wrong trade.