optimized entity indexing