# Self-hosted local discovery cartography

© OpenStreetMap contributors. The bounded cartographic dataset in `norfolk/`
is distributed under the [Open Database License 1.0](https://opendatacommons.org/licenses/odbl/1-0/).
See [OpenStreetMap copyright and contributors](https://www.openstreetmap.org/copyright).
The derived data is available directly through the public tile JSON files listed
in [the manifest](norfolk/manifest.json). The licence applies to this map extract;
seller/listing records are a separate database and are not included in these files.

Source: a single Overpass API download at https://overpass-api.de/api/interpreter,
with OSM base timestamp and original download SHA256 in the manifest. Query:

```overpass
[out:json][timeout:120];(
way[highway~"^(trunk|primary|secondary|tertiary)$"](52.2,0,53.15,2.05);
way[waterway=river](52.2,0,53.15,2.05);
way[railway=rail](52.2,0,53.15,2.05);
way[landuse=residential](52.2,0,53.15,2.05);
node[place~"^(city|town|village)$"](52.2,0,53.15,2.05);
);out geom;
```

Rebuild with `frontend/scripts/build-local-map.py` and Shapely 2.1.2 in an
isolated build environment. It simplifies lines (0.00018-degree tolerance), omits
very small residential patches, clips geometry to 0.25-degree tiles, then encodes
projected SVG paths with WGS84 settlement-label points. This is context for
discovery, not a navigation map, complete street directory or address locator.
Roads, water and place names are real; the rendering is stylised. Cartography is
fetched from our own static assets only after zooming beyond the UK overview.
No external runtime map requests, API key, tracking or location permission.

The UK overview uses separate public-domain Natural Earth country geometry;
see `src/components/home/uk-map-sources.md`. Listing areas remain the existing
fixed 0.05-degree public cells. Photo pins share the selected cell and never
represent individual collection addresses.

## Public handover places

[`meet-spots.json`](meet-spots.json) is a separate ODbL catalogue of mapped cafés,
libraries and settlement centres. It contains public map records only. The
`osm_base` and original download SHA256 are recorded inside it. Source: one
Overpass API request to `https://overpass-api.de/api/interpreter`:

```overpass
[out:json][timeout:90];(
nwr[amenity~"^(cafe|library)$"][name](52.35,0.15,53,1.75);
node[place~"^(city|town|village)$"][name](52.35,0.15,53,1.75);
);out center tags;
```

Build with `python backend/scripts/build_meet_spots.py <download.json>`. The
builder removes explicitly restricted, closed, takeaway-only and outdoor-only
records, and nearby duplicate named POIs. Duplicate settlement names use nearby
town names for readable labels; these describe proximity, not administrative
boundaries or walking routes. Missing access/hours tags are unknown,
not evidence of suitability. Place names, addresses, tagged opening-hours text
and tagged wheelchair access are selected; phone numbers and arbitrary website
URLs are omitted. Selected mapped centres are not pedestrian entrance points.
The same catalogue is bundled privately for Python matching and published here
for source/licence access. No customer/listing coordinates enter either copy.

The guide does not certify a venue, its opening times, wheelchair accessibility,
permission for a handover or personal safety. Users should check directly and
agree arrangements in chat. Straight-line distances from chosen town centres
are not walking routes. Search stops if the catalogue is over 90 days old, until
an operator rebuilds and deploys a reviewed snapshot. The catalogue is separate
from seller/listing records and the older stylised map extract above.

## Walking estimates

`walking-routes.json` is a public ODbL derived route catalogue. It contains only
public OpenStreetMap settlement centres, cafés/libraries and mapped paths between
them. No listing, seller, buyer, postcode or home coordinates enter the build.
The application records which public venue a seller explicitly approves in a
separate database; those records are never included in this download.

The graph was built from the Norfolk, Suffolk and Cambridgeshire Geofabrik OSM
extracts with source timestamp 18 October 2026. Exact public source URLs/download
hashes, graph hash, engine identity, public-place source date and build counts are
embedded in the JSON. The graph uses Valhalla 3.9.1; production uses the reviewed
static results and runs no routing service or external map request. Rebuild with
`backend/scripts/build_walking_routes.py`; see `backend/docs/walking.md`.

For each public centre, candidate venues within 3 km were routed using the
pedestrian model at 4.5 km/h. Each accepted route uses the actual path/route time,
not the separate matrix estimate or a straight-line walking approximation.
Ferries, timed-access routes, non-pedestrian legs, estimates above 30 minutes and
endpoints more than 35 metres from the mapped path are excluded. Endpoint gaps
receive a time/distance allowance; they are not drawn as invented paths. Results
round the final time upwards. No route is substituted when the engine cannot
find one. The catalogue expires after 30 days; venue consent expires separately.

The preview is stylised and is not live navigation, a verified entrance, opening-
hours check, right-of-way guarantee or accessibility assessment. Real pace,
crossings, hills and carrying an item can change the journey. © OpenStreetMap
contributors, [ODbL 1.0](https://opendatacommons.org/licenses/odbl/1-0/).

`walking/manifest.json` lists the separately downloadable 0.05-degree street-
context tiles used only around the accepted routes. They derive from the same
public Geofabrik extract, using osmium 4.3.2 and Shapely 2.1.2 at build time;
`backend/scripts/build_walking_context.py` records the source/PBF/route hashes.
The context includes real streets, paths and selected street names. It is not a
separate permission/access check: the highlighted route comes from the pedestrian
route catalogue. Tiles load from SellitLocal only, and failed detail requests have
an explicit retry. No full graph or tile catalogue is loaded into the page.
