This can significantly speed up certain search operations, as linear scan over all documents can be replaced with simple index lookup.
the right structure of the index object depends on a particular task and is wasteful for online processing of documents.