Building AI applications with Python
Put a language model inside a real program: structured output, tools, retrieval and evals.
About this track
You can write Python; now learn to build software on top of a language model. This track covers calling a model from code, forcing output into a schema your program can rely on, giving the model tools it can call, the agent loop, retrieval-augmented generation over your own documents, evaluating whether a change actually helped, and controlling cost and latency in production. It is deliberately opinionated about the failure modes, because the gap between a demo that works once and a system that works every day is where most AI projects die. Take Python data analysis first if you have never used pip or a virtual environment.
Every lesson is written and hosted here on Yanjye — you never leave the site. Work through them in order, then sit the exam to earn your certificate.
Create a free account or log in to track your progress and earn the certificate.
Lessons
-
1
From chat window to API call
What changes when the model is inside your program instead of a browser tab.
-
2
Your first program that calls a model
Client, request, blocks, usage — and reading the response properly.
-
3
Prompts in code: system design, not wording
Treating the prompt as a versioned, testable part of your program.
-
4
Getting JSON your program can rely on
Schema-constrained output instead of parsing prose and hoping.
-
5
Giving the model tools it can call
Function calling: how the model reaches your database, your API, the real world.
-
6
The agent loop, and how to keep it under control
Multi-step autonomy, budgets, stopping conditions and failure recovery.
-
7
Embeddings: turning meaning into numbers
Vectors, similarity, and why keyword search is not enough.
-
8
RAG: answering from your own documents
The architecture behind almost every serious AI product.
-
9
Making retrieval actually work
Chunking, hybrid search, reranking and query rewriting.
-
10
Evals: knowing whether a change helped
The discipline that separates engineering from prompt roulette.
-
11
Cost, latency and prompt caching
Making it fast and affordable without making it worse.
-
12
Shipping: the things that break in production
Secrets, retries, timeouts, abuse, monitoring and rollback.