What is PageIndex and how does it work?
mainPageIndex is a vectorless, reasoning-based RAG (Retrieval-Augmented Generation) system designed for long, complex professional documents (e.g., legal, financial, technical).
Unlike traditional RAG that relies on vector similarity search and artificial text chunking, PageIndex uses a two-step process that mimics human expert navigation:
- Tree Index Generation: It transforms a document into a hierarchical tree structure index (similar to a semantic Table of Contents).
- Reasoning-based Retrieval: It uses LLMs to perform agentic tree search over that index. This allows the model to reason its way to relevant sections based on context, rather than just finding semantically similar text fragments.
Key Advantages:
- No Vector DB: Uses document structure and reasoning instead of vector similarity.
- No Chunking: Organizes documents into natural, semantic sections.
- Traceability: Results are grounded in explicit page and section references.
- Context-Aware: Retrieval can incorporate conversation history and domain knowledge.