Autoplay
Autocomplete
Previous Lesson
Complete and Continue
AI Engineering: RAG (Retrieval Augmented Generation) for LLMs
Section 1: Introduction to Retrieval Augmented Generation (RAG) Systems
Course Outline (3:10)
Exercise: Meet Your Classmates and Instructor
Meet Rubber Ducky! Your AI Course Assistant using RAG (6:04)
Link to Your AI Course Assistant
Understanding Your Video Player
[ACTION] Download the Course Resources
Set Your Learning Streak Goal
PART A: BASICS OF PROMPT ENGINEERING, PYTHON AND OPENAI API
Who Is This Part For? (2:15)
Section 2: Prompt Engineering Basics
Game Plan for Prompt Engineering Basics (4:30)
Setting Up the OpenAI API (3:03)
Few-Shot Prompting (3:10)
Few-Shot in Practice (9:53)
Role, Persona and Goal (4:58)
Role, Persona and Goal in Practice (4:45)
System Message (5:04)
System Message in Practice (6:01)
My Favourite Prompt (4:02)
Section 3: Understanding LLMs Part 1
Understanding Transformers (12:47)
Attention Mechanisms (6:14)
Section 4: Python for RAG and GenAI
Game Plan for Python for RAG and GenAI (1:34)
Loops (5:18)
Loops: Easy Level (8:31)
Loops: Medium Level - Part 1 (3:45)
Loops: Medium Level - Part 2 (3:55)
Loops: Hard Level (2:56)
Functions (4:43)
Functions: Easy Level - Part 1 (4:06)
Functions: Easy Level - Part 2 (1:30)
Functions: Medium Level - Part 1 (2:49)
Functions: Medium Level - Part 2 (3:07)
Functions: Hard Level (7:01)
Introduction to Classes (4:51)
Classes: Easy Level - Part 1 (10:29)
Classes: Easy Level - Part 2 (3:52)
Classes: Medium Level (8:42)
Section 5: Understanding LLMs Part 2
OpenAI Tokenizer (6:12)
Section 6: OpenAI API
Overview: Working with the OpenAI API (3:47)
OpenAI API for Text (4:52)
Setting Up OpenAI API Key (5:08)
OpenAI API (5:02)
Generating Text with OpenAI API (6:37)
OpenAI API Parameters (6:55)
OpenAI API for Images (4:51)
With Image URL (9:19)
With Image in Base64 (10:08)
Adding Few-Shot Prompting (6:26)
What Did You Learn in this Section? (3:50)
Section 7: Understanding LLMs Part 3
Playing the Dice, Rock, Paper, Scissors, and Guess the Number (8:11)
Section 8: CAPSTONE PROJECT: Deploy With Lovable
Claim Your Free Credits
Project Presentation: Build a LinkedIn Post Writer App (2:57)
UI Design via Image Generation (7:45)
Lovable Build Prompt (5:29)
Deploy on Lovable (11:50)
Course Check-In
PART B - RAG
What to Expect of Part B (4:32)
Section 9 - RAG with OpenAI File Search
OpenAI File Search (2:04)
Project Presentation: Build a Mini Rubber Ducky (3:43)
Vector Stores (4:05)
Setup (1:57)
Retrieving the Files Path (6:54)
File and Vector Stores in OpenAI (9:52)
Responses Endpoint with File Search (9:32)
Section 10 - Deploy RAG with Streamlit
Setting Up on Cursor and Requirements (5:35)
Building Your AI Web App (2:35)
Virtual Environment and .env File (8:43)
Configuring the Page (10:14)
Session State and Vector Store (8:06)
Start Building the App: Sidebar (5:43)
Building the App: Chat Inputs (5:06)
Building the App: Bot Common Kwargs (9:59)
Building the App: Bot Answers (9:36)
Building the App: System Instructions (5:57)
GitHub Repository (6:26)
Deploying to Streamlit (3:02)
Section 11: Working With Unstructured Data
Overview: Working With Unstructured Data (3:36)
Introduction to Langchain Library (7:26)
Excel Data: Best Practices for Data Handling (6:41)
Initial Setup for Data Processing (10:46)
Loading Data (6:36)
Developing a Retrieval System for Unstructured Data (6:55)
Building a Generation System for Dynamic Content (3:38)
Building Retrieval and Generation Functions (9:04)
Working with Word Documents (4:54)
Setting Up Word Documents for RAG (11:48)
Working with PowerPoint Presentations (4:44)
PowerPoint Setup for RAG (5:32)
Working with EPUB Files (4:58)
EPUB Setup for RAG (4:15)
Working with PDF Files (4:21)
PDF Setup for RAG (9:55)
What Did You Learn in This Section? (3:56)
Exercise: Imposter Syndrome (2:55)
Section 12: Multimodal RAG
Overview: Multimodal RAG (3:38)
Introduction to Multimodal RAG (5:58)
Setup and Video Processing (5:23)
Extracting Audio from Video (8:44)
Compressing Audio Files (4:17)
Transcribing Audio with OpenAI Whisper (10:07)
Whisper Model (6:31)
Extracting Frames from Video (5:49)
Introduction to Contrastive Learning (5:14)
Understanding the CLIP Model (5:22)
Tokenizing Text for Multimodal Tasks (8:13)
Chunking and Embedding Text (11:36)
Embedding Images for Multimodal Analysis (8:36)
Understanding Cosine Similarity in Multimodal Contexts (6:46)
Applying Contrastive Learning and Cosine Similarity (10:26)
Visualizing Text and Image Embeddings (11:11)
Query Embedding Techniques (4:12)
Calculating Cosine Similarity for Query and Text (11:47)
GenAI Model Setup for Multimodal Tasks (4:55)
Building a GenAI Model (7:11)
What Did You Learn in This Section? (2:12)
Section 13: Project - Starbucks Financial Data
Project Briefing: Starbucks Financial Data (5:27)
Transcribing Audio with OpenAI Whisper (11:22)
Embedding Transcription with CLIP (7:35)
Converting PDF to Images (5:57)
Embedding Images for Multimodal Analysis (4:58)
Retrieval System (17:13)
Preparing Context (4:59)
Generative System (12:46)
Section 14: Knowledge Graphs with LightRAG
Game Plan for Knowledge Graphs with LightRAG (2:19)
Knowledge Graphs (7:19)
Knowledge Graphs vs Embeddings (8:49)
LightRAG Setup (5:55)
What is LightRAG? (4:40)
Setting the Working Directory (5:49)
Local RAG (8:40)
Knowledge Graph Visualization (12:16)
Global and Hybrid RAG (7:12)
Naive, Mix and Bypass RAG (3:35)
Section 15: Agentic RAG
Overview: Agentic RAG (2:51)
AI Agents (7:51)
Agentic RAG (5:44)
Setup, Data Loading and AgentState (6:49)
State Management and Memory in Agentic Systems (7:54)
Greeting The Customer (8:04)
AI Agent that Checks the Question (7:03)
AI Agent that Assesses the Validity of the Question (7:17)
AI Agent that Generates the Answer (12:19)
AI Agent that Improves the Answer (5:32)
Asking User for More Questions (11:21)
Testing and Improving Agentic RAG (5:41)
Agentic RAG Recap - Key Learnings and Next Steps (6:17)
Section 16: Deploy Agentic RAG with Vercel
Preparing the Prompt with ChatGPT or Gemini (18:14)
Game Plan for Deploying Agentic RAG (1:03)
UX Mock Ups with Stich (3:05)
Setting Up with Cursor (2:58)
Testing the App Locally (21:23)
Final Debugging (4:12)
Push to Github (4:41)
Deploying to Vercel (1:48)
Testing the App (4:10)
Section 17: RAGAS
Game Plan for RAGAS (1:53)
Assessing RAG with RAGAS (6:13)
RAGAS Setup (7:44)
RAG (5:23)
Synthetic Data (3:36)
Generating Synthetic Data (7:02)
Answering Synthetic Dataset (5:13)
ROUGE (Recall-Oriented Understudy for Gisting Evaluation) Score (5:32)
ROUGE (13:49)
LLM-Based Assessment (6:07)
Simple Criteria Score - Part 1 (5:35)
Simple Criteria Score - Part 2 (5:39)
Factual Correctness (5:16)
Rubrics Score (4:52)
Semantic Similarity (4:46)
Factual Correctness (4:57)
Context Precision (3:12)
Semantic Similarity (6:21)
Context Recall (3:11)
Context Precision (5:57)
Response Relevancy (4:36)
Context Recall (4:55)
Response Relevancy (6:22)
Key Learnings and Outcomes: RAGAS (3:17)
Where To Go From Here?
Thank You! (1:17)
Review This Course!
Become An Alumni
Learning Guideline
ZTM Events Every Month
LinkedIn Endorsements
Preparing the Prompt with ChatGPT or Gemini
This lecture is available exclusively for ZTM Academy members.
If you're already a member,
you'll need to login
.
Join ZTM To Unlock All Lectures