Py
Py
Run
What do you want to learn?
Lessons
⌄
Browse the curriculum
Find your level
Practice problems
Interview prep
Cheat sheets
Career paths
Explore by role
All lessons
Fundamentals
Web development
Data
Engineering
Data science
Machine learning
GenAI & RAG
Automation
DSA / interview
Tools
new
⌄
Online compiler
Playground
Revise
Terminal
SQL playground
Notebook
Build
⌄
Workspaces
Guided projects
My published sites
Blog
Pricing
AI
en
Sign in
Start free
→
Start free
→
loading…
Feedback
💬
Ask PyRun
Home
›
All lessons
›
GenAI & RAG
›
Chunking Documents for Retrieval
Chunking Documents for Retrieval
Advanced
13 min
GenAI & RAG
genai · chunking · rag · strings
Try it
↓
Lesson
3
of
6
In this track
▾
1
Text Embeddings & Cosine Similarity
14 min
2
Building a Tiny Vector Store
15 min
3
Chunking Documents for Retrieval
13 min
4
Assembling a RAG Pipeline
18 min
5
Prompt Engineering in Python
14 min
6
Evaluating Retrieval: Precision & Recall @ k
15 min
←
→
Loading lesson…
←
Previous lesson
Building a Tiny Vector Store
Advanced · 15 min
Next lesson
→
Assembling a RAG Pipeline
Advanced · 18 min
Related lessons
Advanced · 18 min
Assembling a RAG Pipeline
Wire embeddings, retrieval and prompt-building into one flow, then see exactly where the LLM call slots in.
Advanced · 14 min
Text Embeddings & Cosine Similarity
Turn text into a numeric vector, then measure how close two pieces of text are with cosine similarity.
Advanced · 15 min
Evaluating Retrieval: Precision & Recall @ k
Measure how good your retriever is with precision@k and recall@k, given the ids it returned versus the ids that are actually relevant.