changed indexing to create sets of ids per attribute value, started conversion of entity & entity_check