35% Off Finance Skills That Get You Hired - Code CFI35
AI Adoption - Drive Business Value and Organizational Impact
Overview
Coursera Flash Sale
40% Off Coursera Plus for 3 Months!
Grab it
Learn to implement advanced RAG chunking techniques that preserve document structure and context using LangChain and Ollama in this 14-minute tutorial. Discover why simple character-based splitting destroys RAG performance by severing tables, breaking sentences, and creating contextless "orphan chunks." Move beyond RecursiveCharacterTextSplitter by implementing a sophisticated two-pass strategy that combines Markdown Header Splitting with LLM-based Contextual Enrichment. Build a chunking pipeline that respects document structure while using a local LLM to inject global context into every chunk. Explore the chunk dataclass and metadata structure, examine the resulting enriched chunks, and understand the trade-offs including token inflation considerations. Master these advanced techniques to significantly improve your RAG system's performance while maintaining complete local control over your data processing pipeline.
Syllabus
- The problem with naive chunking
- Chunking pipeline overview
- Chunk dataclass & metadata structure
- Chunking and enrichment with Ollama
- Looking at the resulting chunks
- Token inflation & trade-offs
Taught by
Venelin Valkov