This repository contains the code that regularly compares place names in OpenStreetMap with the New Zealand Geographic Board (Ngā Pou Taunaha o Aotearoa) Gazetteer.
How this works:
- Once a week, the following process is automatically run:
- The list of place names is downloaded from the NZGB
- An extract of the OpenStreetMap planet is downloaded (containing only Oceania & Antarctica)
- All wikidata features that are linked to the NZGB are downloaded
- The OpenStreetMap planet is compared with the gazetteer, and any discrepancies are identified and categorized
- The result of the conflation process is converted into a format that allows OpenStreetMap mappers to review each place using the same tools as the LINZ-to-OSM address import.
flowchart LR
OSM -->|wikidata| Wikidata
Wikidata -->|P5104| NZGB
OSM -->|ref:linz:place_id| NZGB
If you want to help by adding missing place names, visit ✨the dashboard✨.
If you want to contribute to the code, the following needs to be done manually:
- Clone this repository
- Download nodejs v20.11 or later
- Run
corepack enable
- Run
yarn
- Run
yarn start
- Use the generated
osmPatch
files to update the place names in OSM - Or run the website locally by running
cd client && yarn start
This codebase originally included a lot of complicated logic, which was used to speed up the one-off effort of importing 30,000 place names. Now that the initial import is complete, this logic has been removed to simplify and speed up the process, so that it can run automatically every week.
Some of the removed logic includes:
- Automatically detecting matching features with no
ref:linz:place_id
tag - Logic to guess whether a name is English or te reo Māori (moved to a separate repository)
- A system for extracting
name:etymology
from the feature's description - A system for importing the geometry of lines/areas that were missing using the LDS
See the legacy
tag for the final version of the codebase which included these features.