Vibeleaderboard
← All Intel
Intel / article

Turning Opportunistic AI Inference Capacity Into Better Ads Recommendations

Source
engineering.fb.com
Publisher
Meta
Date

Context

Meta uses temporarily idle computing capacity to do extra work on ad recommendations. Its engineering account describes two ways to spend that surplus: evaluate more candidate ads, or send more requests to a stronger prediction model. The first needs spare CPU and accelerator capacity; the second can use accelerator surplus without substantially increasing upstream CPU work.

The extra work must be removable because other workloads can reclaim the capacity. Separate capacity controls protect baseline serving, while fast local mechanisms discard lower-value optional work before slower central controllers catch up. The design makes recommendation effort adjustable to the resources actually available.

Key takeaways · AI-distilled
  • Meta lists four causes of locally idle capacity in a constrained fleet: peak provisioning versus demand swings, capacity arriving before models are ready, regional CPU-to-accelerator ratio gaps, and non-portable accelerator types.
  • The two levers consume different resources: ranking more candidates needs both CPU and accelerator surplus because extra ads pass through and feature processing, while routing to stronger models uses accelerator-only surplus.
  • Candidate volume is governed by a central PID controller that reads tail , raising the number of ads ranked when latency is under target and cutting it when latency rises.
  • uses an explore-and-exploit across engagement segments, because, Meta says, the gain from the stronger model does not always track a request's absolute value; exploratory traffic is kept to avoid stale routing.
  • Since the central controllers react on the order of minutes, servers and clients also shed lower-value opportunistic work on their own within a few milliseconds when capacity is suddenly preempted.
Terms in this piece · Glossary
  • Retrieval — Selecting evidence relevant to the current request.
  • Latency — The time between asking for a result and having it, including the model's generation time, tool calls, retries and any queueing.
  • model routing — Sending each request to a model chosen by the difficulty of the task, rather than using one model for everything.
  • Process — A running instance of a program, with its own working memory, open files and identity.

Get the Brief

A cited digest of what matters for people building with AI, every morning. Unsubscribe anytime. See today’s edition

Read the source engineering.fb.com
Recommended reads