What it does
The size of the whole
Counted from git on the dev branch: 17,520 lines of application code in 65 files and 6,970 lines of tests in 27 files holding 359 written test cases, in the files that carry this design (the parcel resolver, the OpenAddresses pipeline, the three jobs and their cron routes, the backfill and cutover scripts, the routers for parcel events, disputes, portfolios, historical renumbering, pending resolution requests and the three admin observability views, seven schema files, six migration files and the start-up hook). Beside the code: a 346-line cutover runbook; a 5,436-line generated contract for the first design and a second contract for the follow-on design; the 677-line and 1,075-line designs; a 785-line contract-soundness audit; a 672-line map of the codebase made for the first design; twelve review reports across four rounds; 58 per-layer records (map, map-check, review and re-review). A reference file of 3,235 US counties with their five-digit codes sits in the code. The two designs name 17 new data tables (property_lineage, parcel_event, parcel_event_parcel, portfolio, portfolio_parent, portfolio_property, property_backfill_unresolved, property_dispute, property_dispute_document, property_dispute_claimant, county_coverage, openaddresses_parcels with its prior-snapshot and staging twins, historical_renumbering_events, pending_resolution_request) and the cutover adds a staging table of its own, cutover_soft_deleted_property_ids. They add 13 columns to the property table, two to the people-on-a-property table and one to the user table, more than a dozen new partial, unique and lookup indexes, and a notification event type, so the list of types grows from 21 to 23. The build ran as 28 layers in six days, the first 19 in four: 156 commits on the working branch over those six days, within 677 commits across the wider build.
The design
- RESO UPI, the canonical identity. The Universal Parcel Identifier of RESO, the real-estate industry's standards body, version 2.0: a text identifier built from the country, the county's five-digit code and the county assessor's own parcel number, with an optional part for a unit such as a condominium. It is the identifier on deeds, tax records and title insurance. The database enforces its form with a pattern check (accepting four shapes: pure county, county plus alternate authority, pure alternate authority and provisional) and allows one record per identifier through a partial unique index. The pattern keeps county formatting exactly, so the standard's own example, which contains a space and a full stop, goes in and comes out byte for byte. Every identifier is also split into indexed columns (country subdivision, alternate authority, assessor reference, a normalised assessor reference that a database check ties to the original, and the unit subcomponent), with a rule for which of six URN shapes a parcel takes and a round-trip guarantee tested for each shape: building an identifier from its columns and parsing it back give the same answer.
- No vendor key is ever a uniqueness key (INV-2). Vendor keys are kept only as a cache. The design's own test blanks every one of them and requires that nothing breaks, because one parcel vendor's own keys changed for about 2.4 million parcels in early 2025. The cache column is named
vendor_raw_idso that no column carries a vendor's name. - Resolution is mandatory (INV-3). No property record can be created without an identity, through any route. If the lookup service is down, the person is asked for the parcel number on their tax bill; if they do not have it, they file a request that an administrator resolves. The error text for that case is fixed and tested byte for byte.
- The Global Property Model. A property is one shared record that belongs to no organisation, a ruling recorded as decision C-13. Access sits on the relationship between a person and the property, held in the organisation that person is acting for. A management company and the owner's own account can both work on the same building; each sees only its own work, and the record of the building is shared.
- Claiming. The first thing a person does is "claim property". The relationship (owner, manager or tenant) is a required answer and never a default (INV-7); any other word, such as owner representative, delegate or inspector, is refused on the self-claim path, and an owner representative exists only through a separate invitation by a verified owner (INV-13). There is one verified owner per unit, so a building's owner and a condominium's owner do not collide (INV-10: ownership is kept per property and unit, while locks, self-claim switches and the permission matrix are per property). A second owner claim against a verified owner goes to a dispute that an administrator decides from both sides' documents (INV-6), with one open dispute per unit (INV-16), and no claimant learns who the other is. A person already linked to a property cannot claim again to escalate (INV-17). No owner claim is ever approved automatically (INV-8). Both ways of adding a property run the same duplicate check, so nobody can fork a property that already has a record. Every property-user write carries the active organisation, and is refused if there is none (INV-14).
- The dispute system.
disputes.submit,disputes.reviewanddisputes.getOwn, with three tables. When an administrator verifies one of several unverified owner claims, the rest move into one dispute in the same transaction, which holds a lock on the property and runs at the strictest isolation level, with one dispute row and one row per claimant. Documents carry a 10 MB limit, a type allowlist, a virus-scan stamp that must be set before an administrator can read them, and a fresh signed link per read that lasts at most 900 seconds. The challenger sees only their own side. A partial unique index backs the one-open-dispute rule, so two simultaneous filings cannot both land. - Restoring, never duplicating (INV-15). Claiming a property whose record was deleted restores that same record. Its locks still apply, and the notes the earlier organisation wrote are cleared (the record keeps only parcel facts: identifier, address, centroid and lineage), so one organisation's words never appear as another's. The audit entry records which organisation the row came from and which columns were cleansed.
- Alternate authorities. Land with no county number uses the same identifier form under the authority that does number it: PANYNJ, BIA, BLM, GSA and NYCDOT. An administrator form creates such parcels, warns of similar identifiers, and refuses to record one parcel under two authorities. The list of authorities lives in one constant that the database check, the input validators and the form all import.
- Provisional identities (INV-11). A new building gets a provisional identity of the form
urn:reso:upi:2.0:US:{county}:PROVISIONAL:{id}, and a second claim on the same address, however its spacing or capitalisation differs, is refused by a partial unique index on the normalised address, so two people cannot each claim it before the county has numbered it. The insert uses conflict handling, so two people submitting in the same second get one record and one clear error. When the number arrives an administrator upgrades the record in place under a row lock, its history stays attached, and the change is written to the ledger as a renumbering; if the real identifier already exists on another record, a merge procedure re-parents the claims into it in one transaction. - Portfolios (INV-5). A layer above the parcel for institutions: a named collection of parcels, each with a role (main, ancillary, easement, air rights, support), of ten types from airport and hospital system to school district and municipal agency. A portfolio can sit under more than one parent through the
portfolio_parentjunction, so a hospital belongs to its health system and to its region at once. Loops are rejected at any depth by a recursive database query at the strictest isolation level, with no artificial depth cap; a six-deep chain is a test case. Removed parent links are restored rather than duplicated. A portfolio organises and reports; it never grants access, and a person sees "12 of 36" when that is what they may see. The portfolio tables belong to an organisation while the identity tables are global, so two organisations each keep their own graph. - The parcel lifecycle event ledger (INV-12). Six kinds of event are first-class: split, merge, renumbered, withdrawn, boundary adjusted and reinstated. Every property carries a
lineage_id, a thread that survives the events: children of a split share the parent's, a merge successor shares both predecessors'. The ledger cannot be edited: a correction is a new entry, and lineage records are never deleted. Theparcel_eventrow holds evidence, the actor and notes; a junction table names which parcels were predecessors and which successors, and every read of it goes through the parent event so a deleted event leaves no readable orphans. - Nightly reconciliation.
parcelReconcileJobcompares every active property with the public record each night and proposes events for an administrator to confirm. It works in two phases, so that outside calls are made with no lock held and row locks last only the write (about 100 milliseconds in place of about 50 seconds a batch); it re-reads and locks each row before writing and skips any that changed; one idempotency key covers all six event types, so a run again after a crash adds nothing; notifications are sent after the commit, outside the transaction, with a unique index so a repeat cannot send twice; and it writes an audit entry per property and one per run, under its own system user, whose address uses the reserved.invaliddomain so it can never resolve. It never changes a person's claim on its own. - The reassign-to-successor tool.
parcelEvents.reassignChildren. When a parcel splits, an administrator assigns everything that was attached to it (people, assets, documents, insurance, claims, maintenance, tasks, calendar entries, floor layouts, units, valuations, permissions, portfolio memberships and images) to a successor. Every child table with a property link is named; permissions and portfolio memberships can be copied to all successors, and a claim can be reassigned or rejected with the reason "parcel split". The tool refuses to close while anything is unassigned, runs under a lock at the strictest isolation level, audits each row, and only then retires the predecessor. While it is open, a new claim on the old parcel is refused with an instruction to enter the new number. - Historical renumbering events. An administrator records a renumbering that covered a whole jurisdiction, with its date and evidence; the 2020 New York City renumbering is the seed, written by its own migration.
admin.historicalRenumberinghaslist,createandapplyFanOut: the system writes one ledger entry per affected property exactly once, through an adjunct table whose unique key per property makes a crash safe, and notifies the people on it with a plain request to verify their parcel number. - The parcel resolver. One interface takes an address or a parcel number and returns an identity. Four resolvers sit behind it (one for a number typed in by hand, the census-and-open-data one, and two vendor-specific ones, for Regrid and ATTOM, kept behind the same interface; a setting that selects ATTOM fails at start-up) and are swapped by a setting that is read once per request, so an operator's change applies to new requests while in-flight ones finish. Each resolver states its own recommended pause between batches, so no job holds a vendor's rate limit as a magic number.
vendor-failure.tsgives retries with backoff and a circuit breaker, with thresholds checked when the program boots; every outside failure is classified as brief (RESOLVER_TIMEOUT) or lasting (RESOLVER_OUTAGE), so that it reaches the user as a plain instruction and never as a crash. A change in the vendor's response shape is raised as its own critical error and not disguised as an outage. Smarty's address service is used only to tidy the address text before resolution. - The national open parcel-data pipeline. The US Census geocoder and OpenAddresses, both free, replace the paid vendor (about $375 a month). A monthly job takes an advisory lock, reads the OpenAddresses manifest, downloads each county's snapshot and loads the whole national file into a staging table over hours, then swaps three tables in a single step of milliseconds under a 100 millisecond lock timeout, so the product never reads a half-loaded table. A second monthly job, an hour later, compares this month with last month by set difference to detect renumberings (where the county has parcel numbers) and boundary changes (where it has polygons), and writes events through the same path an administrator uses. A coverage table, drawn from a lookup of 3,235 counties, records for each county whether addresses, parcel numbers and polygons are known, and
properties.getCoveragetells the frontend whether automatic detection is available for a property. A county that fails three months running raises a warning that it is going stale. A change in the source's format stops the job loudly. - The layered migration and its follow-on design. The new identity is added beside the old one, and the two coexist through a changeover limited to 96 hours, with three duplicate checks (by identifier, by the old address key, and by normalised address with neither) so that an old record and a new claim cannot fork, and a claim on a not-yet-filled record fills it in place.
backfill-upi.tsis a resumable script that takes advisory lock 42, selects rows with skip-locked, works in batches of 50 at the vendor's rate, classifies each failure (rate limit, outage, no match, duplicate identifier, address and number disagreement) and sends what it cannot resolve to a review queue; it backs off up to five times per row; a duplicate identifier goes to a merge path with a deterministic winner (a verified owner first, then the most child rows, then the older record). The switch requires fewer than 0.1% unresolved and notifies anyone affected: the cutover soft-deletes the remaining unresolved records, tells every person on each, and writes a critical error for on-call above 100. A second design of nine layers, the follow-on design, makes the hand-typed parcel number reachable from the claim screen, adds the pending-resolution-request flow and its admin queue with a five-business-day promise to the user, brings in the free data sources, keeps every vendor's name out of columns, comments, audit fields and a central allowlist, adds observability (resolver metrics, coverage and detection views) and a smoke-test command that hits the live services to check that their responses still match the code's expectations, and makes sure audit data is never silently truncated. - Cutover safety at four layers. A check at start-up refuses to run on a half-migrated database, an operator command (
pnpm verify-cutover) verifies the state, the dormant-deploy settings hold back what is not ready, and a 346-line runbook governs the order, including a traffic pause, a five second lock timeout and a retry window before the table-wide change, and the written reverse sequence. Three migration files stage the cutover (adding the constraints unvalidated then validating them, so the table is never locked for long); an audit runner follows with advisory lock 43. All four cite the same named invariants. - Admin screens and procedures. A claim-review queue keyed by identifier; a dispute-review page that shows both sides' identities, documents and the property's identifier and address; a backfill-review queue (retry, enter a number, create an alternate-authority parcel, merge, or mark as a data error); a parcel-event creation form; the reassign tool; the alternate-authority form; portfolio management with nine procedures; the provisional-upgrade form; the detected-event queue with acknowledgement; the historical-renumbering tool; the pending-resolution queue; and three observability views.
- Typed evidence and event records. Every event's notes are checked against a schema of its own kind before they are written (
parcel-events-metadata.ts): a renumbering must carry the old and new identifier and the old county and assessor reference, a split must name its parent and at least two successors, and a merge must name the surviving lineage and at least two predecessors, so that a withdrawn event cannot be filed with a renumbering's fields. The evidence an administrator may attach is limited to a closed list of eight keys (parcel-events-allowlist.ts), and the evidence the nightly job stores is extracted by each resolver class itself, so each vendor's vocabulary stays inside that vendor's own file. - The child-table registry.
property-child-tables.tsis the one list of the 26 tables that point at a property (assets, budgets, calendar events, compliance items, financial entries and transactions, inspection and service requests, insurance policies, maintenance items, projects, claims, disputes, images, layouts, passports, settings, units, invitations, valuations, tasks and others), with the documents table, which links to a property by type and number, handled by name. Both the merge of a provisional record and the duplicate-identifier merge in the backfill use it, so neither can leave a child row attached to a retired property. It is counted from the schema itself. - A seeded development county.
seed-dev-parcels.tsloads sample addresses into the coverage and OpenAddresses tables so address lookup can be exercised without the national file. It is repeatable (a second run leaves the same rows), split into pure and database-touching parts, and normalises street and parcel number the same way the resolver does at request time. Two browser regression specs resolve a real Mountain View address in Santa Clara County, one against the procedure itself and one through the add-property screen, and two more cover the add-property flow. - Boot-time checks and a scheduler that cannot drift.
instrumentation.tsis a thin shim that hands off toinstrumentation-node.tsonly in the server runtime, so the edge bundle never loads server-only code. At start-upverifyCutoverAppliedlooks for the three cutover migration files in the migration log and aborts with the runbook's exact message if any is missing; the monthly diff job registers only when its setting (OPENADDRESSES_DIFF_CRON_ENABLED) is on, and the setting itself is validated at boot. Schedules are fixed UTC five-field constants incron-schedules.ts(the nightly reconciliation at 02:00, the diff an hour after the refresh), with shortcuts such as@dailyforbidden so every schedule can be audited at build time. - A seeded historical renumbering. Migration 016 writes the 2020 New York City borough-block-lot renumbering as its own record, so the first jurisdiction-wide event exists before an administrator touches the tool.
- Error contract. The tRPC error formatter (INV-18) carries a structured code from the server to the screen, so the interface can route each case: dispute form, existing dispute, already linked, resolver outage with manual number entry, bad relationship, organisation required and portfolio loop. Every one is a fixed string checked byte for byte.
What it achieved
- Nineteen layers built in four days, and all 28 in six.
- Eighteen invariants, 44 named risks each with a written answer, and four independent review rounds before the contract was generated.
- A contract of 5,436 lines, reviewed by seven agents in parallel.
- The design's own acceptance test: a synthetic renumbering of 1.5 million parcels must produce exactly 1.5 million ledger entries, and a second run must produce none.
- 156 commits in the project over the six days in which the 28 layers were built.
- 17,520 lines of application code in 65 files and 6,970 lines of tests in 27 files with 359 test cases in the named identity files, 17 new data tables, six migration files, a 346-line runbook and a coverage table of 3,235 counties.
The problem it solves
- An address is not a property. A hospital campus is one address and many tax parcels, each owned and taxed separately. A condominium building is many addresses on one ground parcel. Rural parcels share a mailbox. Software that identifies land by its address or its map point merges things that are separate and splits things that are one.
- A data vendor's key is not a property either. The address vendor's key names a mail delivery point. One parcel vendor's own keys changed for about 2.4 million parcels in early 2025. Vendors redo their geocoding over time and silently undo earlier decisions about which records are the same place.
- His product rests on one promise: digitise your property and make sure nobody else can claim it. That needs exactly one record per plot of land in the whole system, and it breaks the moment the identity underneath moves.
- Land itself changes. Counties split parcels, merge them, renumber them, withdraw them and bring them back; New York City renumbered millions in 2020. An identity that cannot follow those events loses the owner's history.
- Institutions do not fit one parcel. An airport is about 36 of them, a hospital system is 28 hospitals of three to eight parcels each, a school district is many. Some land has no county number at all: port-authority airports, tribal trust land, federal land, city street rights-of-way. A new building has none for its first 30 to 90 days.
- A design this deep cannot be trusted on its first draft. He put each draft to independent reviewers before the contract was generated, and every draft is recorded in the design's own history.
- The paid parcel-data vendor first planned was ruled out on cost. He had the same job done from free public sources, and required every limit of those sources to be told to the user or to an administrator. The free sources cover only some counties and cannot see a jurisdiction-wide renumbering, so the design gives each limit a visible answer: a coverage indicator and an administrator's tool for exactly the events no free source can detect.
- A capability that exists in the code but cannot be reached is a gap. He made the hand-typed parcel number reachable from the screen where a person adds a property, so a lookup failure always has a way out, made it the first layer of the second design, and turned the principle into a rule, No Silent Gaps.
- Two layers can each look healthy and still leave a hole between them: a monthly job that runs and finds nothing because the layer that acts on its findings is not there yet. He named the pattern and made it a rule, the dormant-deploy gate.
- Parts that look unrelated hide the same flaw. An audit record that quietly cuts its data when it is too long, a column named for one vendor, and a comment that names one all hide the truth from a later reader, and the follow-on design removes all three.
How he built it
- Research first. Two research papers came before any design: an evaluation of identity schemes, which established the industry standard used here, and an evaluation of parcel data vendors. The design cites them as background and never as authority.
- Eighteen invariants, INV-1 to INV-18, each with its reason. These are the things that must always hold. Every work packet handed to an agent carries all of them word for word with the "why" attached; a packet that points to them or shortens them is a defect. The follow-on design adds NSG-1 to NSG-5 and RM-INV-1 to RM-INV-11.
- Adversarial review of the design, then the 7-agent contract panel. Three reviewers attacked each draft for missing detail, for scope and as an engineer would. The contract compiled from the design then went to seven agents, each hunting one class of defect, and building was refused until all seven returned zero. The first contract is 5,436 lines, and a second panel cleared the follow-on design's contract. A contract-soundness audit of 785 lines followed, and a flag file records the date each panel was cleared.
- Forty-four named risks, RISK-1 to RISK-44, each with its answer written into the design. Two people claiming the same unfinished building in the same second. A nightly job run again after a crash. A vendor quietly changing the shape of its data. An administrator's upgrade racing another administrator's. Each was settled before an agent wrote the code it applies to. Others include a runaway rate-limit loop holding a lock, a vendor key rotation that may cut the old key at once, uploaded files that could carry malware, a cycle created by two simultaneous edits, personal data in a vendor's raw response (so only seven fields of it are stored), and a cutover that would lock the property table under live traffic.
- The Migration Pipeline. Eight steps in fixed order: write the design, review it three ways, clear out the old code, revise every authority document the design changes, rewrite the agents' memory, sweep the project for stale statements of the old design, generate the contract, then build. It stops an agent building against yesterday's design. The authority documents it revised include the product vision, the identifier rules (PCI-1 to PCI-12), the property and claims domain rules and the CTO decisions C-104, C-105 and C-106.
- Layers. Nineteen layers in dependency order, each built from its own brief by one agent, with the gate run after each and a fresh agent reviewing the result against the contract.
- The four-step orchestrator protocol. For each layer of both designs: a map-only pass, a check of that map against the code, the full build, then an adversarial review, with a re-review where the review rejected. The contract sheet was amended seven times during the build as downstream reviews found drift between a brief and the code, each amendment logged, and the layer reviews' findings recorded as a queue of required actions with the trigger for each.
- A source-first review of the whole feature. After the layers, the whole domain went through a source-first review, re-run until it passed.
- No vendor's name beyond one door. All lookups go through one factory,
getParcelResolver. A structural rule stops the build if any code outside one folder names a vendor. The follow-on design extends this to database columns, comments and audit records. - A list of forbidden anti-patterns. Sixteen named ways to get it wrong, among them a vendor key used for uniqueness, a property created with no identity, and split or merge events built without the tool that reassigns what was attached.
- No Silent Gaps (NSG-1). Wherever the system cannot do something automatically it must say so to the affected person or give an administrator a tool. Four companions stand with it: one vendor-neutral interface, a stated behaviour for every outside failure, honest audit records that flag any shortening, and a named trigger for every piece of future work.
- The dormant-deploy gate (RM-INV-11). A part whose effect depends on a later part stays switched off behind a setting until the later part exists, so a scheduled job can never look healthy while doing nothing and events can never pile up unseen. Both gates carry tests that the default does nothing.
- Reverse paths. Every database change carries its written reverse, in order.
- One actor per concern. Each background job writes under a system user of its own, with a warning that reusing one hides who did what from a later investigation.
- Unique advisory-lock numbers in a registry. Every script that takes a database lock lists its number in one file (
lock-registry.md), and a collision check runs before a build. Five are reserved: 42 for the backfill, 43 for the cutover runner, 44 for the monthly refresh (with an overlap guard that exits quietly when a run is already going), 45 for the monthly diff, and 46 held in reserve for the table swap, which is protected today by the database's own table lock and a 100-millisecond timeout. A script tries the lock without waiting and exits cleanly if another copy holds it; the file tells an author to take new numbers from 100 upward. - A build rule that enforces the one door. An ast-grep rule,
no-concrete-resolver-import-outside-factory, with its own tests and snapshot, fails the build when any file outside the resolver folder imports a concrete resolver or vendor client by name, across the api package, the database scripts and both apps; only the backfill and the nightly job are exempt, each for a written reason (RISK-42). - A smoke command against the live services. RM-INV-9: a command that hits the real Census and OpenAddresses services and checks them against the code's validators, so drift in a vendor shows before a deploy.
Named concepts
The named concepts, defined
RESO UPI · Global Property Model · claim property · alternate authority · provisional UPI · lineage_id · parcel_event · portfolio, portfolio_parent, portfolio_property · parcelReconcileJob · reassign-to-successor · historical renumbering events · getParcelResolver · ManualResolver · CensusOaResolver · county_coverage · INV-1 to INV-18 · No Silent Gaps · NSG-1 · RISK-1 to RISK-44 · RM-INV-1 to RM-INV-11 · PCI-1 to PCI-12 · the dormant-deploy gate · the Migration Pipeline · C-13 · vendor_raw_id · backfill-upi.ts
What it shows
He can find the flaw at the base of an industry's data model, choose the right public standard to replace it, and direct AI to build the replacement with every failure case decided in advance.