index and search prototype.