1 of 42

What's new in

by Jake Low @ State of the Map US 2025

2 of 42

OSMCha is a web application (osmcha.org)

for reviewing and visualizing OSM changesets

3 of 42

What’s a changeset?

Created when a mapper saves their edits

Records changes to OSM over time

4 of 42

5 of 42

list of changesets

6 of 42

visualization of selected changeset

7 of 42

changeset metadata

8 of 42

details about change

to selected element

9 of 42

filter changesets by various criteria

10 of 42

…and save your filter so you can be alerted when new changesets match it

11 of 42

OSMCha is used by mappers to…

  • Review each other’s edits, suggest improvements, and spot errors
  • Detect vandalism and undiscussed imports/mass edits
  • View old changesets to help understand why a change was made

12 of 42

so what's new in

13 of 42

adiffs.osmcha.org

a new data service powering the OSMCha website

14 of 42

old shape

new shape

15 of 42

old tags

new tags

16 of 42

<node id="123" version="1" lon="-71.108956" lat="42.350936"/>

<node id="456" version="1" lon="-71.105214" lat="42.351605"/>

<way id="101" version="1">

<nd ref="123"/>

<nd ref="456"/>

<tag k="highway" value="footway"/>

<tag k="surface" value="concrete"/>

</way>

17 of 42

<node id="123" version="2" lon="-71.108956" lat="42.350936"/>

<node id="456" version="1" lon="-71.105214" lat="42.351605"/>

<way id="101" version="1">

<nd ref="123"/>

<nd ref="456"/>

<tag k="highway" value="footway"/>

<tag k="surface" value="concrete"/>

</way>

still version 1 (not technically changed)

18 of 42

Problem: OSM API does not provide this data

GET https://www.openstreetmap.org/api/0.6/changeset/155530622/download

<osmChange>

<modify>

<node id="2523603738" version="3" lat="47.6647943" lon="-121.2881568">

<tag k="highway" v="trailhead"/>

<tag k="name" v="Necklace Valley Trailhead"/>

<tag k="operator" v="US Forest Service"/>

<tag k="website" v="https://www.fs.usda.gov/…"/>

</node>

</modify>

</osmChange>

  • only shows new version, not old
  • no information about ways that the modified node belongs to

19 of 42

Solution: build our own augmented diffs

  • augmented diffs contain both old and new versions of elements, and also contain elements that were indirectly modified by a change
  • format devised by Overpass API

20 of 42

https://adiffs.osmcha.org/

a new standalone HTTP service providing augmented diffs for OSM changesets

used by OSMCha, and also available for other software to use

Replaces s3://real-changesets

makes loading a changeset on osmcha.org much faster (<1s instead of 15-60s)

Technical details:

https://openstreetmap.us/news/2025/05/

osmcha's-new-upgrade/

21 of 42

osm-adiff-parser

22 of 42

https://github.com/osmcha/osm-adiff-parser

Input

Output

23 of 42

new map colors and symbology

24 of 42

before

after

25 of 42

before

created elements

old versions of modified elements

new versions of modified elements

deleted elements

changeset bounding box

new versions of ways

relations (bounding box)

old versions of ways

26 of 42

after

created elements

new versions of modified elements

(geometry changes only)

old versions of modified elements

new versions of modified elements

(with tag changes)

deleted elements

context elements

old versions of ways

new versions of ways

relations (bounding box)

27 of 42

maplibre-adiff-viewer

28 of 42

https://github.com/osmcha/maplibre-adiff-viewer

29 of 42

osmcha-cli

30 of 42

https://github.com/osmcha/osmcha-cli

31 of 42

https://github.com/osmcha/osmcha-cli

$ curl https://adiffs.osmcha.org/changesets/162592907.adiff | osmcha

32 of 42

https://github.com/jake-low/overpass-cli

$ overpass --area 'Utah' --format json 'node[natural = arch]'

{

"version": 0.6,

"generator": "Overpass API 0.7.62.1 084b4234",

"elements": [

{

"type": "node",

"id": 759250908,

"lat": 38.7911745,

"lon": -109.6089896,

"tags": {

"name": "Navajo Arch",

"natural": "arch"

}

},

...

]

}

33 of 42

https://github.com/jake-low/overpass-cli

$ overpass \

--area "Boston" \

--adiff 2025-01-01T00:00:00Z 2025-06-15T00:00:00Z \

-–out geom \

'way[highway](area)' \

> boston.adiff

34 of 42

https://github.com/jake-low/overpass-cli

$ overpass \

--area "Boston" \

--adiff 2025-01-01T00:00:00Z 2025-06-15T00:00:00Z \

-–out geom \

'way[highway](area)' \

> boston.adiff

$ osmcha boston.adiff

35 of 42

36 of 42

Summary

  • adiffs.osmcha.org
  • updated map visualization
  • maplibre-adiff-viewer
  • osm-adiff-parser
  • osmcha-cli

37 of 42

Summary

  • adiffs.osmcha.org
  • updated map visualization
  • maplibre-adiff-viewer
  • osm-adiff-parser
  • osmcha-cli

faster and more correct

easier and more intuitive

extract useful pieces into reusable libraries…

…enabling interesting new use cases!

38 of 42

Thanks for listening!

39 of 42

appendix

40 of 42

Replication files

Minutely updates from openstreetmap.org

Contain every change to the map in a one-minute window

osmChange (XML) format

41 of 42

planet.openstreetmap.org replication files

osmx-adiff-builder

github.com/osmcha/osmx-adiff-builder

OSMExpress database

downloads changeset data

(new versions of elements)

generates augmented diffs

and uploads them to storage bucket

afterwards, applies diffs to planet replica to keep it up-to-date

reads old versions of elements (and indirectly modified elements) from planet replica

42 of 42

OSMExpress

  • a fast database file format for OpenStreetMap data
  • built on LMDB and S2; organized as a set of key-value tables
  • supports in-place updates (unlike .osm.pbf), so you can keep an OSMExpress database synced with upstream changes to OSM

See Brandon Liu's talk at SOTMUS 2019 for more details:

https://openstreetmap.us/events/state-of-the-map-us/2019/osm-express-a-spatial-file-format-for-the-planet/