← Back to Index

2. Core Objectives

Every ML system design balances five core objectives. Your design choices prioritize some over others depending on the use case.

1. Scalability

The ability to handle growing data volumes, request rates, and model complexity. Measured by throughput (requests/second, predictions/hour) and data throughput (GB/hour through the pipeline).

2. Latency

End-to-end response time from request to prediction. Critical for real-time applications.

ApplicationLatency Target
Real-time fraud detection<100ms
Recommendation serving<200ms
Chatbot response<1s
Batch predictionsMinutes—hours

Latency is budgeted across components: network → feature fetch → inference → post-processing.

3. Reliability

Measured by uptime percentage and prediction quality consistency. Includes fault tolerance (graceful degradation when components fail) and accuracy stability (model quality does not degrade over time).

4. Adaptability

The ability to respond to changing conditions: data distribution shifts, new user behaviors, business requirement changes.

5. Explainability & Fairness

Increasingly non-negotiable for regulated industries. Explainability means understanding why a model made a particular prediction. Fairness means ensuring the model does not discriminate against protected groups.

# Example: fairness monitoring
Group A (majority): approval rate = 72%
Group B (minority): approval rate = 68%
Disparity: 4% → acceptable (threshold: 5%)
If disparity > 5%: alert for investigation
Exercise: Rank the five objectives for each scenario: a) an ML-powered medical diagnosis system, b) a real-time ad serving system, c) a batch ML job that generates weekly reports. Explain the reasoning behind each ranking.