EDIT: Thank you for all the method to do a research. I’ll try them all when I’ll have a bit of time.
When I move in a new place, I always look for a map of libraries and for the closest public bookcases.
According to wikipedia
A public bookcase (also known as a free library or book swap or street library or sidewalk library) is a cabinet which may be freely and anonymously used for the exchange and storage of books without the administrative rigor associated with formal libraries. When in public places these cabinets are of a robust and weatherproof design which are available at all times. However, cabinets installed in public or commercial buildings may be simple, unmodified book-shelves and may only be available during certain periods.
At my current place I couldn’t find a map of bookcases and I didn’t find one walking around my home. Fortunately there is OSM and the very helpful site www.boites-a-livres.fr. The site maps out every french public bookcase using OSM and gives very clear information about how to find them on OSM, even for beginner user like me.
In OSM, public bookcases are represented by a amenity key and a public_bookcase value. They can be either node or area element.
However, if I search for “public_bookcase” in openstreetmap.org search bar, I don’t get the result I want. How can define in my research keys and values?
Thank you for your help.
AFAICT, the search feature on openstreetmap.org is meant to be used with human-readable expressions, i.e. “public bookcase” with a space, not underscore.
But I just tested it with various queries for “public bookcase near [city]” and they all gave me plenty of results, both with and without an underscore. Apparently searching for “public_bookcase” with an underscore by itself (without a city) only gives results that are named something like “public bookcase” (which should almost never happen, but that’s a different question).
Ultimately the search feature on openstreetmap.org is unfortunately somewhat limited and if you want more sophisticated ways of searching the database, there are plenty of options available.
The searchbox on osm.org is actually not even part of osm, it’s a separate project called Nominatim:
The main goal of the Nominatim is geocoding by name and addresses, and it doesn’t search in all osm parameters, just in names and addresses, so it can find only public bookcases which are named “public bookcase”. But naming a bookcase “public bookcase” is against the tagging rules on osm, as such common descriptions shouldn’t be added to the
name
tag: https://wiki.openstreetmap.org/wiki/Names#Name_is_the_name_onlySo that searchbox there is wrong recommendation, it will find only mistagged bookcases.
Most of what you write is right, but not the part where you write it searches only in names and addresses, it does have some support for POIs. If I search for public bookcase near paris, the top three results are https://www.openstreetmap.org/node/12387870803 https://www.openstreetmap.org/node/9569806762 https://www.openstreetmap.org/node/11733421968 none of which have anything like “public bookcase” in their names, they are tagged amenity=public_bookcase though.
Wow, adding “near Paris” changes the results, but without it it only finds nodes with
name
=public bookcase
Yes, that’s what I wrote in my first comment in this thread. It seems it recognizes “near” as a keyword to look up things in a map from POI descriptions to tags. I’m sure it’s open source, so we could simply look there, but I don’t know where that exact logic is located.
@schnurrito @infeeeee Nominatim recognises some “special phrases” with words like “near” and “in”. This allows just a little bit of “natural language” searching for POIs.
There is some info on the OSM wiki at this link. Within that, the “current language” pages tell you which phrases are recognised per language. You can see that the English language page has several mappings related to public bookcases.
https://wiki.openstreetmap.org/wiki/Nominatim/Special_Phrases