Artificial Intelligence 10 min read

How to Model Architecture for a High‑Performance Recommendation System

This article walks through business, conceptual, logical, and physical modeling steps to design a recommendation system architecture, detailing value propositions, workflow decomposition, component breakdown, and technology choices to meet reliability, low‑latency, and scalability requirements.

Xiaokun's Architecture Exploration Notes
Xiaokun's Architecture Exploration Notes
Xiaokun's Architecture Exploration Notes
How to Model Architecture for a High‑Performance Recommendation System

Previously we introduced software architecture modeling methodology, emphasizing that modeling helps identify and manage complexity. This article demonstrates how to apply architecture modeling to design a recommendation system.

Business Modeling Analysis

The business model includes value proposition, business processes, and revenue structure, guiding technical implementation to align with commercial goals.

Value Proposition: Personalized recommendations help users filter items amid information overload, enhancing experience.

Business Process: Define the workflow for building a recommendation system.

Revenue Structure: Measure benefits such as increased CTR and GMV.

The top‑level business model for a recommendation system is illustrated below:

CIM Modeling Analysis

CIM modeling describes business requirements and domain logic, analyzes and defines business processes, and identifies complexity. It decomposes business capabilities into sub‑capabilities that together support the top‑level capability.

The resulting complete recommendation business workflow is shown below:

PIM Modeling Analysis

PIM focuses on translating the business workflow into system requirements, including non‑functional requirements. It refines the workflow into layers, modules, and functions.

Key components of a complete recommendation system include:

Data system: data collection, cleaning, storage, and visualization.

User and item profile & feature system: user attribute construction, item feature extraction, knowledge graph building, and feature engineering.

AI estimation system: data encoding, model training, and inference.

Online system: retrieval, recall, ranking, and rule filtering.

AB testing system: traffic segmentation and effect analysis.

System Layer Design

From the user request perspective, the system is layered as follows:

Request routing layer (gateway) for traffic distribution.

Recommendation engine layer with recall, ranking, and re‑ranking modules.

Item index layer providing unified data query capabilities.

Data collection and cleaning layer, using big‑data frameworks such as Lambda or Kappa.

Management and tracing layer for configuration management and observability (non‑functional requirements).

PSM Modeling Analysis

PSM (Physical Data Model) addresses how each module stores data on disk. It guides technology selection for implementation.

Considering a live‑stream recommendation system serving millions of users with peak traffic at 20:00‑20:05, we focus on the user‑profile service. The performance model is shown below:

<code><img src="https://mmbiz.qpic.cn/mmbiz_png/NAZR0mrHx5b7ibXhpXMRs3fXHX2Ih7cNBYOoWj0wUyxrDicxTFMq9iclslPVAhMbRS5zNGHy31GSrD5Eu2SeSMm5Q/640" /></code>

Three architectural alternatives are considered, emphasizing high performance and low latency. After evaluating reliability, availability, and latency, the chosen solution combines RocksDB and Redis.

Summary

We have completed an end‑to‑end architecture modeling process for a recommendation system, progressing from business architecture to application architecture. The layered model guides technology choices, deployment strategies, service decomposition, and performance evaluation.

AIrecommendation systemsystem designbusiness modelingarchitecture modeling
Xiaokun's Architecture Exploration Notes
Written by

Xiaokun's Architecture Exploration Notes

10 years of backend architecture design | AI engineering infrastructure, storage architecture design, and performance optimization | Former senior developer at NetEase, Douyu, Inke, etc.

0 followers
Reader feedback

How this landed with the community

login Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.