CS230 Lecture 2 @ Stanford (AI column)
I told you before that I started this course and looked at it. lecture Andrew Ng. Then it's time. lectureled by Kian Katanforoosh, co-author of this course, CEO and founder of Workera (platform for assessing AI skills)Co-founder of deeplearning.ai. The lecture looked like a "recap about supervised" after learning Coursera lecturesBut in fact, this is an analysis of engineering levers in AI projects: task statement → data / markup → architecture → loss → exploitation of embeddings. The main points are approximately the following:
1Supervised ML solution is a regular product service Model = Architecture + Weights (two-artifact)around which piplins, metrics and deploy revolve.
- Change the task. (binary → multi‑label) - changing the contract of labels, loss and metrics. It's not "added classes to the dataset." Capacity: the size of the model should correspond to complexity + variety of data + compute/latency. Otherwise, you will get a beautiful dev and pain in real traffic. Embeddings – when distances in space make sense. It is the foundation of search, recommendation, retrieval/RAG and “reused views.”
2Three cases where everything is decided by data and setting
- Definition of day/night by picture: first scope (One camera or the whole world? indoor/outdoor? sunrise/sunset/polar day?) Then we collect data. Permission is selected through a human experiment: we print / show people different quality and look for the lower limit of informativeness. Typical compromise: ~64×64×3 + a little CNN.
- Working with a trigger word like "Alexa" / "Alice" / "Siri", here we suggest "activate": a classic cascade pattern (cheap): VAD/activity → trigger → ASR/intent In order not to mark up endless audio with your hands, make synthetic data + programmatic labeling: positives (“activate”), hard negatives ("deactivate" and similar), background noise; script mixes everything into 10Sec clips and generates time stamps. Often, the win does not give “more data”, but the correct markup scheme for time.
- Face verification: "comparing pixels" and "classifying each person" don't scale. Solution - face embeddings + triplet loss (A,P is closer than A,N + margin). Then one embedding layer closes three products at once:
- verification: distance < threshold
- identification: nearest neighbor
- clustering: k‑means/agglo
3How to scale without expensive labels
- Self‑supervised: contrastive (SimCLR style) Two augmentations of one object should be closer, the rest further; and next-token prediction (GPT) - the data labels itself. Weak supervision: using natural pairs of modalities (image↔️text, video↔️audio, subtitles↔️video). Hence CLIP/ImageBind-approaches and unified multimodal embedding-spaces.
What can be learned for the DL/ML project Start the project with setting + distribution + edge cases, not with choosing a model. Review your ML models as code: labels contract + loss + metrics (and their relationship to the business cost of mistakes). Do quick human tests before spending GPU weeks. Optimize iteration speed: A slightly smaller model/resolution often leads to the correct system faster. Build architecture around embedding-API: “learn the concept once → solve N problems.” Look for unlabeled threads and weak connections in the domain (Logical actions, text ия️telemetry) It is a fuel for self/weak supervision.
#Software #ML #AI #Engineering #Architecture