Skip to content

About

Hands-on journey through agentic AI, from LLM basics to production multi-agent systems. LangChain, LangGraph, MCP, RAG, guardrails, evals and deployment, built from scratch and measured.

Resources

Stars

3 stars

Watchers

0 watching

Forks

Latest commit

Β 

History

36 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ€– Agentic AI β€” Built, Run, Verified

A 22-module path from "what even is an agent?" to a deployed multi-agent system.

Python LangGraph LangChain uv Groq License

Built Planned Every script runs


πŸ‘‹ Read this first

Nothing here is a tutorial you watch. Every module is code that has actually been executed against live APIs, with the real output recorded. When something didn't work, the failure is written down too β€” those failure notes are the most useful part of the repo.

If you are a complete beginner: that's fine. This README tells you exactly where to start and what to ignore. Jump to 🎯 Where to start.


🎯 Where to start

πŸ‘‰ Start at Module 4 β€” LangGraph Fundamentals πŸ‘ˆ

Not Module 1. Here's the honest reasoning:

Module What it is What to do
0️⃣ Python Core Basics (optional) Variables, loops, functions, classes, imports πŸ“– Only if you're new to Python. Already comfortable? Skip straight to 1.
1️⃣ Foundations Concepts only, no code πŸ“– Skim for 20 min. Good vocabulary, nothing to run.
2️⃣ Python Essentials async + Pydantic βœ… Check, don't study. Can you read async def / await, and class X(BaseModel)? If yes, move on. You'll need it from Module 7.
3️⃣ LangChain Agents The old way of building agents πŸ‘€ Skim only. This is the approach LangGraph replaced. Useful as contrast, not as a foundation.
4️⃣ LangGraph Fundamentals State, nodes, edges πŸš€ START HERE. Verified working code + beginner notes. Everything after this is built on it.

Why Module 4 maximises what you already know: you know Python functions and dictionaries. That is genuinely all Module 4 is β€” a function that takes a dict and returns a dict, plus wiring that says which function runs next. No new mental model required on day one.

πŸ—“οΈ Your first three days

Day 1  β†’  Module 4, files 01–02    State, nodes, edges + your first LLM node
Day 2  β†’  Module 4, files 03–06    Chaining, parallel + reducers, routing, loops
Day 3  β†’  Module 6                 Memory β€” the one that makes it feel like ChatGPT

Right now, in your terminal:

cd "Module 4 - LangGraph Fundamentals/project"
uv sync          # required: venvs were cleared to reclaim disk
uv run python 01_temperature.py

Look at the output before you open the file. Then read LEARNPLAN.md β€” it's the method that turns this code into understanding instead of a folder you own.


🧭 The four phases

β”Œβ”€ 🟒 PHASE 1 Β· FOUNDATIONS ────────────────────────────────┐
β”‚  M1 concepts   M2 python   M3 old-style agents            β”‚  skim
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              ↓
β”Œβ”€ πŸ”΅ PHASE 2 Β· THE CORE  ⭐ most important ────────────────┐
β”‚  M4 state/nodes/edges  β†’  M5 routing & loops              β”‚
β”‚  M6 memory & threads   β†’  M7 tools  β†’  M8 RAG + approval  β”‚  ← learn properly
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              ↓
β”Œβ”€ 🟣 PHASE 3 Β· SHIPPING ───────────────────────────────────┐
β”‚  M9 Docker/FastAPI  M10 capstone  M11 multi-agent         β”‚
β”‚  M12 MCP  M13 subgraphs  M14 guardrails                   β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                              ↓
β”Œβ”€ 🟠 PHASE 4 Β· PRODUCTION CRAFT ───────────────────────────┐
β”‚  M15 harness  M16 evals  M17 gateway                      β”‚
β”‚  M18/20/22 advanced RAG   M19 serverless   M21 case study β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

πŸ’‘ If you only ever do four modules: 4 β†’ 6 β†’ 7 β†’ 8. State, memory, tools, retrieval. Almost everything else in this field is a variation on those four, and Module 10 is literally those four stacked together.


πŸ“š Module index

βšͺ Phase 0 β€” Absolute Beginners (optional, skip if you already know Python)

# Module You learn Status
0 Python Core Basics Variables, types, collections, control flow, functions, a minimal class, imports βœ… built

🟒 Phase 1 β€” Foundations (skim)

# Module You learn Status
1 Agentic AI Foundations LLM β†’ RAG β†’ agents β†’ multi-agent; the ReAct loop πŸ“– + NOTES
2 Python Essentials asyncio, concurrent calls, validated output πŸ““ + NOTES
3 Agents with LangChain Tool calling, single + multi-agent (LangChain 1.x) βœ… verified

πŸ”΅ Phase 2 β€” The Core ⭐

