Ai
20 pages
-
AI Agents
concept
Agent planning (ReAct, Reflexion); tool categories (knowledge, capability, write actions); function calling; multi-agent systems; planning/tool/efficiency failure modes; safety and compound errors; LLM planning debate
-
AI Engineering
concept
AI engineering as a discipline vs ML engineering; three-layer stack (application dev, model dev, infrastructure); product planning; last-mile challenge; use case taxonomy
-
AI Engineering
source
*AI Engineering* — Chip Huyen
-
AI Engineering Architecture
concept
Five-step progressive architecture (context enhancement, guardrails, router/gateway, caching, agents); model drift detection; orchestration frameworks; user feedback systems (explicit vs implicit, edit-as-preference, degenerate feedback loops, sycophancy)
-
AI Evaluation
concept
Evaluation methodology: perplexity, pass@k, BLEU/ROUGE, embeddings, AI-as-a-judge, comparative evaluation (Elo/Bradley-Terry, LMSYS Arena); factual consistency, safety, instruction-following; model selection workflow; API vs self-hosting; evaluation pipeline design; benchmark contamination
-
Continual Learning and Test in Production
concept
Stateless retraining vs stateful training (fine-tuning); four stages of continual learning maturity; champion/challenger pattern; test in production methods (shadow deployment, A/B testing, canary release, interleaving experiments, bandits, contextual bandits); data freshness value; continuous ML challenges (feedback loops, emergency response, stable A/B baselines)
-
Data Distribution Shifts
concept
Covariate shift/label shift/concept drift/feature change/label schema change taxonomy; degenerate feedback loops (mechanism, detection, correction via randomisation and positional features); detection methods (KS test, two-sample tests, feature validation, prediction monitoring, sliding vs cumulative statistics); proactive design; retraining strategies
-
Dataset Engineering
concept
Data-centric AI; three criteria (quality, coverage, quantity); acquisition and annotation; data synthesis (rule-based, simulation, AI-powered, reverse instruction); model distillation; model collapse; data processing pipeline
-
Designing Machine Learning Systems
source
*Designing Machine Learning Systems* — Chip Huyen
-
Feature Engineering
concept
Feature operations (missing value handling MNAR/MAR/MCAR, scaling, discretisation, categorical encoding/hashing trick, feature crossing, positional embeddings); data leakage causes and detection; feature importance (top 10 = 50% importance); feature generalisation (coverage × distribution overlap); best practices (split by time, scale after split)
-
Finetuning
concept
When to finetune vs RAG; memory bottleneck; quantisation (FP32→INT4); PEFT; LoRA (low-rank decomposition, rank, alpha, multi-LoRA serving); QLoRA; model merging (task arithmetic, TIES/DARE, frankenmerging); finetuning tactics
-
Foundation Models
concept
What foundation models are; transformer architecture (prefill/decode, KV cache, MoE); training data constraints; Chinchilla scaling law; post-training (SFT, RLHF, DPO)
-
Inference Optimization
concept
Inference metrics (TTFT, TPOT, throughput, goodput, MFU, MBU); prefill (compute-bound) vs decode (memory bandwidth-bound); speculative decoding; KV cache management (PagedAttention, FlashAttention, GQA/MQA); continuous batching; prefill-decode decoupling; prompt caching
-
LLM Sampling and Probabilistic Outputs
concept
Sampling strategies (temperature, top-k, top-p); test-time compute; structured outputs; hallucination (self-delusion + knowledge-mismatch hypotheses); inconsistency mitigation
-
ML Systems Design
concept
When to use ML (nine conditions); research vs production differences (silent failure, latency vs throughput, messy data, fairness, interpretability); four system requirements (reliability, scalability, maintainability, adaptability); business vs ML objective alignment; problem framing (task types, decoupling objectives); mind vs data debate
-
MLOps Infrastructure and Tooling
concept
Four-layer MLOps stack (storage/compute, resource management, ML platform, dev environment); cloud repatriation; Docker + Kubernetes; workflow orchestration tools (Airflow/Argo/Prefect/Metaflow); model store (8 artifact types); feature store (management/computation/consistency, eliminates training-serving skew); build vs buy framework
-
Model Development and Offline Evaluation
concept
Six model selection tips; four phases of ML adoption; ensembles (bagging/boosting/stacking); experiment tracking and data versioning challenges; ML debugging; distributed training (data/model/pipeline parallelism); AutoML (hyperparameter tuning, NAS, learned optimisers); offline evaluation baselines; evaluation methods (perturbation, invariance, directional expectation, calibration, confidence, slice-based/Simpson's paradox)
-
Prompt Engineering
concept
Prompt anatomy; system vs user prompt; chat templates; in-context learning (zero/few-shot, CoT); prompt decomposition; defensive prompt engineering (extraction, jailbreaking, injection, information extraction); three-layer defence (model/prompt/system)
-
Reliable Machine Learning
source
*Reliable Machine Learning* — Chen, Murphy, Parisa, Sculley, Underwood
-
Retrieval-Augmented Generation (RAG)
concept
Retrieval-augmented generation; term-based (TF-IDF, BM25) vs embedding-based retrieval; ANN algorithms (LSH, HNSW, FAISS); hybrid search with RRF; chunking; reranking; contextual retrieval; text-to-SQL; memory model