# Architecture
> 250 posts about Architecture, summarised, each linking to the original.

## Articles

### [Making User-Sequence Data More Cost-Efficient, Faster, and Easier to Use](https://yomu.fyi/post/making-user-sequence-data-more-cost-efficient-faster-and-easier-to-use.md)
- Company: [Pinterest](https://yomu.fyi/company/pinterest.md)
- Author: Pinterest Engineering
- Published: May 21, 2026

User sequences serve as core primitives powering machine learning models across ranking, retrieval, and recommendation surfaces at Pinterest. Managing these sequences previously caused high infrastructure costs, operational fragility, and data drift between offline training pipelines and online serving systems. In response, engineering teams redesigned the platform around a single definition executed across multiple runtimes, including real-time streaming, batch backfills, and online inference. The updated architecture pairs a unified enrichment engine with columnar time-partitioned storage and standardized validation tiers. Consequently, the redesign achieved lower storage and network costs, faster signal onboarding via configuration, and improved engagement metrics across major recommendation surfaces.


### [How Partition Access Visualizations Reduced our Data Lake S3 Cost by 33%](https://yomu.fyi/post/how-partition-access-visualizations-reduced-our-data-lake-s3-cost-by-3.md)
- Company: [Yelp](https://yomu.fyi/company/yelp.md)
- Author: Nick Del Nano, Data Streaming
- Published: May 21, 2026

Data teams at Yelp struggled to identify table consumers and track how datasets were accessed across their petabyte-scale data lake. To solve this, the team built a usage attribution system using Amazon S3 server access logs to visualize time-based partition keys against access timestamps and IAM roles. These visualizations revealed distinctive patterns for daily batch jobs, backfills, and ad hoc queries, guiding migrations of thousands of tables to Apache Iceberg format. Furthermore, Yelp implemented a Default Access Retention strategy gated by IAM bucket policies to prevent accidental queries from resetting S3 Intelligent Tiering transitions. Combining these granular usage insights with targeted S3 storage classes reduced Yelp's S3 storage costs by 33 percent.


### [Scaling Airbnb’s identity graph with a unified knowledge graph infrastructure](https://yomu.fyi/post/scaling-airbnb-s-identity-graph-with-a-unified-knowledge-graph-infrast.md)
- Company: [Airbnb](https://yomu.fyi/company/airbnb.md)
- Author: Lucen Zhao
- Published: May 19, 2026

Airbnb migrated its massive identity graph from a third-party graph database vendor to a unified, in-house knowledge graph platform to solve long-tail latency and scaling bottlenecks. Built on JanusGraph with AWS DynamoDB for persistence and OpenSearch for indexing, the new architecture decouples storage operations from graph traversal logic. The migration improved P99 query latency, eliminated routine instance reboots, and supported a tenfold increase in write throughput.


### [Making LLMs faster without sacrificing accuracy](https://yomu.fyi/post/making-llms-faster-without-sacrificing-accuracy.md)
- Company: [Amazon](https://yomu.fyi/company/amazon.md)
- Author: Tao Yu, Youngsuk Park
- Published: May 15, 2026

Standard scaling laws optimize parameter count and training data budgets to minimize loss but ignore internal Transformer architecture configurations. To address throughput disparities among equally sized models, researchers developed a scaling framework incorporating hidden size, the multilayer perceptron to attention parameter ratio, and grouped-query attention. The method calibrates a correction surface over standard Chinchilla scaling laws to independently optimize separable architectural parameters for target accuracy. Evaluated across more than 200 models up to three billion parameters, the framework produced the Panda model family for maximum accuracy and the Surefire family for Pareto efficiency. Surefire models matched or exceeded LLaMA-3.2 accuracy while increasing inference throughput by 12% to 47% across vLLM and SGLang serving systems on modern GPUs.


### [From latency to instant: Modernizing GitHub Issues navigation performance](https://yomu.fyi/post/from-latency-to-instant-modernizing-github-issues-navigation-performan.md)
- Company: [Github](https://yomu.fyi/company/github.md)
- Author: Natalie Guevara
- Published: May 14, 2026

GitHub Issues addressed navigation latency by shifting workloads to the client using a local-first, stale-while-revalidate architecture. To evaluate perceived delays, the team tracked user transitions through Highest Priority Content thresholds, aiming for instant rendering in under 200 milliseconds. The core implementation added a persistent client-side cache using IndexedDB, paired with a synchronous in-memory tier to serve hot issue payloads without asynchronous overhead. A selective preheating mechanism resolves missing cache entries for high-intent links without overburdening backend capacity with redundant requests. Following broad rollout, the proportion of instant React soft navigations increased from 4% to approximately 22%, yielding an overall cache-hit ratio of around 33%.


### [Enhancing Ad Relevance: Integrating Real-Time Context into Sequential Recommender Models](https://yomu.fyi/post/enhancing-ad-relevance-integrating-real-time-context-into-sequential-r.md)
- Company: [Pinterest](https://yomu.fyi/company/pinterest.md)
- Author: Pinterest Engineering
- Published: May 8, 2026

Pinterest's sequential ads candidate generator inferred user embeddings offline from historical offsite conversions, which lacked real-time browsing context. Consequently, less than 1% of impressions on the Related Pins surface were attributed to this generator because its retrieved candidates struggled in downstream ranking. To resolve this limitation, engineers developed the Contextual Sequential Two Tower Model, integrating a context layer directly into the query tower alongside user demographic features. Offline training utilized synthetic context derived from positive conversion labels paired with high dropout rates to preserve sequence reliance, while serving split into offline Transformer inference and online context computation. Offline evaluations showed a 3x to 10x increase in Recall@K, and production deployment lifted median candidate relevance by 275% to 300% and overall ROAS by approximately 0.7%.


### [Fixing JavaScript observability, one library at a time](https://yomu.fyi/post/fixing-javascript-observability-one-library-at-a-time.md)
- Company: [Sentry](https://yomu.fyi/company/sentry.md)
- Author: Abdelrahman Awad
- Published: May 7, 2026

JavaScript application performance monitoring tools rely on monkey-patching via require-in-the-middle and import-in-the-middle, which breaks with ECMAScript Modules, bundlers, and non-Node runtimes. To solve this, an initiative is replacing monkey-patching with Node's built-in diagnostics\_channel TracingChannel API across server-side JavaScript libraries. Under this pattern, libraries publish structured events while monitoring vendors subscribe to them with zero overhead when unlistened. The author leveraged Claude Code workflows alongside direct maintainer communication to draft proposals, implement code, and manage reviews across 44 target packages. Ten libraries including mysql2, node-redis, ioredis, and unjs modules have merged support, while active efforts continue on shared OpenTelemetry mapper registries and remaining ecosystem packages.


### [Navigating uncertainty in Amazon&apos;s middle-mile network](https://yomu.fyi/post/navigating-uncertainty-in-amazon-apos-s-middle-mile-network.md)
- Company: [Amazon](https://yomu.fyi/company/amazon.md)
- Author: Ruth Misener, Hana Ku, Georgios Paschos
- Published: May 6, 2026

Amazon's middle-mile logistics network coordinates tens of millions of packages across hundreds of facilities while managing subtle demand variations and major operational disruptions. To solve this mixed-integer optimization challenge without combinatorial explosion, Amazon models routes at coarse time resolutions augmented by precomputed 15-minute timing bounds. The system uses Monte Carlo methods alongside a graph attention network featuring interconnected site graphs and origin-destination graphs to capture complex spatial correlations and flow interdependencies. By generating synthetic flow permutations, planners stress-test candidate network designs against hundreds of plausible scenarios to prioritize routing optionality. This risk-aware modeling approach preserves network flexibility, absorbs severe shocks, and yields potential cost savings while safeguarding delivery promises.


### [From SSH to REST: A Security-Driven Modernization of Slack’s EMR Data Pipelines](https://yomu.fyi/post/from-ssh-to-rest-a-security-driven-modernization-of-slack-s-emr-data-p.md)
- Company: [Slack](https://yomu.fyi/company/slack.md)
- Author: Mahendran Vasagam
- Published: May 5, 2026

Slack's data platform accumulated over 700 SSH-based Airflow operators executing jobs directly on AWS Elastic MapReduce clusters, creating broad security surfaces and operational instability. Stateful SSH connections frequently failed when Kubernetes pods restarted, leaving orphaned zombie processes and preventing infrastructure modernization such as migrating EMR clusters to child accounts. To eliminate SSH access, Slack adopted a REST-based architecture using Quarry, a gateway providing unified REST APIs and token authentication across compute engines. For non-Hadoop CLI workloads, Slack leveraged YARN Distributed Shell to execute arbitrary shell scripts stored in Amazon S3 within managed, isolated YARN containers. The phased migration achieved zero downtime across eight data regions, unlocking reliable monitoring, simplified onboarding, and future initiatives like Spark on Kubernetes.


### [How mechanism design theory helps optimize Amazon-vendor collaboration](https://yomu.fyi/post/how-mechanism-design-theory-helps-optimize-amazon-vendor-collaboration.md)
- Company: [Amazon](https://yomu.fyi/company/amazon.md)
- Author: Dirk Bergemann
- Published: May 5, 2026

Amazon and its vendors face an asymmetric information problem when coordinating purchase orders across fulfillment centers because neither party shares proprietary cost, capacity, or demand data. To solve this coordination gap without exposing sensitive information, Amazon's Supply Chain Optimization Technologies organization designed Flo Pro by integrating the Vickrey-Clarke-Groves mechanism with the Consensus Planning Protocol. The distributed optimization framework uses the alternating-direction method of multipliers to coordinate iterative agent responses, calculating cost-benefit transfers across rolling six-week planning horizons. In lower-dimensional settings, Amazon also evaluated a transparent menu-of-contracts approach where vendors select optimal plans priced at Amazon's incurred costs. A nine-week pilot with a consumer-product manufacturer confirmed that Flo Pro successfully aligns incentives and achieves measurable cost savings.


### [Optimizing ML Workload Network Efficiency (Part I): Feature Trimmer](https://yomu.fyi/post/optimizing-ml-workload-network-efficiency-part-i-feature-trimmer.md)
- Company: [Pinterest](https://yomu.fyi/company/pinterest.md)
- Author: Pinterest Engineering
- Published: May 1, 2026

Pinterest deployed a root-leaf architecture for online machine learning serving to decouple CPU-based feature preprocessing from GPU-based inference. Because the root cluster retrieved a union of features across models and fanned out the full set to every leaf, network bandwidth became a severe bottleneck. After initial tests with fbthrift LZ4 compression yielded a 20% bandwidth reduction at the cost of CPU and latency overhead, the team implemented Feature Trimmer. This mechanism uses exported model signatures as the source of truth to prune unused features on the root before transmission. By dispatching only required features per model, the system reduced network bandwidth, decreased latency, and enabled cluster rightsizing that saved over $4M annually.


### [Data Mesh at Grab (Part II): The foundational tools behind certification](https://yomu.fyi/post/data-mesh-at-grab-part-ii-the-foundational-tools-behind-certification.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Aezo Teo
- Published: Apr 30, 2026

Grab operationalizes its Signals Marketplace data mesh through integrated platforms designed for continuous data certification and observability. The central metadata management platform, Hubble, extends open-source DataHub to model metadata as an event-driven graph and expose search, lineage, ownership, and data contracts. An automated certification engine built on the DataHub Actions framework continuously evaluates metadata changes, classifying assets into Uncertified, Certified, CertifiedPlus, or Revoked states. Genchi serves as the data quality observability layer, using Temporal and Kafka to run checks for freshness, volume completeness, schema stability, and semantic rules. To eliminate false-positive alerts caused by decoupled cron schedules, Genchi integrates with the Lighthouse monitoring service to trigger quality tests immediately upon pipeline completion.


### [From Clicks to Conversions: Architecting Shopping Conversion Candidate Generation at Pinterest](https://yomu.fyi/post/from-clicks-to-conversions-architecting-shopping-conversion-candidate.md)
- Company: [Pinterest](https://yomu.fyi/company/pinterest.md)
- Author: Pinterest Engineering
- Published: Apr 27, 2026

Pinterest built a dedicated shopping candidate generation model to optimize for lower-funnel purchase conversions rather than relying strictly on engagement retrieval models. Because offsite conversion events are sparse and delayed, engineers trained a single multi-surface two-tower model using conversion data supplemented by duration-weighted click engagement and unengaged ad impressions as hard negatives. The two-tower retrieval architecture incorporates a parallel DCN v2 and MLP layer structure that allows simultaneous learning from the same inputs without information bottlenecks. Later revisions transitioned the system from a multi-head loss structure to a unified single-head multi-task architecture paired with an advertiser-level objective. Deployed across more than 600 million monthly active users, the system increased shopping conversion volume by 2.3% and boosted return on ad spend by 3.1% for United States shopping campaigns.


### [How Yelp Keeps Server-Driven UI Consistent Across Four Platforms](https://yomu.fyi/post/how-yelp-keeps-server-driven-ui-consistent-across-four-platforms.md)
- Company: [Yelp](https://yomu.fyi/company/yelp.md)
- Author: Radu Comaneci, Software Engineer
- Published: Apr 22, 2026

Yelp maintains two major applications across Web, iOS, and Android, which previously led to fragmented server-driven UI implementations with mismatched backend component representations. To unify its server-driven UI framework, CHAOS, with its cross-platform design system, Cookbook, Yelp built an automated bridge library called Konbini. Konbini reads centralized JSON interface definitions through Jenkins pipelines to automatically generate synchronized libraries for Python, Kotlin, Swift, and TypeScript. These generated libraries handle component serialization on the backend and deserialization on client platforms. To maintain backward compatibility when component interfaces introduce breaking changes, client requests pass versioned spec identifiers, prompting the backend to execute migration methods that downcast newer component models to older supported versions.


### [Managing context in long-run agentic applications](https://yomu.fyi/post/managing-context-in-long-run-agentic-applications.md)
- Company: [Slack](https://yomu.fyi/company/slack.md)
- Author: Dominic Marks
- Published: Apr 13, 2026

Long-running multi-agent systems struggle with context management because accumulating raw message histories degrades inference quality, increases latency, and exceeds context window limits. In a collaborative security investigation platform, passing unrestricted history can also introduce confirmation bias across specialized agents. To maintain coherence across unbounded rounds of investigation, the system eliminates raw message history carryover between invocations. Instead, it coordinates agents through three structured context channels: a Director's Journal for orchestration memory, a Critic's Review that scores findings to filter hallucinations, and a Critic's Timeline of validated chronological events. This architecture provides agents with tailored context without overwhelming their inference capacity.


### [Improving storage efficiency in Magic Pocket, our immutable blob store](https://yomu.fyi/post/improving-storage-efficiency-in-magic-pocket-our-immutable-blob-store.md)
- Company: [Dropbox](https://yomu.fyi/company/dropbox.md)
- Author: Ilya Yakovlev,Andrew Cheung,Binoy Dash,Simran Jumani,Dmitriy Meyerzon,Mark Breitenbach,Ishan Mishra,Kazuaki Okumura,Mike White,Kevin Altschuler,Facundo Agriel
- Published: Apr 2, 2026

After introducing a direct erasure-coding service, Dropbox encountered severe storage fragmentation in its immutable blob store, Magic Pocket, due to a large number of under-filled volumes. Because their legacy compaction strategy was only designed to top off near-full volumes, the team created new multi-strategy compaction methods to aggressively consolidate sparse volumes. These approaches leverage dynamic programming and streaming pipelines to rapidly reclaim unused disk capacity at exabyte scale.


### [Predicting Rider Conversion in Sparse Data Environments with Bayesian Trees](https://yomu.fyi/post/predicting-rider-conversion-in-sparse-data-environments-with-bayesian.md)
- Company: [Lyft](https://yomu.fyi/company/lyft.md)
- Author: Zammit Alban
- Published: Mar 30, 2026

Lyft requires real-time predictions of whether a rider will request a ride after viewing price and ETA details to balance supply and demand and personalize user experiences. Traditional machine learning models overfit on high-cardinality, sparse context intersections, whereas deep neural networks introduce unacceptable inference latency during live user sessions. To address this, engineers created a hierarchical Bayesian tree framework that organizes session data into increasingly granular context partitions. Each node houses a parametric model trained top-down, applying Gaussian Bayesian priors and L2 penalties relative to parent parameters to smooth predictions in data-rare child segments. Using simple parametric models at each node also permits monotonic constraints, guaranteeing logically consistent predictions aligned with domain expectations.


### [Building Biz Ask Anything: From Prototype to Product](https://yomu.fyi/post/building-biz-ask-anything-from-prototype-to-product.md)
- Company: [Yelp](https://yomu.fyi/company/yelp.md)
- Author: Maria Christoforaki, Group Tech Lead; Shree Shalini Pusapati, Software Engineer
- Published: Mar 27, 2026

Yelp expanded Yelp Assistant to business pages by developing a question-answering architecture that extracts concise, evidence-backed answers from reviews, photos, and structured facts. The production system replaces static snapshots with near-real-time streaming pipelines for reviews and structured properties alongside weekly batch ingestion for menus and website data. For each incoming query, the system evaluates intent, retrieves relevant context through keyword and embedding searches, and constructs targeted prompts with dynamically selected few-shot examples. Synthesized answers are augmented with supporting visuals and citations before being streamed token-by-token to users. Generating suggested questions directly from specific business content rather than generic categories improved user engagement by roughly fifty percent and reduced unanswerable queries by twenty-six percent.


### [How Slack Rebuilt Notifications 📣](https://yomu.fyi/post/how-slack-rebuilt-notifications.md)
- Company: [Slack](https://yomu.fyi/company/slack.md)
- Author: Frances Coronel
- Published: Mar 19, 2026

Slack redesigned its legacy notification architecture to address user confusion, conflicting desktop and mobile preference systems, and tight coupling between notification content and push delivery. The engineering team unified four separate preference models into a single framework with three channel options: All new posts, Mentions, and Mute. To ensure safe rollback and backwards compatibility without direct database mutations, Slack implemented a read-time translation strategy alongside a new desktop\_push\_enabled preference and auto-saving cross-platform React UI components. This decoupling of activity from push delivery resulted in a fivefold sustained increase in settings engagement, reduced reliance on per-channel overrides, and eliminated synchronization mismatches across mobile and desktop clients.


### [From firefighting to building: How AI agents restored our team’s core productivity](https://yomu.fyi/post/from-firefighting-to-building-how-ai-agents-restored-our-team-s-core-p.md)
- Company: [Grab](https://yomu.fyi/company/grab.md)
- Author: Sneh Agrawal
- Published: Mar 19, 2026

Grab's Analytics Data Warehouse team spent roughly 40% of their engineering bandwidth answering repetitive questions, tracing data lineage, and handling basic pipeline enhancement requests across more than 15,000 tables. To eliminate these manual investigative bottlenecks, the team implemented a multi-agent AI architecture using FastAPI, LangGraph, Redis, and PostgreSQL. Incoming requests route through two dedicated pathways: an enhancement pipeline for generating code changes and an investigation pipeline for diagnosing data anomalies. Specialized agents interact with underlying engines like Trino, GitLab, and observability platforms to query data, trace transformations, and check ongoing incidents before synthesizing findings. This system automates the context-gathering process within minutes while maintaining human-in-the-loop review for merge requests and production changes.


[Newer posts](https://yomu.fyi/topic/architecture/page/5.md) · [Older posts](https://yomu.fyi/topic/architecture/page/7.md)
