Skip to main content

20 docs tagged with "Neural classifier"

The encoder-only transformer model — architecture, BIO labeling, decoding, and inference.

View all tags

A walkthrough — NY-NY Steakhouse, Houston, TX

The knowledge ladder explains why the v0.5.0 pipeline grew two new information layers (Stage 2.7 phrase grouper, expanded Stage 5 reconcile). This article walks through what they actually do on one concrete input, end-to-end.

BIO labels

BIO labelling is the trick that lets a token classifier (which decides one token at a time) emit spans (groups of consecutive tokens that mean one thing together). It is the standard approach for sequence labelling tasks in NLP — Named Entity Recognition, part-of-speech tagging, address parsing.

Confidence calibration

Every span the parser emits carries a number when the model says it's 94% sure, is it right 94% of the time?

CRF decoder

A Conditional Random Field (CRF) is a structured-prediction layer that finds the best whole-sequence label assignment instead of picking each token's label independently. Mailwoman's model card carries crfatinference a Viterbi search over a frozen, hand-coded validity table, with no learned transition scores anywhere in the loop. This page explains what ships, and how it got here.

FST gazetteer prior

The FST (finite-state transducer) gazetteer prior is the structure that lets the neural classifier benefit from everything Who's On First already knows. The neural model knows grammar; the gazetteer knows places. The FST is the bridge — pre-computed at build time so the classifier can consult it at inference time without paying gazetteer-lookup costs per token.

How it will work

This is a roadmap snapshot, current as of May 2026. For current state, see the scope declaration, How Mailwoman parses an address, How Mailwoman resolves a place, and How it works now.

How it works now

Mailwoman runs addresses through a staged pipeline. Each stage adds one kind of knowledge the stages below it cannot easily derive. Two models are involved, not one: a small coarse-placer that guesses the country up front (Stage 1.5), and the main neural classifier that labels the tokens (Stage 3). Rule classifiers run alongside the neural classifier, and a policy registry decides whose vote wins for each address component. Outside knowledge — postcodes, the gazetteer — reaches the model as soft hints called anchors, which inform a decision but never override it.

Neural classification

This page used to be the primary explanation of Mailwoman's transformer encoder. It's been superseded — How the model reasons says so in its own See Also, and this page's numbers had drifted out of date besides. Rather than maintain two competing descriptions of the same architecture, here's where to go instead:

ONNX runtime

ONNX (Open Neural Network Exchange) is a standardized format for serializing trained neural networks. ONNX Runtime is the family of inference engines that consume those files. Mailwoman uses ONNX so the same trained model can run in Node.js, browsers, mobile devices, or anywhere else with an ONNX Runtime build.

The knowledge ladder

The staged pipeline is a contract for decomposition by what each layer knows. Every stage is the rightful home of a particular kind of information; pushing work to the wrong stage produces fragile systems that try to learn things from data that they could have looked up, or look up things that they could have learned. This article catalogues the layers, what each one knows, and the two layers we don't ship yet but should.

The tokenization tautology

Traditional address parsers split the input into tokens, classify each token independently, then try to reassemble the pieces into a coherent parse. This sequence contains a structural circularity: you cannot group tokens correctly without knowing their types, and you cannot type them correctly without knowing their groups. The traditional architecture resolves this with heuristics, exceptions, and solver post-processing. The exception pile grows without bound.

Training pipeline

The training pipeline turns raw address data sources into a model file that ships on npm. This article walks through each stage end-to-end. The Corpus construction article digs into the first three stages in more detail.