Entity searching, search refactoring