AI, GenAI and LLM systems
The content of a 2026 loop shifted hard. Classical ML theory is now perhaps a quarter of the technical rounds; the rest is retrieval architecture, evaluation, agents, serving economics and the quiet ways these systems fail. Definitions are free. Judgment is what is being bought.
Four things a modern loop probes that a 2022 loop never did: system design on top of a model you do not control, judgment about retrieval and evaluation, whether you can build and debug the integration by hand, and production sense about cost, latency and silent failure.
What this chapter covers
- [done] The transformer, walked through with tensor shapes
- [done] RoPE and ALiBi explained, not named
- [done] Tokenisation, BPE, and the multilingual token-count penalty
- [done] Prefill vs decode
- [done] Diagnosing confidently wrong RAG
- [done] Chunking, and why fixed-size is usually wrong
- [done] Hybrid retrieval and reciprocal rank fusion
- [done] Evaluating RAG
- [done] KV cache, GQA, paging and continuous batching
- [done] LLM cost engineering
- [done] Prompt injection and the lethal trifecta
- [done] Evaluating an agent
- [done] Cross-encoder and LLM reranking
- [done] FlashAttention, speculative decoding, quantisation and parallelism
- [done] The fine-tuning ladder, with a worked LoRA example
- [done] Sampling strategies, with demonstrated outputs
- [done] Structured output: JSON mode, constrained decoding, grammars
- [done] Classical ML you still need: calibration, leakage, drift
- [done] Regression gates in CI for LLM systems
Source: §15, §24, §41, §44.