Skip to content

wellAbebe/python-for-ai-course

Repository files navigation

Python for AI: From Basic to Advanced

A free, beginner-friendly, hands-on path from zero Python to building a real AI-powered project — the same 4-week curriculum used in a live mentored cohort, published here so anyone can follow it.

No prior coding experience needed. No paid tools required. By the end, you'll have written real Python, understood how AI APIs actually work under the hood, and shipped a small working AI chatbot of your own.

New here? Start at week-01-python-core-fundamentals/. Each week builds directly on the last — don't skip ahead.


Why this exists

Most "learn Python for AI" content on the internet is either a 40-hour university-style course, or a copy-paste "call this API" tutorial with no fundamentals underneath it. This is neither. It's built around one idea:

See it → understand it → build it. Every lesson starts by showing you the finished thing, then explains the concept behind it, then walks you through building it yourself, step by step.

It also takes a clear position on something a lot of people are anxious about right now: AI coding assistants are everywhere, so do fundamentals still matter? Yes — more than ever. An AI assistant can write code fast; it can't tell you whether that code is right, safe, or doing what you actually asked for. This course is about building that judgment, not just typing syntax.

Who this is for

  • Absolute beginners to programming (high school age and up)
  • Anyone who's dabbled in Python but never built anything real
  • Anyone who wants to understand LLM APIs (Gemini, OpenAI, etc.) from first principles instead of copy-pasting a tutorial

The 4-Week Path

Week Focus You'll walk away with
Week 1 Python Core Fundamentals A working CLI tool using functions, data structures, and error handling
Week 2 (coming soon) OOP & Data Handling The same tool, refactored into clean, class-based, multi-file code
Week 3 (coming soon) Packages, Debugging & APIs A script that calls a real API using a key and JSON
Week 4 (coming soon) AI Concepts, Project & Roadmap A working AI chatbot on the Gemini API, plus a roadmap for where to specialize next (web dev, ML, data science, or agentic AI)

How to use this repo

Each week is its own folder. Inside, each day has:

  • README.md — the lesson: what it is, why it matters, how it works, and a walkthrough
  • practice.py — a starter file with # TODOs for you to fill in
  • solution.py — a full reference solution, so you're never stuck

Work through the days in order. Don't peek at solution.py until you've genuinely tried practice.py first — that struggle is where the learning happens.

Setup (once, before Week 1 Day 1)

  1. Install Python 3.11+
  2. Install VS Code and its official Python extension
  3. Clone this repo:
    git clone https://github.com/<your-username>/python-for-ai-course.git
    cd python-for-ai-course/week-01-python-core-fundamentals/day-01-intro-setup
  4. Open the folder in VS Code and you're ready for Day 1.

License

Course content is released under the MIT License — use it, fork it, teach with it, just keep the attribution.


This repo is the companion material for a live mentored cohort. If you want the live version — structured sessions, code review, and a mentor answering your questions in real time — reach out to the instructor.

Releases

Packages

Contributors

Languages