How to Improve LLMs with RAG (Overview + Python Code)

Опубликовано: 18 Февраль 2026
на канале: Shaw Talebi
144,230
4k

🤝 Work with me: https://www.shawhintalebi.com
🚀 Ship AI apps in weeks, not months: https://aibuilder.academy/

In this video, I give a beginner-friendly introduction to retrieval augmented generation (RAG) and show how to use it to improve a fine-tuned model from a previous video in this LLM series.

▶️ Series Playlist:    • Large Language Models (LLMs)  
🎥 Fine-tuning with QLoRA:    • QLoRA—How to Fine-tune an LLM on a Single ...  

📰 Read more: https://medium.com/towards-data-scien...
💻 Colab: https://colab.research.google.com/dri...
💻 GitHub: https://github.com/ShawhinT/YouTube-B...
🤗 Model: https://huggingface.co/shawhin/shawgp...

References
[1] https://github.com/openai/openai-cook...
[2]    • LlamaIndex Webinar: Building LLM Apps for ...  
[3] https://docs.llamaindex.ai/en/stable/...
[4]    • LlamaIndex Webinar: Make RAG Production-Ready  

Intro - 0:00
Background - 0:53
2 Limitations - 1:45
What is RAG? - 2:51
How RAG works - 5:03
Text Embeddings + Retrieval - 5:35
Creating Knowledge Base - 7:37
Example Code: Improving YouTube Comment Responder with RAG - 9:34
What's next? - 20:58