Every named OSM object in each country's Geofabrik extract goes into a SQLite FTS5 index (data/places/<CODE>.sqlite, lib/maptool/places.rb), built as the last offline-build step or on its own with rake places:index. Kiwix full-text search is another source; clicking a hit opens the article. Results from every source are sorted by distance from the map center (settlements weighted closer) and show it; each source is queried separately so a slow one doesn't hold up the list.