---
title: "Meta’s Generative Ads Model (GEM): Scaling the Central Model and Compute Engine for Frontier Ads AI"
description: "Meta's 2026 GEM replaces per-surface ads ranking models with a single central recommendation foundation model trained across Facebook, Instagram, Reels and deep-funnel conversion objectives, reporting 18.9% conversion and 12% CTR gains."
url: "https://swe.quest/articles/meta-s-generative-ads-model-gem-scaling-the-central-model-and-compute-engine-588a45420da8f0cd"
canonical: "https://engineering.fb.com/2026/10/13/ml-applications/generative-ads-model-gem-scaling-frontier-ads-ai/"
source: "Meta Engineering"
published: "2026-10-13"
difficulty: "hard"
kind: "Case study"
reading_minutes: 14
tags: ["recommendation-systems","ads","model-training","inference","scalability"]
---

# Meta’s Generative Ads Model (GEM): Scaling the Central Model and Compute Engine for Frontier Ads AI

A post on [Meta Engineering](https://swe.quest/sources/meta.md), published 2026-10-13, 14 min read, Case study. Original: [https://engineering.fb.com/2026/10/13/ml-applications/generative-ads-model-gem-scaling-frontier-ads-ai/](https://engineering.fb.com/2026/10/13/ml-applications/generative-ads-model-gem-scaling-frontier-ads-ai/)

## Summary

Meta's 2026 GEM replaces per-surface ads ranking models with a single central recommendation foundation model trained across Facebook, Instagram, Reels and deep-funnel conversion objectives, reporting 18.9% conversion and 12% CTR gains. Its new Kunlun architecture uses block-sparse attention, a GDPA kernel that unifies attention-like ops, MoE-style cross interaction with expert parallelism, component skipping (43% fewer FLOPs) and unified user sequences. Together these support 2.5x model complexity and an LLM-like scaling law, with prediction quality following a power law in sequence length. Intelligence reaches latency-bound vertical models through LoopFM precomputed structured representations, which double transfer effectiveness over plain distillation, and through Solaris speculative precomputation of user-ad embeddings with hierarchical fallback. Custom low-precision kernels and 5D parallelism reach 20-25% MFU at 4x the training FLOPs.

Written by swe.quest, not by the author.

**Difficulty:** Hard: written for specialists in the field

## Topics

- [Recommendations & ranking](https://swe.quest/tags/recommendation-systems.md) (AI & ML)
- [Ads](https://swe.quest/tags/ads.md) (Domains)
- [Model training](https://swe.quest/tags/model-training.md) (AI & ML)
- [Inference & serving](https://swe.quest/tags/inference.md) (AI & ML)
- [Scaling](https://swe.quest/tags/scalability.md) (Distributed systems)

## Prerequisites

- transformer attention
- recommender ranking models ([easy posts on Recommendations & ranking](https://swe.quest/tags/recommendation-systems.md?difficulty=easy))
- knowledge distillation
- mixture-of-experts

## Keywords

GEM, Kunlun, LoopFM, Solaris, Interformer, Generalized Dot-Product Attention, 5D parallelism

## Related posts

- [Meta’s Generative Ads Model (GEM): The Central Brain Accelerating Ads Recommendation AI Innovation](https://swe.quest/articles/meta-s-generative-ads-model-gem-the-central-brain-accelerating-ads-5d5a24731a15c0eb.md): Meta Engineering · 2025-11-10 · Hard · 10 min read · Recommendations & ranking, Ads, Model training, ML platforms
  GEM is Meta's LLM-scale foundation model for ads recommendation, trained on thousands of GPUs and used as a teacher to improve hundreds of downstream vertical ranking models; it lifted ad conversions 5% on Instagram and 3% on Facebook Feed.
- [GEM Training: How Meta Doubled the Efficiency of Its LLM-Scale Ads Foundation Model](https://swe.quest/articles/gem-training-how-meta-doubled-the-efficiency-of-its-llm-scale-ads-foundation-1bf8547a323404ba.md): Meta Engineering · 2026-08-03 · Hard · 21 min read · Model training, Recommendations & ranking, Performance engineering, Hardware, Ads
  Meta doubled end-to-end training efficiency of GEM, its LLM-scale ads recommendation foundation model, to 20–25% MFU while scaling training FLOPs 4x in a year, by co-designing kernels, precision, parallelism, networking and memory.
- [Meta Adaptive Ranking Model: Bending the Inference Scaling Curve to Serve LLM-Scale Models for Ads](https://swe.quest/articles/meta-adaptive-ranking-model-bending-the-inference-scaling-curve-to-serve-llm-b02b370caa05f2c4.md): Meta Engineering · 2026-03-31 · Hard · 9 min read · Recommendations & ranking, Inference & serving, Ads, Performance engineering, Hardware
  Meta Adaptive Ranking Model serves LLM-scale ads ranking models (O(10 GFLOPs) per token, O(1T) parameters) at O(100 ms) latency by routing each request to an appropriately complex model and computing user signals once per request instead of once per ad candidate.
- [From User Sequences to Scaling Laws: A Multi-Stage Architecture for Meta’s Ads Ranking](https://swe.quest/articles/from-user-sequences-to-scaling-laws-a-multi-stage-architecture-for-meta-s-ads-3c689db90be36667.md): Meta Engineering · 2026-08-05 · Hard · 6 min read · Recommendations & ranking, Ads, Model training, Machine learning, Scaling
  Meta scales sequence learning for ads ranking by splitting it into two stages: an offline transformer user model processes thousands of user events asynchronously and caches user-level embeddings, and a lightweight online ranking model combines those embeddings with fresh signals and ad candidates under strict latency budgets.
- [Meta Andromeda: Supercharging Advantage+ automation with the next-gen personalized ads retrieval engine](https://swe.quest/articles/meta-andromeda-supercharging-advantage-automation-with-the-next-gen-ea5fc57c7e788d2c.md): Meta Engineering · 2024-12-02 · Hard · 7 min read · Recommendations & ranking, Ads, Inference & serving, Hardware, Machine learning
  Andromeda is Meta's ML-based ads retrieval engine that narrows tens of millions of ad candidates to a few thousand per request.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
