Turns a handwritten address into a point on the map, using the city's official register and the IBGE address grid. All inside PostgreSQL.
PostGISPL/pgSQL
What it is
Geocod is the engine that finds on the map an address someone typed however they could. It runs entirely inside PostgreSQL/PostGIS, in PL/pgSQL functions, with no application layer in between. Together with the Geocod API and Geocod Web, it forms a set of three pieces.
What it is for
Put health records on the map using the official street register and the IBGE address grid, without personal data ever leaving the database.
What it does
Compares the text through a 12-phase cascade: trigrams, Jaro-Winkler, phonetics and handling of connectors.
Resolves the street and, when possible, the door number (exact or interpolated).
Records how each address was resolved, for audit and correction.
Works by neighborhood and, if it needs to relax the scope, flags it in the result.
Flags ambiguities instead of guessing, and points out duplicate streets in the register.
In tests with 10,000 real addresses from health records, it resolved 88% of streets and 69% of door numbers, at about 224 addresses per second (development machine).
Pairs with the Geocod API, which offers it to other systems, and with Geocod Web, which puts it in the hands of people who do not code.
From address to point, all inside the database.The three pieces working together.