Lessons
496 lessons · intermediate · page 5 of 21
- AIintermediate
Gateway, Tools, and the M by N Problem
An agent is only as useful as the things it can do, and connecting many agents to many tools is a multiplication problem that gets expensive fast. This lesson covers what AgentCore Gateway converts into tools and how, the semantic search that stops tool overload, the two directions of authentication, and the managed sandboxes for code and browsing.
7 steps·~11 min - AIintermediate
Running an Agent: Runtime, Harness, and Session Isolation
An agent is a loop that runs for minutes, holds state, executes code it just wrote, and must not leak anything into the next user's session. This lesson covers what AgentCore Runtime provides that a container does not, why session isolation is the load-bearing guarantee, and where the managed Harness sits against bringing your own loop.
7 steps·~11 min - AIintermediate
Bedrock: One Door to Many Models
Amazon Bedrock's pitch is that model choice becomes a configuration value instead of a rewrite. This lesson takes that claim apart: the four API dialects Bedrock exposes over the same models, what the unified Converse API actually normalises, what it cannot normalise, and the inference and governance machinery that decides cost and blast radius.
7 steps·~11 min - Programmingintermediate
Flakiness, Coverage, and Suites That Survive
A test suite is a product with a maintenance cost, and two forces decide whether it stays useful: flakiness, which destroys the signal, and the metrics teams use to judge it, which mostly measure the wrong thing. This lesson covers where flakiness comes from, the arithmetic that makes it fatal at scale, what coverage research actually found, and what to measure instead.
8 steps·~12 min - Programmingintermediate
Property-Based Testing: Assert the Law, Not the Example
An example-based test checks the cases you thought of, which is exactly the set that excludes your bugs. Property-based testing inverts it: state a law the code must obey for all inputs, let the machine hunt for a counterexample, and let it shrink that counterexample to something you can read. This lesson covers the property patterns, generators, shrinking, and where the technique stops fitting.
7 steps·~11 min - Programmingintermediate
Test Doubles: Isolation and What It Costs
Replacing a real dependency with a stand-in is what makes a unit test fast, deterministic, and able to reach states you cannot otherwise produce. It is also how a suite ends up green while the system is broken. This lesson covers the five kinds of double, when each is right, and the two failure modes that follow every team who reaches for mocks by reflex.
8 steps·~12 min - Programmingintermediate
What Is Worth Testing, and the Shape That Follows
Every test costs time to write, time to run, and time to maintain when the code moves. This lesson works out what that budget should buy: what each level of test can and cannot catch, why the pyramid has the shape it does, why some teams invert it, and the arithmetic that decides both questions before anyone argues about it.
8 steps·~12 min - Businessintermediate
Peeking: How Watching Your Experiment Ruins It
The most natural behaviour in experimentation, checking results daily and stopping when they look significant, quietly destroys the statistical guarantee everyone thinks they have. This lesson shows the peeking mechanism with honest arithmetic, then the fixes: fixed-horizon discipline, group sequential designs, and always-valid inference.
7 steps·~11 min - Businessintermediate
Assignment, Exposure, and the Smoke Detector Called SRM
Most wrong experiment results are not statistical subtleties; they are plumbing. This lesson covers how assignment actually works, hashing, not coin flips, why exposure must be logged at the moment of treatment, and the sample ratio mismatch check: the humble comparison of observed to expected group sizes that catches more broken experiments than any other single test.
7 steps·~11 min - Businessintermediate
Why Everything Gets Tested, and What a Test Actually Is
The companies famous for experimentation did not adopt it out of statistical enthusiasm: they adopted it because their own data showed most confident product ideas fail to improve the metrics they target. This lesson covers why observational product data misleads, what randomisation actually buys, the choice of randomisation unit, and the humbling base rates reported by the teams who measured.
7 steps·~11 min - AIintermediate
Feedback Loops: The Model Trains on Clicks It Caused
A deployed recommender chooses its own future training data: it shows items, users respond to what was shown, and those responses become the next model's ground truth. This lesson maps the loop's consequences, exposure bias, popularity compounding, narrowing candidate pools, explains why offline metrics reward imitation of the loop, and covers the exploration budget that keeps the system learning.
7 steps·~11 min - AIintermediate
Ranking and Objectives: What Should the Model Optimise?
The ranker is a prediction machine, and the hard question is what it should predict. Clicks are plentiful and poisonous, watch time bends toward length, likes are rare and unrepresentative. This lesson covers implicit feedback, the position bias baked into every training log, multi-objective ranking, and calibration.
7 steps·~11 min - AIintermediate
Two Towers: How Taste Becomes Geometry
Candidate generation's workhorse is the two-tower model: one network embeds users, another embeds items, and relevance becomes a dot product in shared space. This lesson traces the idea from collaborative filtering through matrix factorization to trained towers, why the towers must never mix features, and the cold-start problem geometry alone cannot solve.
7 steps·~11 min - AIintermediate
The Two-Stage Machine: Why No Model Ranks the Whole Catalogue
A recommender has milliseconds to pick ten items from millions, and no model good enough to rank them all is cheap enough to run on them all. The industry's answer is a funnel: cheap candidate generation cuts millions to hundreds, an expensive ranker orders those hundreds. This lesson builds that architecture, its latency arithmetic, and the multi-source retrieval layer real systems run.
7 steps·~11 min - Computer Scienceintermediate
Measuring Relevance: Judgments, NDCG, and the Click Trap
Search quality arguments end when there is a number, and begin again over whether the number is honest. This lesson builds offline evaluation from its atoms: a judgment set, precision and recall at k, MRR for known-item queries, and NDCG computed by hand for graded relevance. Then the online half: clicks, position bias, and why the top result gets clicked even when it is wrong.
7 steps·~11 min - Computer Scienceintermediate
Lexical Meets Vector: Hybrid Search and Rank Fusion
Vector search did not replace keyword search, because the two fail in opposite places: BM25 cannot see that laptop and notebook mean the same thing, and embeddings cannot see that SKU-4471-B is not approximately anything. This lesson maps the two failure surfaces, then builds the production answer: run both retrievers and fuse the rankings, with reciprocal rank fusion done by hand.
7 steps·~11 min - Computer Scienceintermediate
BM25: How Lexical Relevance Is Actually Computed
Matching finds candidates; scoring orders them, and the ordering is the product. This lesson builds BM25, the default ranking function of Lucene, Elasticsearch and OpenSearch, from its three ingredients: rare terms count more, repeated terms saturate, and long documents get discounted. With the formula, the two tuning knobs, and the saturation curve computed by hand.
7 steps·~11 min - Computer Scienceintermediate
The Inverted Index, and Why Analysis Decides Everything
Search does not scan documents; it looks up precomputed answers. This lesson builds the inverted index from first principles, then covers the pipeline that feeds it: tokenization, normalisation, stemming and synonyms, and why an analysis mistake made at index time cannot be fixed at query time. Includes the classic failure where a product SKU becomes unfindable.
7 steps·~11 min - Programmingintermediate
SLOs and Error Budgets: Turning Reliability Into a Number
How reliable should the service be? Wrong question: the right one is how much unreliability you can afford, spent deliberately. This lesson builds the SLI, SLO and error budget machinery from Google's SRE practice, does the arithmetic of nines, explains burn-rate alerting, and shows why 100 percent is the wrong target.
7 steps·~11 min - Programmingintermediate
Distributed Tracing and the Art of Throwing Data Away
Tracing every request through every service produces the most useful telemetry you have and more of it than anyone can afford. This lesson covers how context propagation actually stitches a trace together, the head versus tail sampling decision and why it determines which incidents you can debug, and the collector pipeline where all of it is enforced.
7 steps·~11 min - Programmingintermediate
Percentiles and Cardinality: The Two Numbers That Run Your Bill
Two pieces of arithmetic decide whether your telemetry is useful and affordable. Percentiles, because averages hide exactly the users who are suffering, and you cannot average a p99. Cardinality, because metric cost is not per event but per label combination, and one careless label can multiply your bill by the size of your user base. This lesson does both mechanisms by hand.
7 steps·~11 min - Programmingintermediate
Metrics, Logs, Traces: Three Signals, Three Cost Models
Observability is not a product you buy but a property your system has: can you explain a behaviour you did not predict? This lesson defines the three telemetry signals, what question each answers, why their costs grow along completely different axes, and why the difference between monitoring and observability is the difference between known and unknown failure modes.
8 steps·~12 min - Businessintermediate
Declines, 3-D Secure, and Chargebacks: The Failure Paths
Payments engineering is mostly failure engineering. This lesson covers the decline taxonomy and what a merchant may do about each kind, how strong customer authentication and 3-D Secure actually work including the exemptions with their 0.13 and 0.06 percent fraud thresholds, who eats a fraudulent transaction and when that liability shifts, and the chargeback machine from dispute to representment.
8 steps·~12 min - Businessintermediate
Interchange: The Fee Structure That Shapes the Industry
Every card fee argument eventually reaches interchange: the fee the merchant's side pays to the cardholder's bank on every transaction. This lesson decomposes the merchant discount rate, explains why rewards cards exist and who really funds them, covers the EU caps of 0.2 and 0.3 percent and their loopholes, and shows why the same purchase costs a merchant triple on a corporate card.
8 steps·~12 min

