Maps folks, I would like to start a discussion on the best way to search in a map. Daniel Schwen's WikiMiniAtlas has a similar algorithm, but we might need to expand or rethink it for a more general use case. We have an Elastic Search cluster, which has some geo-search capability, but that might not be enough for all of our use cases. Any feedback would be very helpful.

Please suggest use-cases and comments at
https://www.mediawiki.org/wiki/Maps/Search

== GOAL ==
Given a bounding box, get a set of entities with geo coordinates, such that:

Satisfy some arbitrary search request, e.g.
* Search among Wikipedia articles
* Show "everything" (all Wikipedia articles in a given language)
* All Wikipedia articles with some Wikidata category / type / some other conditions?

Clumping vs spread-out
* Results should not collapse onto each other in one place of the map, while the rest of the map is empty. They should spread out so that only the most relevant/important items should are shown for each location of the map.  Yet, if the ranking of the found items in one part of the map are significantly lower than the other, the result would also look weird. Imagine searching for the "monuments" within the whole world, and see the Status of Liberty in New York and some local commemorative plaque in some tiny village in a low population area. All results should be in the same "ranking class" - a range of values that do not differ too much from each other.

== Target Audience ==
* Showing maps in articles for "similar articles"
* Showing maps in Andoid/iPhone apps
* Wikidata info
* Commons pictures