Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Searching OpenStreetMap with Elasticsearch
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Christoph Lingg
November 24, 2015
Programming
1.1k
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Searching OpenStreetMap with Elasticsearch
Christoph Lingg
November 24, 2015
Other Decks in Programming
See All in Programming
Android CLI
fornewid
0
220
freeeにおけるEvalsの実践例の紹介
freee
PRO
0
110
Terraform標準の組織で AWS CDKをどう使うか
mu7889yoon
1
510
2年かけて Deno に DOMMatrix を実装した話 / How I implemented DOMMatrix in Deno over two years
petamoriken
0
210
FDEが実現するAI駆動経営の現在地
gonta
2
280
What's New in Android 2026
veronikapj
0
260
AWS DevOps AgentのAzure接続機能を検証して見えた活用法/Use Cases Verified for the AWS DevOps Agent's Azure Connectivity Feature
masakiokuda
1
230
Go 1.27 における memory allocation の高速化
andpad
0
170
<title><a id="</title>君はこのHTMLをパースできるか"></a></title> #雑LT_study
pizzacat83
0
140
Laravelで学ぶ Webアプリケーションチューニング入門/web_application_tuning_101
hanhan1978
4
1.8k
「寝てても仕事が進む」Claude Codeで組む第二の脳
tomoyafujita2016
0
330
Google Apps Script で Ruby を動かす
kawahara
0
220
Featured
See All Featured
How to Talk to Developers About Accessibility
jct
2
510
How to make the Groovebox
asonas
2
2.3k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
A Soul's Torment
seathinner
6
3.4k
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
700
End of SEO as We Know It (SMX Advanced Version)
ipullrank
3
4.4k
AI Search: Where Are We & What Can We Do About It?
aleyda
0
7.8k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
210
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
23k
Have SEOs Ruined the Internet? - User Awareness of SEO in 2025
akashhashmi
0
410
How to Think Like a Performance Engineer
csswizardry
28
2.7k
Navigating Team Friction
lara
192
16k
Transcript
Searching OpenStreetMap with Elasticsearch photon.komoot.de Christoph Lingg –
[email protected]
komoot
OpenStreetMap • free • editable map • worldwide • built
by volunteers • open-content licence
OpenStreetMap
OpenStreetMap
Geocoding „Böcklerpark“ Coordinate(10.1 50.2) Park Kreuzberg, Berlin, Germany
Nominatim • started many years ago • standard solution for
OSM • based on Postgres/Postgis, SQL, PHP, C • powerfull + mature • drawbacks ◦ slow ◦ no typo tolerance ◦ no partial match / search-as-you-type
Closing the Gap • suitable for mobile usage • “built
on the shoulder of a giant” → elasticsearch • open source • free public API • enhance the OSM ecosystem
{ "name": "VIASKO", "housenumber": "33a", "amenity": "restaurant", "coordinate": [10, 52
], "street": "Bahnhofstraße", "postcode": "10403", "city": "Berlin", "state": "Berlin", "country": "Germany", "context": "Kreuzberg", "importance": 0.1 } OSM Entry { "name": "VIASKO", "housenumber": "33a", "amenity": "restaurant", "coordinate": [10, 52] } Photon Document
Photon Importer VIASKO Bahnhofstraße Postcode 10403 City Berlin State Country
Germany Berlin Nominatim DB Postgis Elasticsearch Index Photon Importer
Type-ahead search "filter": { "photonngram": { "min_gram": "1", "type": "edgeNGram",
"max_gram": "100" },... }
Typo Tolerance "query": { "bool": { "must": { "match": {
"collector.default": { "fuzziness": 1, "query": "${query}", "analyzer": "search_ngram", "prefix_length": 2 } } }, "should":{ "match": { "collector.${lang}.raw": { "query": "${query}", "boost": 100, "analyzer": "search_raw" } } } }
Location biased "score_mode": "multiply", "functions": [ { "script_score": { "script":
"1 + doc['importance'].value * 100" } }, { "script_score": { "script": " dist = doc['coordinate'].distanceInKm(lat, lon); 0.5 + ( 1.5 / (1.0 + dist/40.0) )", "params": { "lat": "${lat}", "lon": "${lon}" } } } ]
Photon Project • 100 Mio documents • 60 GB search
index • easy install • photon.komoot.de • github.com/komoot/photon • want be informed for the next sprint? →
[email protected]
komoot.de/hack15