Index Ai Academy
Phase 0 · Tools · Developer tools

Packages and environments

Install libraries with pip and keep projects isolated with venv.

About 25 minutes · Free lesson

Start this lesson

Why it matters

Nearly all AI work in Python runs on packages other people wrote: anthropic and openai for model APIs, numpy and pandas for data, torch and transformers for training models. The first lines of almost every AI project's setup install them. Knowing how packages and environments work turns "it doesn't work on my machine" from a mystery into a two-minute fix.

What you'll be able to do

  • Install a package from PyPI with pip and import it
  • Create, activate and leave a virtual environment
  • Read and use a requirements.txt file
  • Diagnose a ModuleNotFoundError

Before this lesson

Next in this phase: How APIs work