I'm not a search expert. I wouldn't be able to do anything fancy without ElasticSearch. So the idea of handling a search query that includes places is daunting. How do FamilySearch and Ancestry handle places in their record search queries?
When starting a new search at Ancestry they prompt you to select a normalized place.
If you select a normalized value then on the results page you get an advanced place filter with options of matching Broad, Country, State and adjacent states, State, County and adjacent counties, County, and Exact.
When set to Broad there are 1,103,301,743 results.
When set to State there are 444,576,313 results.
When set to Exact there are 1,751,043 results.
Clearly that filter is working. And it's fast too.
Are all events in records normalized and inserted into a geospatial index? Is there any string matching of places going on?
If I don't select a normalized value when searching then I don't get the fancy place filter. I just get the options of Broad and Exact. When searching for "Amsterdam, Montomgery, NY" I get 669,259,292 Broad matches and 1,751,043 Exact matches. I'm not sure why the broad matches are different but the exact matches are the same as above. It seems they are attempting to normalize the input query even when the user doesn't selecting a normalized value.
I remember hearing once that FamilySearch normalizes place values on the fly when answering search queries. Is it true? I don't understand how that could possibly be true unless they're referring solely to the user input.
How would you design a search system that matches against millions of records? Is it possible to do without normalizing the places in the records?