Overview of the LocalGPT Indexing Pipeline
mainThe Indexing Pipeline transforms raw documents (such as PDF or TXT files) into search-ready chunks. The process involves converting files to text, chunking the text using various strategies, optionally enriching chunks with contextual summaries, generating embeddings, and finally storing the vectors in LanceDB. It also generates auxiliary assets like overviews in JSONL format for triage routing.
flowchart TD
A["Uploaded Files"] --> B{Converter}
B -->|PDF→text| C["Plain Text"]
C --> D{Chunker}
D -->|docling| D1[DocLing Chunking]
D -->|latechunk| D2[Late Chunking]
D -->|standard| D3[Fixed-size]
D1 & D2 & D3 --> E["Contextual Enricher"]
E -->|local ctx summary| F["Embedding Generator"]
F -->|vectors| G[(LanceDB Table)]
E --> H["Overview Builder"]
H -->|JSONL| OVR[[`index_store/overviews/<idx>.jsonl`]]