Skip to content

AI, in Depth9 min read

The Best Free GitHub Repos to Learn How to Build AI Agents

Six free GitHub repos that teach AI agents with real code, checked on October 28, 2026 for license, activity and what each one actually contains.

By · Published · Updated

Updated 19 Nov 2026: Corrected the date of the last awesome-llm-apps commit before the October 28 check.

Key takeaways

  • Microsoft's AI Agents for Beginners is the most structured free start as of October 2026: 18 lessons with Python code, under the MIT license, with a Tagalog translation.
  • Hugging Face's free Agents Course covers smolagents, LlamaIndex and LangGraph in 4 units and ends with a benchmarked final project and an optional certificate.
  • Shubhamsaboo/awesome-llm-apps had about 143,000 GitHub stars on October 28, 2026, and its README lists 100+ agents, agent skills and RAG apps under Apache-2.0.
  • NirDiamant/GenAI_Agents is free to learn from, but its custom license allows non-commercial use only, so its code cannot go into a paid product without written permission.
  • The repos are free, but most examples call a paid model API, so budget for tokens or pick the examples that run local models.

The best free GitHub repos to learn how to build AI agents in 2026 are Microsoft’s AI Agents for Beginners and Hugging Face’s Agents Course for structured lessons, and awesome-llm-apps for working projects to copy. Anthropic’s Claude Cookbooks, NirDiamant’s GenAI_Agents and Arindam200’s awesome-ai-apps fill in agent patterns, notebooks and framework starters.

I build with agents myself, including a multi-agent Claude Code pipeline that audits a production codebase in under 6 minutes, so I wanted a shortlist I could hand to anyone starting out. This list is part of my writing on AI, in depth.

How did I choose these repos?

A good repo for learning agents has to teach with code you can run, not just links. I checked every repo on October 28, 2026 against six criteria:

  • Free: no paywall on the lessons or the code.
  • License: a license file you can read. GitHub’s licensing guide says that without one, default copyright applies and no one may reuse the work.
  • Active: a commit to the main branch in October 2026.
  • Hands-on: runnable scripts or notebooks, not only reading.
  • Maintainer: a company or a named person who answers for it.
  • Stars: a popularity signal only, never proof of quality.

The letterbox at GitHub's office in Amsterdam

All six repos are free on GitHub. This is the letterbox at GitHub’s Amsterdam office. Photo: Rrustema, CC0.

All six picks passed. One of them, GenAI_Agents, passes with a license caveat you should read before you reuse its code.

Which free GitHub repos teach you to build AI agents?

The six repos below are in the order I would suggest a beginner open them, with the same facts for each.

A programmer working at a laptop

Each repo teaches with real code you can run and change. Photo: Crew, CC0.

1. microsoft/ai-agents-for-beginners

  • What it is: microsoft/ai-agents-for-beginners is Microsoft’s free course of 18 lessons on building AI agents.
  • Who it’s for: beginners who want a set order, from what an agent is to deploying and securing one.
  • What’s inside: a written lesson and Python code for each topic, plus short videos for the first 13. Topics include tool use, agentic RAG, planning, multi-agent design, MCP and A2A protocols, context engineering, memory and computer use. It has 50+ translations, including Tagalog.
  • License: MIT.
  • Stars and last update: about 78,000 stars and a commit on October 27, 2026.
  • Caution: the code uses the Microsoft Agent Framework and Foundry, and the README says an Azure account is required. Some samples accept other OpenAI-compatible providers.

Microsoft’s own video for lesson 1 explains what an AI agent is before any code:

What are AI agents?, a video by Microsoft Developer
Video: What are AI agents? by Microsoft Developer, on YouTube.

2. huggingface/agents-course

  • What it is: huggingface/agents-course is the source repo of Hugging Face’s free Agents Course, which you take on hf.co/learn.
  • Who it’s for: learners who want to compare frameworks and finish with a graded project.
  • What’s inside: 4 units plus bonus units. They cover what agents are, the smolagents, LlamaIndex and LangGraph frameworks, agentic RAG, and a final project scored on a benchmark with a leaderboard. A bonus unit teaches fine-tuning a model for function calling.
  • License: Apache-2.0.
  • Stars and last update: about 34,000 stars and a commit to main on October 6, 2026.
  • Caution: the repo holds the course source, so the lessons read better on the course site. The listed prerequisites are basic Python and basic knowledge of LLMs.

3. Shubhamsaboo/awesome-llm-apps

  • What it is: Shubhamsaboo/awesome-llm-apps is a collection of open-source agent projects. Its README lists 100+ AI agents, agent skills and RAG apps.
  • Who it’s for: builders who learn faster from a finished app than from a lesson.
  • What’s inside: single-file starter agents that run with an API key, multi-agent teams, voice agents, MCP agents, always-on agents and RAG tutorials. Some, like the Local RAG Agent with Llama 3.2, need no API key. Its agent skills install into coding agents such as Claude Code.
  • License: Apache-2.0. The README says you can “clone it, ship it, sell it.”
  • Stars and last update: about 143,000 stars, the most on this list, and a commit on October 27, 2026.
  • Caution: the README calls the apps tested end-to-end. That is the maintainer’s claim, and each app brings its own dependencies and keys.

Shubham Saboo, who maintains the repo, shared it on Threads in June 2025. The post counted 75+ tutorials then, and the README lists 100+ as of October 28, 2026:

Shubham Saboo@saboo_shubham_

This GitHub repo literally contains 75+ AI tutorials on AI Agents, MCP, RAG, Voice Agents, and Multi-agent teams.

Step-by-step AI tutorials with complete code examples.

100% free and Opensource.

𝐒𝐭𝐚𝐫𝐭𝐞𝐫 𝐀𝐈 𝐀𝐠𝐞𝐧𝐭𝐬

🎙️ AI Blog to Podcast Agent

❤️‍🩹 AI Breakup Recovery Agent

📊 AI Data Analysis Agent

🩻 AI Medical Imaging Agent

😂 AI Meme Generator Agent (Browser)

🎵 AI Music Generator Agent

🛫 AI Travel Agent (Local & Cloud)

✨ Gemini Multimodal Agent

Post by Shubham Saboo (@saboo_shubham_) on Threads, 12 Jun 2025

4. anthropics/claude-cookbooks

  • What it is: anthropics/claude-cookbooks is Anthropic’s official set of notebooks and code for building with Claude.
  • Who it’s for: developers building on the Claude API who want the patterns behind agents, not a framework.
  • What’s inside: the patterns/agents folder implements prompt chaining, routing, parallelization, orchestrator-workers and evaluator-optimizer workflows. The claude_agent_sdk folder has 9 recipes, from a one-line research agent to multi-agent systems and hosting an agent.
  • License: MIT.
  • Stars and last update: about 54,000 stars and a commit on October 24, 2026.
  • Caution: you need a Claude API key, and API calls are billed per token. The Agent SDK recipes assume you already know Claude Code. If token costs are new to you, start with what tokenization is and why it decides what AI costs.

5. NirDiamant/GenAI_Agents

  • What it is: NirDiamant/GenAI_Agents is a collection of Jupyter notebook tutorials, from simple chatbots to multi-agent systems. Its README counts 57 tutorials.
  • Who it’s for: learners who like one notebook per idea, with the reasoning written out.
  • What’s inside: beginner agents, an introduction to LangGraph and an MCP tutorial. There are also business agents such as customer support and contract analysis, and a notebook that builds the smallest agent loop from scratch. Most use LangGraph.
  • License: custom. GitHub shows NOASSERTION because it cannot match the license text to a standard one. It allows use, changes and sharing for non-commercial purposes only, with credit and a link to the repo. Commercial use needs the author’s written permission.
  • Stars and last update: about 24,700 stars and a commit on October 27, 2026.
  • Caution: fine for learning, not for client work. The README also promotes the author’s book and newsletter.

6. Arindam200/awesome-ai-apps

  • What it is: Arindam200/awesome-ai-apps is a collection of agent and RAG projects. Its README counts 132 projects.
  • Who it’s for: builders choosing a framework, because it has a starter for almost every one.
  • What’s inside: 21 starter agents across frameworks such as CrewAI, Google ADK, LangGraph, Mastra, the OpenAI Agents SDK, PydanticAI and smolagents. It also has sections for voice, MCP, memory, RAG, advanced agents and fine-tuning.
  • License: MIT.
  • Stars and last update: about 16,600 stars and a commit on October 9, 2026.
  • Caution: the project has sponsors, and many starters are wired to sponsor services such as Nebius Token Factory. Swapping in your own model provider may take edits.

Arindam Majumder, who maintains the repo, shared it on Threads in July 2025. The post counted 30+ tutorials then, and the README counts 132 projects as of October 28, 2026:

Arindam Majumder 🇮🇳@arindam_1729m

This GitHub repo has 30+ tutorials to help you build real AI Agents!

I update Awesome AI Apps every week with fresh examples. It has:

- Starter agent templates

- Complex agentic workflows

- MCP-powered agents

- RAG demos

- Multiple agentic frameworks

100% free & open-source

Post by Arindam Majumder 🇮🇳 (@arindam_1729m) on Threads, 24 Jul 2025

How do the repos compare?

The six repos split into two courses, one official cookbook and three project collections.

RepoBest forLicenseStars (Oct 28, 2026)Last commit
microsoft/ai-agents-for-beginnersA structured first courseMITabout 78,000Oct 27, 2026
huggingface/agents-courseComparing frameworks, a certificateApache-2.0about 34,000Oct 6, 2026
Shubhamsaboo/awesome-llm-appsFinished apps to copyApache-2.0about 143,000Oct 27, 2026
anthropics/claude-cookbooksAgent patterns on the Claude APIMITabout 54,000Oct 24, 2026
NirDiamant/GenAI_AgentsNotebook tutorials, non-commercialCustom, non-commercialabout 24,700Oct 27, 2026
Arindam200/awesome-ai-appsA starter for each frameworkMITabout 16,600Oct 9, 2026

Stars track attention, not teaching quality, so pick by the “best for” column.

Which one should you start with?

The right first repo depends on how you learn and what you plan to build.

Students studying together at a table with books

Start with the repo that matches how you like to learn. Photo: Narek75, CC BY-SA 4.0.

  • You are new to agents: start with Microsoft’s AI Agents for Beginners. It has a clear order, and each lesson stands alone if you want to skip ahead.
  • You want proof you finished: take the Hugging Face Agents Course for its final project and certificate.
  • You learn by copying a working app: open awesome-llm-apps, pick one starter agent, and get it running before you read anything else.
  • You build on Claude: go to the patterns/agents notebooks in the Claude Cookbooks, then the Agent SDK recipes.
  • You are choosing a framework: run two or three starters from awesome-ai-apps side by side.

A course plus one collection is enough. Finish one agent end to end before you open a second repo. Once your first agent works, my roundup of the best AI agent tools shared on Threads in October 2026 covers newer tools like Executor and agent-browser for giving an agent tools and a browser.

How do you run agent code from GitHub safely?

Agent code from GitHub deserves more care than a normal script, because an agent can call tools, browse and run code with your keys. Read the README and the requirements file before you install anything.

  • Keys: put API keys in a .env file that stays out of git, and set a spending limit on every provider account.
  • Tools: give a new agent read-only tools first. Let it write files, send messages or spend money only after you have watched it work.
  • Skills and MCP servers: read a skill’s instructions and scripts, or an MCP server’s code, before you install it, since both run with your access.
  • Licenses: check the license before code goes into client work, as with GenAI_Agents.

Even frontier models can take actions nobody asked for, as I covered in Anthropic’s report on Claude’s unsanctioned actions. Start small, and widen an agent’s permissions one step at a time.

Where can you learn more?

Questions people ask

Do I need to pay anything to learn AI agents from these repos?

The repos and courses are free, but most examples call a model API that bills per token, such as Claude, OpenAI or Azure. Microsoft's course needs an Azure account for its main samples. To spend nothing, pick examples that run local models, such as the local RAG agents in awesome-llm-apps.

Can I use code from these repos in a client project?

Code under MIT or Apache-2.0, which covers five of the six repos, allows commercial use if you keep the copyright and license notices. NirDiamant/GenAI_Agents is the exception: its custom license reserves all commercial use for the author, so ask for written permission first.

Do I need to know Python before starting?

Yes, basic Python helps with all six. Hugging Face lists basic Python and basic knowledge of LLMs as its only prerequisites, and nearly every example in these repos is a Python script or Jupyter notebook.

Share

Keep reading

More in AI, in Depth.

Get new posts by email

One email every two weeks: new posts, news takes and one personal note, so you keep up with AI, automation and SEO without checking the site.

No spam. Unsubscribe any time. By subscribing you agree to the privacy policy.

Prefer a feed? Follow by RSS. About the newsletter.

Want AI working in your business? Book a free 15-minute call →

No obligation. I read and answer every message myself.

It’s Showtime, folks! · All That Jazz (1979)