You could also add a field to your documents at index time that indicates how many geolocations there are. Then you could use that number in a function_score field value factor function, and you would not have to use scripting.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.