Discrepancy between address levels and tag labels? #2568
Replies: 2 comments 2 replies
-
I think you misunderstand the purpose of the rank assignment. Search and address ranks are fixed Nominatim-internal concepts. The meaning of the numbers is explained in the documentation The choice of numbers were indeed initially derived from
Nominatim does not support customized labels at the moment. |
Beta Was this translation helpful? Give feedback.
-
Let me try to explain it better:
Thanks for helping me navigate this. I'm pretty sure I'm missing something obvious as I'm new to the project, but I don't yet see what exactly. Is my expectation above wrong? |
Beta Was this translation helpful? Give feedback.
-
Customizing address levels is possible with the
address-levels.json
config file.However, when those levels are used to determine the label tag for output, it looks like Nominatim just divides by 2 and uses that to determine the administrative level again.
This doesn't always play well together.
For example, if I state in my
address-levels.json
file that"administrative8": 18
I clearly want 18 to represent lvl 8. But when I query Nominatim, it will divide by 2 for some (undocumented) reason.The
getBoundaryLabel()
hard-codes the map between levels and labels:So my 18 now becomes 9 which is "City District" and not 8 as I specified in the config file. I guess for a newcomer to the project, this is a little confusing. My intention was to have complete control of which address tags are used, and ideally the label of the tags. If not directly the labels themselves, then at least how they map between address levels to labels. I hope that makes sense!
I suggest:
Thanks for reading this far and sorry if I'm missing something obvious.
Beta Was this translation helpful? Give feedback.
All reactions