Local Retrieval Augmented Generation (RAG) from Scratch (step by step tutorial) Daniel Bourke Kho Tổng Hợp 225,897 2 năm trước Add Nghe mp3 Facebook Tweet XEM MÔ TẢ In this video we'll build a Retrieval Augmented Generation (RAG) pipeline to run locally from scratch. There are frameworks to do this such as LangChain and LlamaIndex, however, building from scratch means that you'll know all the parts of the puzzle. Specifically, we'll build NutriChat, a RAG pipeline that allows someone to ask questions of a 1200 page Nutrition Textbook PDF. Code on GitHub - https://github.com/mrdbourke/simple-local-rag Whiteboard - https://whimsical.com/simple-local-rag-workflow-39kToR3yNf7E8kY4sS2tjV Be sure to check out NVIDIA GTC, NVIDIA's GPU Technology Conference running from March 18-21. It's free to attend virtually! That's what I'm doing. Sign up to GTC24 here: https://nvda.ws/3GUZygQ Other links: Download Nutrify (take a photo of food and learn about it) - https://nutrify.app Learn AI/ML (beginner-friendly course) - https://dbourke.link/ZTMMLcourse Learn TensorFlow - https://dbourke.link/ZTMTFcourse Learn PyTorch - https://dbourke.link/ZTMPyTorch AI/ML courses/books I recommend - https://www.mrdbourke.com/ml-resources/ Read my novel Charlie Walks - https://www.charliewalks.com Connect elsewhere: Web - https://dbourke.link/web Twitter - https://www.twitter.com/mrdbourke Twitch - https://www.twitch.tv/mrdbourke ArXiv channel (past streams) - https://dbourke.link/archive-channel Get email updates on my work - https://dbourke.link/newsletter Timestamps: 0:00 - Intro/NVIDIA GTC 2:25 - Part 0: Resources and overview 8:33 - Part 1: What is RAG? Why RAG? Why locally? 12:26 - Why RAG? 19:31 - What can RAG be used for? 26:08 - Why run locally? 30:26 - Part 2: What we're going to build 40:40 - Original Retrieval Augmented Generation paper 46:04 - Part 3: Importing and processing a PDF document 48:29 - Code starts! Importing a PDF and making it readable 1:17:09 - Part 4: Preprocessing our text into chunks (text splitting) 1:28:27 - Chunking our sentences together 1:56:38 - Part 5: Embedding creation 1:58:15 - Incredible embeddings resource by Vicky Boykis 1:58:49 - Open-source embedding models 2:00:00 - Creating our embedding model 2:09:02 - Creating embeddings on CPU vs GPU 2:25:14 - Part 6: Retrieval (semantic search) 2:36:57 - Troubleshooting np.fromstring (live!) 2:41:41 - Creating a small semantic search pipeline 2:56:25 - Showcasing the speed of vector search on GPUs 3:20:02 - Part 7: Similarity measures between embedding vectors explained 3:35:58 - Part 8: Functionizing our semantic search pipeline (retrieval) 3:46:49 - Part 9: Getting a Large Langue Model (LLM) to run locally 3:47:51 - Which LLM should I use? 4:03:18 - Loading a LLM locally 4:30:48 - Part 10: Generating text with our local LLM 4:49:09 - Part 11: Augmenting our prompt with context items 5:16:04 - Part 12: Functionizing our text generation step (putting it all together) 5:33:57 - Summary and potential extensions 5:36:00 - Leave a comment if there's any other videos you'd like to see! #ai #rag #GTC24 Video liên quan 1:31:57 NHẠC SỐNG BOLERO REMIX 2018 - LK NHẠC SỐNG HÀ TÂY TRỮ TÌNH NGẪU HỨNG TEST LOA - GIỌNG CA NGÔ NAM Kim Lam dung 1,038,058 view 7 năm trước Add 2:28 [HYBE x Geffen] Dream Academy - Mission 1 Pink Venom (Team A, Dance) HYBE LABELS 6,670,623 view 2 năm trước Add 18:40 Kinh nghiệm du lịch tự túc Malaysia Cherry Sharer 11,530 view 2 năm trước Add 1:51:43 Original DJ-Sly- Belle Jazz KOMPAS et Gouyad (Best of 2023 Kompas x Gouyad Mix) Ft Kai, Vayb, Oswald Original DJ-Sly 4,248 view 2 năm trước Add 50:42 High altitude danger: Inside Peru’s deadliest mountain Ici et ailleurs, voyages 94,052 view 16 ngày trước Add 25:56 From Syria to Germany - Nour’s dream to become a doctor | DW Documentary DW Documentary 16,443 view 16 ngày trước Add 18:26 CHẢ GIÒ TRIỀU CHÂU, Cải ná xào bò, Sườn kinh đô: THƠM NGON, ĂN VỚI CƠM THIỆT ĐÃ - Quận 11 Sài Gòn Tung Thanh Ly Vietnam 17,281 view 8 tháng trước Add 10:26 Nguyễn Ngọc Ngạn - Quýt làm Cam chịu của người phúc ta - Paris By Night 82 Nguyễn Ngọc Ngạn 1,176,608 view 5 năm trước Add 0:20 How Your Body Reacts During Midnight Scrolling. #animation #health Dr. Healthcare 487,499 view 7 tháng trước Add 29:05 Cách Làm Lợn Quay Lạng Sơn Hành Trình Đi Tìm Quy Trình Quay Lợn Chuẩn Lạng Sơn I Thai Lạng Sơn Thai Lạng Sơn 3,096,857 view 6 năm trước Add 0:49 Đ/c Nguyễn Duy Ngọc nhận bàn giao chức vụ Trưởng ban Tổ chức Trung ương từ Thủ Tướng Lê Minh Hưng Tình yêu từ Việt Nam 85,039 view 12 ngày trước Add 3:11 Infinite (2021) - The Mansion Assault Scene | Movieclips Movieclips 509,313 view 3 năm trước Add 2:04 Shoreline Mafia - Perc Popper [Official Audio] Shoreline Mafia 14,055,945 view 5 năm trước Add 4:46 12-14 triệu mua iPhone, Samsung hay Xiaomi dùng lâu dài 4 năm, dễ thay linh kiện? Vinh Xô 43,190 view 1 năm trước Add 26:30 LIÊN KHÚC DISCO HOT - CHUỐC RƯỢU CUỘC TÌNH - MỸ NHUNG - NHẠC TÌNH SONG CA CNS MỸ NHUNG 8,721 view 8 tháng trước Add 7:58 Nhiều trường Đại học Việt Nam bỏ xét tuyển học bạ, thế giới có như vậy? | VTV4 VTV4 3,024 view 5 tháng trước Add 8:19 MRU Library Welcome Back & Tour MRU Library 506 view 4 năm trước Add 57:18 Lệ Nam Nhi - Liên Khúc Nhạc Đời Danh Tuấn Trung Được Nghe Nhiều Nhất 2024 Danh Tuấn Trung Official 23,872 view 2 năm trước Add 3:31 Frozen 2 | Cast Sing Some Things Never Change Behind The Scenes Rehearsal (Full version) Tiogi Doblajes 1,767,059 view 4 năm trước Add 0:19 After Effects vs Davinci Resolve - Motion Graphics #shorts Arane Editor 78,753 view 8 tháng trước Add