Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Airbnb Engineering 8 min read Case study mediumAdept

The guest journey, updated in real time: extending Airbnb’s sequence recommender with Chronon

Airbnb moved its Transformer-based guest sequence encoder from a daily batch job, where embeddings could lag behavior by nearly two days, to a near-real-time pipeline built on two new Chronon capabilities. Push Mode makes streaming jobs emit a notification as soon as they commit a feature update, and NRT Model Transform calls the already-deployed encoder inside the streaming flow and writes the embedding to the same low-latency store the ranking model already reads. Embeddings now typically update within 10–30 seconds of guest activity. Offline NDCG rose 1.67% and an A/B test showed about a 0.33% lift in uncancelled bookings, showing freshness alone improves ranking quality.

Related posts

  • From Activity to Intent: Generating User Journeys with LLMs

    Pinterest Engineering mediumAdept

    Pinterest replaced a multi-stage keyword-clustering pipeline for inferring user "journeys" (long-horizon goals like a kitchen remodel) with a single fine-tuned 4B Qwen3 model. The model reads a compact chronological activity log and emits a ranked JSON list of localized journey names, with the prompt itself encoding ranking, dedup, noise and safety policy. The student was distilled via LoRA SFT from frontier-model teacher outputs; a few thousand diverse, hard examples were enough, and 4B beat 0.6B/1.7B/8B on the quality/throughput tradeoff. Serving uses NVIDIA Dynamo with vLLM on ~100 L40S GPUs at ~775 req/s (p50 1.2s, p95 3.0s), with KV-aware routing and prefix caching, and skips recently inferred users. Online tests showed 1.1% email CTR and 1.3% push open lifts over the clustering system.

  • Safe and Efficient Multi-Epoch Embedding Training

    Pinterest Engineering hardMaster

    Fine-tuning large pretrained ID embedding tables for more than one epoch in Pinterest's Homefeed ranking model caused about a 6% offline save regression. Freezing the table and isolating gradient paths traced the overfitting to the embedding table. The best recipe was delayed adaptation: keep the table frozen for early epochs and co-train it only in the final epoch. Update timing correlated roughly linearly with quality, and the recipe beat both the one-epoch and fully frozen models, with gains such as +1.16% on a 20-day window. To make longer training affordable, a semi-synchronous pipeline overlaps sharded embedding all-to-all lookups with compute using bounded one-step staleness, alongside fused ID lookups and a specialized cuEmbed singleton-row gather that keeps torch.compile tracing intact.

  • Sequence learning: A paradigm shift for personalized ads recommendations

    Meta Engineering hardMaster

    Meta replaced its DLRM ads ranking models, which depended on thousands of hand-engineered aggregated sparse features, with sequence learning over event-based features (EBFs). These features preserve the order and fine-grained attributes of a person's engagement and conversion events. An event model compresses per-attribute embeddings and adds timestamp encodings, and a transformer-based sequence model uses multi-headed attention pooling keyed by the candidate ad, cutting attention cost from O(N²) to O(M·N). Variable-length sequences are made production-viable through jagged tensor support in PyTorch, GPU kernels, Jagged Flash Attention, quantization and vector quantization. The result was a 2-4% conversion lift on select segments, with plans to scale sequences 100x and explore linear attention and state space models.

  • The journey of building a comprehensive attribution platform

    Grab Engineering easyNovice

    Grab's ads and promo attribution system evolved from a Kappa-architecture streaming engine to a Lambda architecture that pairs real-time stream processing with Spark batch jobs over S3. The pure streaming design cut attribution latency from 2-3 days to minutes, but it struggled with processing cost, long attribution windows, out-of-order events and multi-touch models. Adding an offline batch layer gave historical context and fault tolerance, kept discrepancies under 1% and cut real-time processing costs by about 25%. To limit the cost of maintaining two codebases, Grab plans to reserve the real-time path for time-sensitive metrics such as cost-per-order budget capping and move all other reporting to batch.

  • From Scoring to Spelling: Rebuilding Ads Retrieval at Instacart

    Instacart Tech hardMaster

    Instacart replaced its BERT-based ads retrieval model, which scored every atomic product ID in a fixed vocabulary, with a generative model that autoregressively decodes Semantic IDs (RQ-VAE codeword sequences) via beam search. The goal was to fix vocabulary bottlenecks, cold-start bias toward popular items, and incoherent candidate sets. Prompts combine a retailer-type token, user history SIDs and cart SIDs. SIDs shrink embedding parameters 125x and give new products coverage from day one, while beam width and temperature act as dials between precision and diversity. Serving moved from Python on CPU to a Go service on TensorRT-LLM and Triton. Mean latency dropped 10–17% despite roughly twice the candidates, and A/B tests showed +5% CTR and +34% add-to-carts.

The quest for software engineering knowledge.

Look:
Layout: