Address matching often begins with a messy string and ends with a Unique Property Reference Number: the identifier for a particular property. The difficult cases are not always dramatic spelling mistakes. Sometimes a small change makes an address describe a different flat, house or building.
There are amazing progress in the UK address matching space, such as the UK_Address_matcher. But a consistent bottleneck I hear people discuss was the lack of realistic, messy address for large-scale linkage methods comparison & evaluation.
That is why I have released address-errors, an open Python package for generating realistic UK address-recording errors with known answers.
A few examples
Consider an address such as:
2ND FLOOR FLAT 14 CHESTNUT AVENUE
If the flat or floor information is dropped, the result may become the address of the parent building rather than the individual dwelling.
A number change can have a similar effect:
193 Hamilton Street193B Hamilton Street
These may be different properties, even though the edit is only one character.
There are the kinds of mistakes that can cause an address matcher to link a record to the wrong property. They are easy to miss because the resulting address often looks perfectly plausible.
Learning the patterns
The package was developed by comparing council tax address records with canonical address data for the same UPRNs. The differences were classified into named mechanisms, including sub-unit errors, building-name changes, number changes, formatting changes, postcode errors and label drift.
The generator then applies these mechanisms to clean address components. Each output includes an audit table showing what happened and what the correct answer should be. That makes it possible to test an address matcher on realistic errors rather than on generic random noise.
A taxonomy of address errors
The package describes 59 named mechanisms grouped into 11 families: The important distinction is that some families alter presentation while others can change which property the address describes.
- Sub-unit (SU): errors in flats, rooms, units or floor information.
- Building name (BN): adding, dropping or changing a building name.
- Primary number (PN): changes to the main house or property number.
- Descriptive qualifier (DQ): changes to words such as “rear”, “annexe” or “former”.
- Street (ST): changes to the street name or street description.
- Locality (LO): changes to neighbourhood, village or locality information.
- Text edits (TX): spelling changes, dropped words, abbreviations and similar edits.
- Format (FM): changes to punctuation, spacing, case or the order of address components.
- Postcode (PC): postcode recording or transcription errors.
- Label drift (LB): the address string is plausible, but the attached UPRN belongs to another related property.
- Systemic (SY): errors caused by the recording system, such as truncating an address at a fixed character limit.
What transferred, and what did not?
The evaluation produced encouraging but qualified results. For an unseen urban council with similar characteristics, the generator reproduced:
- the broad volume of address errors;
- the mix of error mechanisms;
- the rate of collisions with other real properties.

Error volume across leave-one-council-out checks.

Collisions occur when a recorded address matches another real property.
The result was different for councils at the edges of the development data. A rural council had roughly twice the error volume produced by the pooled setting, while a low-error council had substantially less. Overall intensity therefore needs to be calibrated to the source. Recording style also matters. Commas, field separators, wording and component order can reveal which system produced an address. These features need to be fitted from the same address field that the matcher will use.
What the package provides
The generator produces recorded-style addresses from clean address components. Every output includes a truth table showing:
- the property the address came from;
- the UPRN carried by the record;
- the error mechanisms applied;
- whether the property identity shifted;
- whether the result collides with another real address.
This gives researchers and developers a controlled way to test address-to-UPRN matchers, including difficult cases involving flats, buildings, rural properties and neighbouring addresses.
The package is available on PyPI and GitHub.
A paper describing the method and evaluation is in preparation. It will set out the results, limitations and the cases where the learned profile did not transfer well!
