Data Pipeline
Purpose: ingest and normalize map, POI, elevation, and rule data.
MVP pipeline steps:
- Load OSM fixture or small regional extract.
- Extract bikepacking POIs.
- Normalize categories.
- Store source, source_id, tags, and confidence.
- Prepare route-corridor query indexes.
Production steps:
- Download Geofabrik/planet extracts.
- Build routing graph for selected engine.
- Import POIs into PostGIS/search index.
- Enrich segments with elevation.
- Import protected areas and rules.
- Generate offline pack assets.
Do not use public Overpass instances for production-scale queries.
Implemented skeleton
The package includes a small OSM-like fixture and a normalizer:
npm -w @pikebacker/data-pipeline run normalize:sample
The normalizer maps OSM tags into bikepacking POI categories (water, food, sleep, repair, bailout, charging, emergency) and preserves source, tags, opening_hours, confidence, and OpenStreetMap attribution hooks. Production ingestion should write the normalized records into PostGIS using schemas/database.sql.