Skip to content

osm-nz/place-name-conflation

Repository files navigation

NZGB ➡️ OSM place name conflation

Test Lines of code

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
Loading

Usage

If you want to help by adding missing place names, visit ✨the dashboard✨.

Setup

If you want to contribute to the code, the following needs to be done manually:

  1. Clone this repository
  2. Download nodejs v20.11 or later
  3. Run corepack enable
  4. Run yarn
  5. Run yarn start
  6. Use the generated osmPatch files to update the place names in OSM
  7. Or run the website locally by running cd client && yarn start

The original import

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:

See the legacy tag for the final version of the codebase which included these features.