We're sorry but this app doesn't work properly without JavaScript enabled. Please enable it to continue.

Build an AI Agent in Python

Build a tiny coding agent that can read files, edit code, run Python, and loop on feedback.

What will you learn?

Write a toy agentic code editor in Python, similar to Claude Code or Cursor's Agent Mode. Understand how agents work from scratch by using the Google Gemini API to create an LLM-powered code agent. You'll use function calling and feedback loops to build an agent that can find and fix bugs in a real project!

Chapter List

1
LLMs
Learn how LLMs work and send prompts to the Gemini API using the Python client library
2
Functions
Write the functions your AI agent will need to modify files and run Python code
3
Function Calling
Give your AI agent the ability to call functions based on its system prompt and context window
4
Agents
Give your tool a proper feedback loop to make it truly "agentic" and fix a real bug

Join 15,456 students in the Build an AI Agent in Python course

Read reviews of their learning experiences

it would be nice if there was a ascii picture of where each file should be for reference

(3/5)
Dimitrije Barbul profile image

Dimitrije Barbul

Serbia

OK - creating something that fixes what you've written, is quite impressive

(4/5)
James Halliday profile image

James Halliday

United Kingdom

It's not for everyone. Skipping this one is totally fine!

(2/5)
Some Cat profile image

Some Cat

Russia

So far, in my opinion, this has been the worst course. The explanations are much worse than in the previous ones. The Google documentation page also currently does not seem to be working. In terms of difficulty, it is many times harder than everything before it. In the previous courses, I often felt that things were too easy or too slow, but here I often could not make any progress at all. That is also why, for the first time, I used AI to get the solution, and I did that several times. It woul

(1/5)
Alex S profile image

Alex S

Germany

Some parts of it were a bit abstract but the tests and checks are forgiving. A well-balanced course.

(4/5)
Oğuz Kabasakal profile image

Oğuz Kabasakal

Germany

N/A

(4/5)
Nack  profile image

Nack

United States

Great course, but a tough lesson.

(5/5)
Mike Davidson profile image

Mike Davidson

Flat Rock, USA

Very very interesting course. It give you a taste in how to build agents in Python. It's an occasion to practice Python too.

(5/5)
Massimo  profile image

Massimo

Italy

Good course that holds your hand through learning how to build ai agent

(5/5)
Max Kelly profile image

Max Kelly

Nashville

Showing 1-9 of 571

or view more reviews

Mediocrity doesn't cut it anymore

The only way to become a great developer is to write a lot of code

Avoid tutorial hell

by writing a ton of code

Stay motivated with

a game-like curriculum

Build portfolio projects

to prove your skills

Delve deeper

into foundational concepts

Learn flexibly online

without interrupting your life

For 1% the price of college

to minimize your financial risk

Frequently asked Questions

Got questions? We've got answers

Yes! It's free to create an account and start learning. You'll get all the immersive and interactive features for free for a few chapters. After that, if you still haven't paid for a membership, you'll be in read-only (content only) mode.