Skip to content
Preptima
hardDesignScenarioMidSeniorStaff

You have 50 ms for a model call in a request path. How do you make that budget?

5 min readUpdated 2026-08-15

Answer

Short answer

Break the budget into its parts first, because feature fetching usually costs more than the model does. Then parallelise and cache the fetches, shrink the model with quantisation or distillation, set a timeout shorter than the budget, and define a degraded path that answers without the model.

Was this answer helpful?

Likely follow-ups

  • Two of your five feature lookups are on the critical path and one is optional. How does that change the design?
  • Your p50 is 18 ms and your p99 is 300 ms. Where do you look first?
  • When would you accept a stale cached feature, and how stale is too stale?
  • How do you keep the fallback path from silently becoming the main path?

Related questions