ai_ml / README.md

ML system design

1 min read index source

ML system design

# File Covers
01 01_ml_design_framework.md the structure to apply to any question; capacity arithmetic; feedback loops
02 02_design_a_rag_assistant.md the most likely AI design question for a backend engineer
03 03_design_fraud_detection.md the canonical classical-ML design: imbalance, cost thresholds, label delay, adversarial drift

The two things that carry most questions

Say the outline before diving in. Clarify the decision, frame the ML problem, state the baseline, define metrics, then data, model, serving, rollout, monitoring, failure modes. Candidates who start at model architecture have skipped everything that matters.

Retrieve-then-rank covers search, recommendations, ads and RAG. The capacity arithmetic forces it: scoring every candidate with an expensive model at production QPS is impossible, so a cheap high-recall stage feeds an expensive high-precision one.