User:Nadjita/Routes
Routes revised | |
---|---|
Proposal status: | Draft (under way) |
Proposed by: | Nadjita |
Tagging: | segment=*, stage=*, stage:name=*, stage:name=*, label=* |
Applies to: | |
Definition: | This proposal adds attributes to routes and recommends rules that will allow searching for them in Nominatim and other data consumers |
Rendered as: | hidden |
Draft started: | 2023-06-26 |
Applies to
This proposal only applies to the following route types: route=hiking, route=foot, route=bicycle.
All network:type=node_network routes are explicitly excluded
Proposal
The aim is to enable the searchability of routes' names and references by Nominatim without losing any important information. To accomplish this, we need to be more strict about what is allowed in these two tags. Any values that this proposal would make invalid in the routes' names and refs will be moved to other tags that are more user-friendly for data consumers. To achieve this, the proposal introduces several new tags, formalizes the already existing stage=* tag, and advocates for implementing stricter rules.
The route's name and ref should align with the official and signed name and ref of the route. They should not include tags like to=*, from=*, stage=*, stage:name=*, stage:description=*, nor description=*, segment=*, or solely rely on a "widely used" ref or name. Furthermore, there is a recommendation to use short_name=* to handle route names containing problematic characters.
The introduction of the new label=* tag might be seen debatable by some, but it seems to be the best compromise to allow searching for ref=* without inventing something like symbol:ref
or similar. I truly believe that the benefits of having a general label are worth the effort.
Rationale
Nominatim currently doesn't want to search for route names and refs, because the naming uses all kinds of different characters that would never be found, plus many route names and refs are not official but made up. I want to give mappers the tags they need to move some things that are commonly mapped in a route's name and ref into machine-readable attributes and convince Nominatim to search for routes by name and ref.
Analysing hundreds of routes, I noticed these common error patterns with route names:
- Routes that don't have a name, are being given a name, assuming it won't be displayed otherwise. In the past, some editors would also not display relations without a name, so people gave names to routes, just to be able to find them.
- JOSM has the following order for displaying relations: name, ref, description
- iD has the following order for displaying relations: name, ref, from/to
- Routes were given refs, even if there was no officially signed reference. This was done, so maps would display the route with this ref, instead of a horribly long name. There were several discussions, whether refs should only contain official refs, or not, and since there was no consensus, both exist now. As of right now, it's impossible to know if the ref of a route appears on the signs or not.
- Routes have attributes in their name that aren't actually part of the name:
- Ergänzungsroute (Supplementary route)
- Alternativroute (Alternative route)
- Abkürzung (Shortcut)
- (Maryland)
- Some routes have been cut into stages, all stages are then in a superroute. Usually, these stages are "day 1, stage 1", and so on. These stages are also visible in the name of the invididual routes.
- Some routes are known by multiple names, but people put both names into the name=*-tag, instead of adding an alt_name=*.
- A lot of routes use characters that Nominatim will have issues finding:
-
–
▶
→
<>
->
:
;
()
Tagging
The route should be described with as many tags as needed. The goal is to keep only the real name of a route in name=*, the real ref of the route in ref=*, and every descriptive bit moved to other, better fitting tags.
General rules
Rule | Definition |
---|---|
1. Don't invent names | Don't give the route a name if it doesn't have one. Don't mix ref=* with name=*, they are not the same! Make sure to use the proper ref=*, set from=* and to=* and add a description=* to the route to explain what the purpose is. It's perfectly fine for a route not to have a name. In the case of no visible name on the signs, please set noname=yes |
2. Don't invent refs | Don't set a ref=* that's not present on the route's signs/markers/icons. The name of a route is not the reference code! Use label=* to help data consumers find a short representation of the route's name if there is no ref=* on the signs. It's perfectly fine for a route not to have a ref. In the case of no visible reference code on the signs, please set noref=yes |
3. Keep the name clean | Don't put anything in a route's name that's not part of it. to=*, from=*, stage=*, stage:description=*, and stage:name=* don't belong into a route's name. |
4. Use segments | Superroutes should use the following route segments as role for their route members: main , alternative , excursion , approach , and connection . Members without role must be considered main . There can be multiple routes for each role.
Every route that is not the main route or part thereof, must set a segment=*. |
5. Special chars | Every route containing non-alphabetic letters in the name should have a short_name=* that is a representation without these |
6. Use stages | Every route that's been cut into several stages must use the stage=*-key and/or from=*/to=* to describe the stage – not make it part of the name. Use stage=* when it's cut into logical stages (day 1, 2, 3, by state/country), otherwise only to=* and from=*. Use stage:name=* if the individual stages have names (Grand Départ, Königsetappe, Isle of Man, …) |
7. Names for segments | Every route that is part of a superroute and not the main route (or a stage thereof) must not have a name, unless explicitly signed. Proper use of description=*, from=* and to=* is advised. |
8. Superroute tags mimick the main route's | Superroutes must use the main route's name=*, network=* and ref=* tags, including leaving them empty, if the main route doesn't set them. |
9. role vs. segment | A route can be a full route by itself, while having a different role in another superroute. The segment=* of the route remains empty, or "main", while the role in the superroute is applied accordingly. This is common for hiking routes that are a connection to the Camino de Santiago, but a full hiking route by itself (e.g. "Via Scandinavica" or "Pilgerweg Loccum - Volkenroda") |
New tag segment=*
The new tag segment=* is used to indicate the role of a route within a super-route, without requiring data-consumers to have knowledge of super-routes. Renderers are encouraged to visually differentiate non-main segments by using different styles such as dotted, dashed, or thinner lines. The permitted values for segment=* are the same as those for the role
in recreational routes. Keep in mind that a route can have different roles in different relations. In this case, if one role is main
, use this as a segment=*, otherwise use the most important one.
- segment=main
- This route is a main route or a part thereof
- segment=alternative
- This route is an alternative route, or a shortcut, that connects one node from the main route with another one. Make sure to add from=* and to=* as well as a description=*.
- segment=excursion
- This is a supplementary route that is not part of the main route. It usually leads to attractions that are too off-route to be on the main route, or have a different difficulty (more steep, special equipment needed, etc.)
- segment=approach
- This is a signposted way leading to the route itself, usually from a parking space, a train station, etc. Only put these into a separate route if it's a rather long approach. Otherwise, you can just add these ways to the main route with the role=approach instead.
- segment=connection
- This is a connection between 2 or more routes. Typically, it belongs to all connected routes, so putting this into its own route can save some work, because you will only have to add the connection-route to the superroutes, and not all of the connection's ways to the routes. Only map these connections, if they are explicitly signed - everything else is for the router to figure out.
Tag stage=*
This is not a new tag, but I wish to formally define it here. stage=* defines that a route is just a part of a route that has been cut into several stages and the value signalizes which stage we're in. Typically, these are one stage per day, sometimes also one stage per state, sometimes one stage per country, or one for the morning and one for the afternoon. This key only takes a numerical value that is optionally followed by a letter. If there are no official stages for a route, it is up to the mapper to decide whether and where to split. Common sense advised. When splitting on geographic criteria, consider using from=* and to=* instead of, or in addition to stage=*. The fact that this can lead to subjective stages is not necessarily bad, and especially if the mapper has local knowledge, can be a big advantage.
Wrong: stage=Day 1
Correct: stage=1
Correct: stage=1a
If you have multiple routes covering the same stage, either give them all the same stage=*-value, or add a
, b
, c
, and so on.
An example is a large route through the Netherlands that's been cut into 8 days (stages), but some of the stages have alternative routes. It's advised to tag the main route with stage=1, and the alternative routes either with stage=1, or stage=1a, and so on.
Data consumers can use the leading number for sorting, but must ignore anything starting with the first non-digit.
Caveat: If a route is a part of a superroute that contains two or more equally significant "main" routes (meaning they have equal importance, with no one route being more significant than the others), exercise caution when utilizing the stage=* tag. To ensure correct numbering, the two variants must be divided into an equal number of stages. An example of this is the "E2 European long distance path", which has two alternative midsections.
New tag stage:name=*
Use this if the stage of your route has an official name that is not part of the route's name. Some stages have separate, official names like "Mountain stage", "The big approach", and so on. Use this tag for these official names, not for something you made up yourself or "Day 7". This tag is meant to be searchable by Nominatim, and for being displayed by editor software, to make it easier to find the correct stage.
New tag stage:description=*
Use this if the stage of your route has no official name, and you need to describe it. If you cut a big hiking trail into one stage per state, you could put the state's name in here (stage:description=Kansas. Don't use stage:description=*, if stage=* is really just an arbitrary day's stage (Day 1, Part 1, and so on). This tag is not meant to be searchable by Nominatim, but to be displayed by editor software, to make it easier to find the correct stage.
New tag label=*
A label is essentially the short textual representation of a route's name, not to be confused with short_name=*. Usually, maps show the name of a route its ref, or a shortened form of the name. Because this proposal encourages to have an empty ref if there is no officially signed one, the data consumer is stuck with having to guess the short form of the name, or with no label at all, because the name/ref is empty. label=* is used to give a 2-5 letter label to routes that data consumers should use to display the route, if no ref=* is set.
An example of a cycle route where this is helpful, is the "Nordhannoversche Moorroute" (aka "Von Moor zu Moor"), which is signed like this:
There is no short ref available and relying on the data consumer to somehow process the two names "Nordhannoversche Moorroute" and "Von Moor zu Moor" into a meaningful short representation, is a gamble. We can help data consumers by giving them a label=Moor or label=VMZM.
This tag should be used by maps and routers, but only if there is no ref=* set.
When to use ref=* and when to use label=*?
Only use ref, when the ref is part of the official logo/image/markers that can be seen along the way. Everyone giving a route by a specific abbreviation is not a ref, but rather a label. In some countries (mainly Germany), it's not uncommon to make up a ref (see this discussion) if there is no official one. This proposal officially discourages this practise and lobbies for the use of label=* instead.
This signpost shows 6 different bicycle routes. The first 3 markers clearly show refs: Ds, Br and Mg. If you look closely, the next 2 also show refs: "EU 2" and "EU 3" as ref, but the last one (Badischer Weinradweg) clearly doesn't feature anything that could be a ref. In this case, you could use label=BW / label=BWR / label=BWRW to help finding a short representation, but it's optional. | |
This signpost has 2 routes. The first one is only marked by an image, so this clearly has no ref and no visible name either. It's called "Mittellandkanal" officially, so you can use that one as name=*, but as for a shortcut like ref=* or label=*: there is none. Make sure to add the logo, because that's what people will identify this by.
The second one has the words "Mittellandkanalroute", which is also no ref. Since the latter cannot be shortened easily by an algorithm, it's advisable to add label=MKR or something similar. | |
Here we have 2 bicycle routes: "Der Deisterkreisel" and "Fahrradregion Regionsring".
The frst one clearly hasn't got any visible ref, just a name. We could add label=DK to give it a good label. The second one shows the logo of the Hannover region, plus an "R" in the top right corner. This should be considered the ref for this route, so ref=R. The "Fahrradregion" at the bottom is part of the logo of similar routes and not part of the ref or label. | |
The 3 routes on the right are named "Feengrotten-Kyffhäuser-Weg" and "Weinbergsweg". None of these have a ref, so label=FKW and label=WB / label=WW / label=WBW along with the symbols is the only thing to tag. | |
This sign shows the hiking route "E2", aka "E2 European long distance path". Since the reference "E2" is clearly visible on the sign: name=E2 European long distance path + ref=E2 + short_name=E2 path
The cycle route "The National Byway" to Burford, however, does not have any visible reference. label=NB is a good fit here. | |
This is a rare case of all markers having a visible ref. On the upper bit of the sigh, the "Heideschleife Haverbeeke" has a nice ref=h. On the lower sign, we have ref=5, ref=7, ref=10, ref=17 and ref=W. You could add label=RB5, 7 and 10 for the first three, but not a must. |
Special case network:type=node_network
Explicitly not part of this proposal, but I wrote some suggestions how node network tagging could be improved while still adhering to the overall suggestions of this document.
Examples
Old | New |
---|---|
ref and name both don't match on the ground
name=Velo visavis Circuit cyclotouristique name:de=Velo visavis Rundweg name:fr=Velo visavis Circuit cyclotouristique network=rcn ref=VeloV route=bicycle type=route |
label=VeloV name=Velo visavis network=rcn roundtrip=yes route=bicycle type=route |
Alternative name is part of the name
description=Veloroute 2 führt…
from=Hannover City
name=Veloroute 2 - Radschnellweg Hannover-Langenhagen
network=lcn
ref=VR2
route=bicycle
to=Langenhagen
type=route
|
description=Veloroute 2 führt… from=Hannover City name=Veloroute 2 alt_name=Radschnellweg Hannover-Langenhagen network=lcn ref=VR2 route=bicycle to=Langenhagen type=route |
Segment, from and to inside the name
from=Hildesheim
name=Kulturroute Hannover, Alternativroute - Abkürzung zwischen Hildesheim und Sarstedt
network=rcn
ref=K
route=bicycle
to=Schliekum
type=route
|
description=Shortcut between Hildesheim und Sarstedt from=Hildesheim network=rcn noname=yes ref=K route=bicycle segment=alternative to=Schliekum type=route |
Stage is part of the name
description:en=The first stage leads… name=Von Moor zu Moor - Etappe 1 network=rcn ref=Moor route=bicycle type=route |
description:en=The first stage leads… from=Altwarmbüchen name=Von Moor zu Moor label=Moor network=rcn noref=yes route=bicycle stage=1 to=Bissendorf type=route |
Missing from/to and section part of the name. The route doesn't have a ref, it was just put there for the renderer. Name didn't match OTG description:en=Outer loop from the Grüner Ring… name=Grüner Ring - Außenschleife Sehnde-Laatzen network=lcn ref=GR route=bicycle type=route |
The sign only says Schleife Sehnde-Laatzen
description:en=Outer loop from the Grüner Ring… from=Anderten label=GR name=Schleife Sehnde-Laatzen network=lcn noref=yes route=bicycle segment=excursion to=Grasdorf type=route |
Stage and denomination are part of the name. To and from missing
name=Jakobsweg Via Scandinavica, Niedersachsen network=nwn pilgrimage=yes ref=Jw vS route=hiking type=route |
from=Lauenburg/Elbe label=VS name=Via Scandinavica network=nwn noref=yes pilgrimage=Camino de Santiago route=hiking stage=2 stage:description=Niedersachsen type=route to=Eisenach Alternatively, we can divide this rather huge route in daily stages like this: from=Lauenburg/Elbe label=VS name=Via Scandinavica network=nwn noref=yes pilgrimage=Camino de Santiago route=hiking stage=10 type=route to=Lüneburg |
British cycle networks are already in good condition
cycle_network=UK:National Cycle Network
name=NCN National Route 6
network=ncn
ref=6
route=bicycle
type=route
|
cycle_network=UK:National Cycle Network from=London name=National Cycle Route 6 network=ncn ref=6 route=bicycle short_name=NCR 6 to=Lake District type=route |
The 9-11 trail has been chopped into stages - one for each state
cycle_network=US:USA
name=9-11 Trail (Maryland)
network=ncn
ref=9-11
route=bicycle
type=route
|
cycle_network=US:USA alt_name=9/11 Trail name=September 11th National Memorial Trail network=ncn ref=9-11 route=bicycle short_name=NMT stage=1 stage:description=Maryland type=route |
Don't put the ref number into the name
hiking=yes
name=Willow Springs Bike Loop #535
network=rcn
ref=535
route=bicycle
type=route
|
hiking=yes
name=Willow Springs Bike Loop
network=rcn
ref=535
route=bicycle
type=route
|
Don't invent names
name=Ciclovía Temuco-Labranza
network=lcn
roundtrip=no
route=bicycle
type=route
|
from=Temuco network=lcn noname=yes roundtrip=no route=bicycle to=Labranza type=route |
To and from in the name
name=Nasjonal sykkelrute 1 (Moss–Bergen)
network=ncn
ref=1
route=bicycle
type=route
|
from=Moss name=Nasjonal sykkelrute 1 network=ncn ref=1 route=bicycle to=Bergen type=route |
stage and alt_name part of the name
cycle_network=EuroVelo
icn_ref=8
name=EuroVelo 8 - Mediterranean Route - part Spain 7
network=icn
ref=EV8
route=bicycle
state=proposed
type=route
|
cycle_network=EuroVelo icn_ref=8 name=EuroVelo 8 alt_name=Mediterranean Route stage=7 stage:description=Spain network=icn ref=EV8 route=bicycle state=proposed type=route |
section_ref and main route part of the name
name=Floris V-pad 9h, Variant Hoog water network=nwn operator=Wandelnet ref=LAW 1-3 route=hiking section_ref=9h type=route |
name=Hoog Water segment=alternative network=nwn operator=Wandelnet ref=LAW 1-3 route=hiking stage=9h type=route |
Example of how you could tag node networks
description=Connection of node 27 and 86
name=Schweinrich (27) - Flecken Zechlin (86)
network=rcn
network:type=node_network
ref=27-86
route=bicycle
type=route
|
description=Connection of node 27 and 86 from=Schweinrich network=rcn network:type=node_network noname=yes ref=27-86 route=bicycle to=Flecken Zechlin type=route |
Staged international hiking path. The E2 splits into a West and an East route, none of which is more "main" than the other We will need a superroute that has both variants - not addressed here description=Westroute: Stranraer (UK) - Birminhgham (UK)[…] name=European walking route E2 west, UK, South East England name:signed=no network=iwn ref=E2 ref:signed=no route=hiking type=route |
description=Westroute: Stranraer (UK) - Birminhgham (UK)[…] from=Stranraer name=European walking route E2 name:signed=no network=iwn ref=E2 route=hiking stage=7 stage:description=South East England to=Birmingham type=route |
Display Name
Editors should consider using the following logic to determine a relation's name:
DisplayName ::= (name | ref | "From " from " to " to | description) ["(" RouteStage " - " RoutePart ")"] RouteStage ::= (stage ": " stage:name | stage:name | stage) RoutePart ::= "From " from " to " to
Features/Pages affected
- stage=* should mention that it only takes numeric values and also explain stage:name=* and stage:description=*.
- route=bicycle and route=hiking should mention rules, best practices and link to the new tags
- Relation:route should mention the new tags
- Roles_for_recreational_route_relations should mention to use segment=* as well
- state=* should remove state=alternate, which is now replaced by segment=alternative
- network:type=node_network should discourage making up route names, and ask to use from=* and to=*.
- The owner and maintainer of Waymarked Trails has agreed to support the new schema should the vote pass.
External Discussions
Follow-up work
- I will create MapRoulette-challenges for the individial countries, to clean up the routes according to best practices
- I'm in contact with the Nominatim maintainer in order to enable searching for routes after the majority has been fixed.