geocoder_nlp

Crates.iogeocoder_nlp
lib.rsgeocoder_nlp
version0.2.1
created_at2025-12-10 05:20:58.714204+00
updated_at2025-12-22 11:52:25.975374+00
descriptionRust bindings for geocoder-nlp
homepage
repositoryhttps://github.com/catacombing/charon
max_upload_size
id1977516
size39,112,892
Christian Duerr (chrisduerr)

documentation

README

Geocoder NLP Rust bindings

Geocoding is the process of taking a text-based description of a location, such as an address or the name of a place, and returning geographic coordinates.

This crate statically compiles geocoder-nlp, which is an offline-capable geocoder using postal for address normalization.

While geocoder-nlp and libpostal are compiled statically, it will still link dynamically to kyotocabinet, sqlite3, and marisa. All of these are required runtime dependencies.

Additionally boost is required as a compile-time dependency.

Examples

use geocoder_nlp::Geocoder;

let mut geocoder = Geocoder::new("/tmp/postal", "/tmp/postal", "/tmp/geocoder").unwrap();

// Get all results matching `Rúa` in our selected dataset.
let mut results = geocoder.search("Rúa", None).unwrap();

// Output results in descending relevance.
while let Some(result) = results.next() {
    println!("Title: {}", result.title());
    println!("Latitude: {}, Longitude: {}", result.latitude(), result.longitude());
    println!("Address: {} {}", result.postal_code(), result.address());
    println!();
}
Commit count: 0

cargo fmt