Skip to main content

Open source · No API key · Runs in your process

An address parser and geocoder that runs where your code runs.

Install it from npm, load a 39.4 MB model, and turn messy address text into labeled components and coordinates — with no server to call and no address leaving your infrastructure.

"1600 Pennsylvania Ave NW"→38.8977, -77.0365rooftop

Neural address parser

A 6-layer encoder over a 73,143-piece SentencePiece vocabulary, quantized to int8 and executed on ONNX Runtime. Emits 33 BIO labels over 16 component tags — country, region, locality, postcode, street, house number, unit, venue and the rest — each with a confidence score.

Gazetteer-backed resolver

Parsed components resolve to Who's On First place IDs and WGS-84 coordinates over pre-indexed SQLite. It uses only node:sqlite, without SpatiaLite or a native build step. The gazetteer is a 1.65 GB download you keep, not a service you call.

Node and the browser

Node 24.18 or later, and the same pipeline in a browser tab: the classifier on onnxruntime-web, the resolver on WASM SQLite over a byte-ranged gazetteer. Earth is that build, not a hosted API behind a text box.

Drop-in and agent surfaces

Nominatim-, Photon- and libpostal-compatible servers answer on the shapes your client code already speaks, so a migration can be a hostname change. @mailwoman/mcp exposes parse, geocode and POI search to any MCP-compatible agent over stdio.

Quick start

Library

npm install mailwoman @mailwoman/neural @mailwoman/neural-weights-en-us
import { createRuntimePipeline } from "mailwoman"
import { NeuralAddressClassifier } from "@mailwoman/neural"

const classifier = await NeuralAddressClassifier.loadFromWeights({ locale: "en-US" })
const parse = createRuntimePipeline({ classifier })

const result = await parse("apt 4b 350 5th ave new york ny 10118")
// result.tree.roots — nested by geographic containment:
// region "NY" › locality "New York" › street "5TH"
// › unit "Apt 4B" · house_number "350" · street_suffix "Ave"
// …and postcode "10118" under the locality

CLI

npx mailwoman parse "350 5th Ave, New York, NY 10118"
{
"region": "NY",
"locality": "New York",
"street": "5th",
"house_number": "350",
"street_suffix": "Ave",
"postcode": "10118"
}

No coordinates in that output, because geocoding needs the gazetteer. Your first ten minutes covers what you get out of the box and what still needs a download.