Udemy
Turn what you know into an opportunity and reach millions around the world.
Learn More
Your cart is empty.
Keep shopping
AI Agents & RAG in Python: Document Chat and Research Agent
New
Rating: 5.0 out of 5(2 ratings)
4 students

AI Agents & RAG in Python: Document Chat and Research Agent

Build AI agents and RAG apps in Python: a content repurposer, a chat-with-your-documents app and a research agent
Created byAdi Tejus
Last updated 11/2026
English

What you'll learn

  • Build 3 LLM apps in Python: an AI Content Repurposer, a Chat With Your Own Documents RAG app and an autonomous Research Agent
  • Explain tokens, embeddings, context windows, temperature and hallucinations, and use them to predict an LLM app's cost and failures
  • Write production prompts with a 5-block formula, few-shot examples, self-critique and structured JSON output your code can parse
  • Build a 7-stage RAG pipeline with chunking, embeddings, vector search, re-ranking, page citations and "I don't know" refusals
  • Build an AI agent from the ReAct loop up, with function calling, permission boundaries, memory and a full reasoning trace
  • Defend an LLM app against prompt injection with guardrails, and log and monitor it without leaking personal data
  • Measure accuracy, latency and cost with an evaluation harness, then cut token spend with compression, model tiering and caching
  • Add streaming and caching, and deploy an AI app to a live URL with environment variables, secret handling and HTTPS

Course content

7 sections • 33 lectures • 3h 43m total length
  • 3 AI Apps You'll Build By the End of This Course2:42

    A quick tour of the three real projects you'll build: an AI Content Repurposer, a Chat-With-Your-Documents RAG app, and an Autonomous Research Agent. No theory  yet — just what's ahead and why it matters.

  • Setup in 5 Minutes: API Keys, Python & Your First Call4:13

    Get your Python environment, OpenAI API key, and first successful API call running in under five minutes. Everything you need for the rest of the course.

Requirements

  • Basic Python knowledge (functions, classes, pip) — no prior AI or machine learning experience required.
  • A computer with Python 3.10+ installed; any OS (Windows, macOS, or Linux) works.
  • An OpenAI (or other LLM provider) API key; low-cost usage is enough for all projects.
  • Familiarity with the command line and Git basics is helpful but not mandatory.

Description

This course contains the use of artificial intelligence.


You build three working LLM apps in Python: an AI Content Repurposer that turns one article into a summary, a LinkedIn post, five tweets, an email and a video script; a Chat With Your Own Documents RAG app with page citations; and an autonomous Research Agent that plans its own research, calls tools and logs its reasoning.

Then you measure them with a 20-case evaluation harness, cut token costs, add streaming and caching, and deploy an app to a live URL.


Why this course is different

  • Three projects, not slides: each part of the course ends in a project or an assignment you build yourself.

  • Numbers, not adjectives: one extra retrieval step takes accuracy from 61% to 89%, and the cost lecture shows before and after numbers for three techniques that cut token spend by 70%.

  • Security by doing: a live prompt injection demo that breaks the course's own assistant in one sentence, then the guardrails that stop it.

  • Straight advice: why most apps need RAG rather than fine-tuning, and when a multi-agent system costs more and answers worse.


What you will build and learn

  • LLM foundations for builders: tokens and pricing, embeddings, context windows, temperature and top-p, and why hallucinations happen.

  • Prompt engineering that ships: a 5-block prompt formula, role and few-shot prompting, step-by-step reasoning with self-critique, structured JSON output and prompt injection defences.

  • Project 1, AI Content Repurposer: a multi-stage pipeline with parallel generation and self-critique.

  • RAG from scratch: chunking that keeps meaning, vector databases and semantic search, and a 7-stage pipeline (load, chunk, embed, store, retrieve, re-rank, generate).

  • Project 2, Chat With Your Own Documents: PDF ingestion, hybrid retrieval, re-ranking, page citations, "I don't know" refusals and access control.

  • AI agents: the ReAct loop built from scratch, function calling with permission boundaries, three types of memory, and when multi-agent systems are worth it.

  • Project 3, Autonomous Research Agent: it plans its own research, calls APIs, recovers from failures, resists prompt injection and logs a full reasoning trace.

  • Production: an evaluation harness for accuracy, latency and cost; prompt compression, model tiering and caching; streaming; deployment to a live URL with secret handling and HTTPS; logging and monitoring that keeps personal data out of the logs.


Practice built in

  • 4 assignments: rewrite a fragile one-line prompt into a production prompt, fix a broken RAG system from 9/20 to 16/20 without changing the model, build a bounded agent that writes a company briefing, and take the RAG app from localhost to production-ready.

  • A 30-day practice plan (downloadable) for after the last lecture.


Who this course is for

  • Python developers who want to build RAG apps and AI agents that hold up beyond a demo.

  • Developers and analysts who already use ChatGPT or an LLM API and want to know why it fails and how to fix it.

  • Tech leads who need to judge the cost, accuracy and security of an LLM feature before it ships.


Scope, stated plainly

  • About 3 h 43 min of video in 7 sections and 33 lectures, plus 4 assignments.

  • You set up Python and an OpenAI API key in lecture 2, in about five minutes.

  • Model names and libraries will date; tokens, embeddings, retrieval quality and least privilege will not. The last lecture says which is which.

Who this course is for:

  • Python developers who want to move from ChatGPT prompting to building real, production-grade LLM applications.
  • Backend and full-stack engineers adding RAG, chatbots, or agent features to existing products.
  • Data scientists and ML engineers who want practical LLMOps skills: evaluation, deployment, and monitoring.
  • Students and career switchers who want portfolio-worthy AI projects rather than toy notebook demos.
  • Technical leads evaluating whether agents and RAG can solve their business problems, and how much they cost to run.