# Module You learn Status
4 LangGraph Fundamentals State, nodes, edges, reducers βœ… 6 files
5 Workflow Patterns Send fan-out, Command routing, capped loops βœ… 5 files
6 Chatbot: Memory & Streaming Checkpointers, thread_id, time travel, SQLite βœ… 5 files
7 Observability & Tools ToolNode, tools_condition, context trimming βœ… 4 files
8 RAG & Human-in-the-Loop PDF β†’ FAISS, interrupt() + resume βœ… 6 files

🟣 Phase 3 β€” Shipping

# Module You learn Status
9 Deployment FastAPI streaming, Docker (image verified), CI βœ… built
10 Capstone: ChatGPT Agent All of Phase 2 + Streamlit UI, 4 tools Β· ARCHITECTURE βœ… built
11 TripMate AI Supervisor + 3 specialists, Command(goto=) βœ… built
12 MCP One tool server, many clients, async, stdio βœ… built
13 Subgraphs: AgentWriter Reusable subgraph + revision loop βœ… built
14 Guardrails + Supervisor 4 middleware layers, 5/5 adversarial eval βœ… built

🟠 Phase 4 β€” Production Craft (15–19 and 21 built; 20 and 22 need Pinecone / Neo4j credentials)

# Module You learn Status
15 Harness & Loop Engineering Audit 8 rows, fix the weakest in code βœ… built
16 Agent Evaluation 31 evals, 5 dimensions, LLM-as-judge, CI gate βœ… built
17 LLM Gateway Groq + DeepSeek + Gemini, verified fallback βœ… built
18 Advanced RAG I CRAG + Self-RAG, compared side by side βœ… built
19 Self-Correcting App Writer/reviewer loop, container verified βœ… built
20 Advanced RAG II Routing RAG on hosted Pinecone πŸ“‹ plan
21 Forward Deployed Eng FDE case study with real before/after βœ… built
22 Advanced RAG III Neo4j GraphRAG + charts/images πŸ“‹ plan

🧰 One-time setup

1. Install uv (replaces pip/venv, much faster):

curl -LsSf https://astral.sh/uv/install.sh | sh

2. Get free API keys:

Key Where Needed by
GROQ_API_KEY console.groq.com πŸ”΄ 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 16, 18, 19 β€” free tier
TAVILY_API_KEY tavily.com 3, 7, 10, 11, 13, 18 β€” free tier
LANGSMITH_API_KEY smith.langchain.com 6, 10 β€” optional, tracing only
OPENWEATHER_API_KEY openweathermap.org 11 β€” optional, degrades to search
PINECONE_API_KEY pinecone.io 20 (not built)
NEO4J_URI/_USERNAME/_PASSWORD neo4j.com/aura 22 (not built)

Copy .env.example into each module folder as .env and fill in only what that module needs. Embeddings need no key β€” Modules 8/10/18 use local MiniLM.

πŸ’° Cost: Groq's free tier runs everything here. If you'd rather use OpenAI, a full pass of every module is about $0.09 on gpt-4o-mini (252 counted model calls) β€” so the usual $5 minimum top-up is far more than enough. Details and caveats in VERIFICATION.md Β§4.

3. Run any module β€” each is its own self-contained project:

cd "Module 4 - LangGraph Fundamentals/project"
uv sync                              # installs exactly the pinned versions
uv run python 01_temperature.py

Put your keys in a .env inside the module folder. .env is gitignored everywhere β€” never commit it.

⚠️ If a module builds its model client at import, importing it needs a key. That's fine when you run the module β€” you have a .env. It is not fine for the free CI job, which runs with no secrets at all: it made tests.yml fail at Module 18 before a single assertion. Module 18 now builds both clients on first use (self_rag.llm(), kb.embeddings()), so the pure-logic tests import cleanly. Reproduce CI before trusting it: env -u GROQ_API_KEY uv run python test_caps.py.

⚠️ Folder names use -, never : β€” a colon makes uv run fail outright and makes source .venv/bin/activate silently do nothing (you stay on system Python and get baffling import errors). See AGENT_RULES.md #5.


πŸ“– The two docs that matter

Doc Read it when
πŸŽ“ LEARNPLAN.md Now. How to actually learn this: the run β†’ break β†’ predict loop, how to read a NOTES.md, realistic pacing, break-it experiments per module, an error decoder.
πŸ› οΈ AGENT_RULES.md When building Modules 17–22. Pinned stack + every pitfall already hit. Paste it with a module's README when asking a coding agent to build it.
🧠 MEMORY.md Starting a fresh chat? Paste this + AGENT_RULES.md and an agent can continue without re-reading the repo: module status, the pitfall list, remaining work prioritised, and the exact checklist for when an OpenAI key arrives.
βœ… VERIFICATION.md Proof it runs. Real captured output from every built module, what is honestly not verified, the full key matrix, and what it costs (~$0.09 a full pass). Regenerate with ./verify.sh.
πŸ”„ OpenAI.md If you have an OpenAI key. Switching provider is one env var; it also removes the json_mode workaround and the parallel-tool-call limitation. Includes cost warnings and an honest verification table.
πŸ—‚οΈ topics.md + learning_prompt.md Want a chatbot to teach you the theory, not just the code. Paste learning_prompt.md then topics.md into any chatbot for a one-topic-at-a-time walkthrough, prerequisites checked first.

