Automated edits/Latvia-bot

From OpenStreetMap Wiki
Jump to navigation Jump to search

Latvia-bot is a collection of scripts published on GitHub to update and maintain OSM data in Latvia:

  • Addresses,
  • LAU 2 (administrative territories), territorial units (towns and rural territories), villages and neighbourhoods of Riga and Valmiera (not implemented yet),
  • Tags.

Need for an automated way to use some of the open data published by the State Land Service on the Latvia's Open Data Portal in OSM was expressed and accepted on the Latvian Talk-lv mailing list in January 2022. Thread on Imports mailing list.

Bot is based on comparing data from OSM and external sources (State Land Services) in PostgreSQL and uploading OsmChange files to OSM. Osmosis and Upload.py are used.

OSM data are used from Geofabrik's daily extract of Latvia, updated with osmupdate, and Geofabrik's daily extract of historical data of Latvia. Because importing into PostgreSQL database, data processing and change retrieval takes some time, elements might be modified meanwhile leading to version mismatch during upload. Thus, conflicting elements due to version mismatch are skipped while uploading.

Permission to use the State Land Service open data on OSM: https://wiki.openstreetmap.org/wiki/Attribution/vzd.gov.lv_explicit_permission.

For questions or comments regarding this project, please get in touch with OSM user Dāvis Kļaviņš, follow the Talk-lv mailing list or join OSM Latvija Zulip chat (discussions related to addresses are publicly available).

Changes done to OSM data by the script are performed as the OSM user latvia-bot since June 2022 approximately every month. Automated updates are not implemented yet.

Bot operates only within the territory of Latvia as defined is OSM.