Phase 0 · Tools · Python core
Modules and imports
Use Python's standard library instead of reinventing it.
Why it matters
Nobody writes AI software from scratch. The top of every AI script is a list of imports: json to read API replies, requests to call APIs, numpy for the math, the Anthropic SDK to talk to models. Knowing how imports work, and what Python's standard library already does, means you reuse proven code instead of rewriting it, and you can read the first ten lines of any project and know what it depends on.
What you'll be able to do
- Import a module, or specific names from it, and use what it provides
- Use the standard library for math, randomness, dates, statistics and counting
- Explain what a module is and where Python looks for one
- Avoid the import mistakes that confuse beginners
Before this lesson
Next in this phase: Classes and objects