Every built module also has a NOTES.md written for a beginner β€” what each file does, why, and a "Gotchas we hit" section at the end. Read the gotchas twice: once now, once when you're stuck.


πŸ”— Relationship to the original course

This repo follows entbappy/Complete-Agentic-AI-Course β€” the official repo for the course. I scanned it and compared structure directly. The overall idea matches. Same concepts, same order, same projects:

Original repo β†’ Here
Langchain vs LangGraph β†’ M1
Asynchronous Programming + Pydantic-Validation β†’ M2
Langchain-Single-Agent + LangChain-Multi-Agent-Research-System β†’ M3
LangGraph-Code/1,2,3,5,7,8_*.ipynb β†’ M4 (near-exact 1:1 β€” temperature, QA, chaining, essay, review, iterative)
LangGraph-Code/4,6_*.ipynb + workflow patterns β†’ M5
9_Persistence.ipynb + Agentic-Chatbot/*_db_* β†’ M6
Agentic-Chatbot/*_tool_* + tools_demo.ipynb β†’ M7
10_HITL.ipynb + *_rag_* β†’ M8
Agentic-Chatbot-using-LangGraph/ (full app) β†’ M9 + M10
11_subgraphs + 12_subgraph_shared β†’ M13 (the original shows both patterns β€” M13's notes explain why to prefer the explicit one)
13_guardrails_crash_course.ipynb β†’ M14
AI_Agent_Evaluation.ipynb β†’ M16
llm_gateway.ipynb β†’ M17
Corrective-Rag-CRAG + Self-Rag-Code β†’ M18
Advanced-RAG/Agentic-RAG β†’ M20
Agentic AI Interview Preparation/ β†’ M21
Advanced-RAG/Graph-RAG + Multimodal-RAG β†’ M22

What's different, and why:

  • πŸ“‚ 22 small modules instead of 12 topic folders. Same material, finer-grained, so one module = one sitting.
  • 🐍 .py scripts instead of .ipynb notebooks. Runnable with one command, diffable in git, and they fail loudly instead of hiding stale state in cell outputs.
  • πŸ“¦ uv + pinned versions instead of requirements.txt. Reproducible β€” the reason this code still runs.
  • βž• Four modules with no counterpart in the original: M9 (Deployment), M11 (TripMate), M12 (MCP), M15 (Harness), M19 (Serverless). These come from the extended course brief.
  • πŸ” Secrets are gitignored here. The original has 18 committed artifacts, including 4 .env files, plus chatbot.db, __pycache__/ and faiss_db/. Don't copy that pattern β€” rotate any key you ever push.

⚠️ About "the old code is rotten"

Your diagnosis is correct, and it's the main reason this repo re-implements rather than copies. The concepts in the original are sound; the code bit-rots because the ecosystem moves fast. Concretely, what broke while building Modules 4–14:

πŸ’€ What rotted What it does now Fix used here
llama-3.3-70b-versatile 404 β€” decommissioned openai/gpt-oss-120b
mixtral-8x7b-32768 410 β€” decommissioned same
with_structured_output(Model) errors: "Tool choice is required, but model did not call a tool" method="json_mode" + field names in the prompt
langchain_community.tools.tavily_search deprecated langchain-tavily
init_chat_model("groq:llama-...") dead model behind a live API live model list, checked
langchain-community prints a sunset warning still correct for FAISS/PyPDF β€” no official replacement yet

The lesson, not the complaint: never trust a hardcoded model name in any tutorial, including this one. Check what's actually live:

curl https://api.groq.com/openai/v1/models -H "Authorization: Bearer $GROQ_API_KEY"

All of this is collected in AGENT_RULES.md so you hit each gotcha once, not twice.


πŸ†˜ Stuck?

  1. πŸ” Check "Gotchas we hit" at the bottom of that module's NOTES.md.
  2. πŸ“‹ Check the error table in LEARNPLAN.md β€” InvalidUpdateError, GraphRecursionError, dead models and friends are all decoded there.
  3. πŸ” Run it again. Code bugs fail identically every time; model weirdness varies. That one distinction saves hours.
  4. πŸ‘‡ Read the last line of the traceback first, not the first.

πŸ™ Credits

Concepts and projects in this repo are based on Boktiar Ahmed Bappy's Agentic AI course, which explains all of this material.


πŸš€ Stop reading. Go run the first file.

cd "Module 4 - LangGraph Fundamentals/project" && uv run python 01_temperature.py

Then break it on purpose. That's the part that teaches.

About

Hands-on journey through agentic AI, from LLM basics to production multi-agent systems. LangChain, LangGraph, MCP, RAG, guardrails, evals and deployment, built from scratch and measured.

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages