document data retrieval
segment utilities
Indexing logic implemented