Boston Transit in Real-Time with Apache NiFi and FLaNK Stack
I will be speaking at the Data Summit 2024 in Boston very soon. Here is a preview of some real-time LLM workloads I am working on.
Join me here:
Data Flow
DATA
- Service Alerts: https://cdn.mbta.com/realtime/Alerts.pb
- Trip Updates: https://cdn.mbta.com/realtime/TripUpdates.pb
- Vehicle Positions: https://cdn.mbta.com/realtime/VehiclePositions.pb
- Service Alerts: https://cdn.mbta.com/realtime/Alerts.json
- Trip Updates: https://cdn.mbta.com/realtime/TripUpdates.json
- Vehicle Positions: https://cdn.mbta.com/realtime/VehiclePositions.json
- Service Alerts: https://cdn.mbta.com/realtime/Alerts_enhanced.json
- Trip Updates: https://cdn.mbta.com/realtime/TripUpdates_enhanced.json
- Vehicle Positions: https://cdn.mbta.com/realtime/VehiclePositions_enhanced.json
curl -X GET "https://api-v3.mbta.com/alerts?filter%5Bactivity%5D=BOARD%2CEXIT%2CRIDE" -H "accept: application/vnd.api+json"
CUSTOM PYTHON — Address To Lat / Long
{'place_id': 18032036,
'licence': 'Data © OpenStreetMap contributors, ODbL 1.0. http://osm.org/copyright',
'osm_type': 'relation',
'osm_id': 11195637,
'lat': '42.3541466',
'lon': '-71.06143718117355',
'class': 'building',
'type': 'office',
'place_rank': 30,
'importance': 9.99999999995449e-06,
'addresstype': 'building',
'name': 'Lafayette City Center',
'display_name': 'Lafayette City Center, Chauncy Street, Downtown Crossing, Downtown Boston, Boston, Suffolk County, Massachusetts, 02111, United States',
'boundingbox': ['42.3534847', '42.3548087', '-71.0620029', '-71.0601783']
}
To pick a location, I highly recommend looking at the awesome Open Street Maps.