The working language of AI products: call model APIs, handle JSON, async calls and errors.
Starting with Syntax, variables and types, Functions, Lists, dicts, sets and tuples, Virtual environments, pip and uv, Errors and exceptions, Calling model APIs, Async and batching, Pydantic models, and more
Made for you now: slide lessons from basics to production, usually with code and a quiz. See a finished one
The working language of AI products: call model APIs, handle JSON, async calls and errors.
AI EngineeringStage 1 of 17: Python and APIs for AI
Start with these 8. 20 more are one tap away.
Numbers, strings, booleans and None, and how Python treats each one.
Package steps into reusable pieces with arguments, defaults and return values.
The four containers you use to hold prompts, results and records.
Keep each project’s packages apart so one install cannot break another.
Catch failures from networks and models, and raise clear errors of your own.
Send a prompt, read the reply, and handle streaming, retries and timeouts.
Run many model calls at once without blocking.
Validate data at the edges and turn model JSON into typed objects.