Two documents describe the same flat. One was written on move-in day, one on move-out day. A third party who has seen neither property has to read both and decide who gets the money.
That is a diff problem, and most inventory software gets it wrong by treating each report as an independent document.
The failure mode
A check-in report says:
Kitchen
Worktop - laminate, beech effect, good condition
Floor - vinyl, clean
The check-out report, written five months later by a different clerk using the same software, says:
Kitchen / Diner
Work surface - 40mm laminate, two burn marks near hob
Flooring - cushion vinyl, staining under sink
Everything here is true and the report is worthless. Nothing in the data model ties "Worktop" to "Work surface", so there is no machine-readable diff and the human reading it has to do the matching by hand. When the matching is ambiguous, the ambiguity is resolved against whoever is making the claim.
Stable item IDs, assigned once
The fix is to treat the check-in report as the schema, not just the first document.
type Item = {
id: string; // stable for the life of the tenancy
roomId: string;
label: string; // display only, may change
kind: ItemKind; // enum, not free text
observations: Observation[];
};
The id is minted at check-in and never regenerated. Check-out does not create items; it creates observations against existing ones. A clerk can rename label from "Worktop" to "Work surface" and the diff still lines up, because the diff runs on id.
Deriving the id from the content is the tempting shortcut and the wrong one. hash(room + label) breaks the moment someone fixes a typo. Use a ULID or a UUID, store it, and treat the label as presentation.
Three timestamps, not one
Every observation needs three distinct times, and they are frequently different:
-
capturedAt— what the camera said -
recordedAt— when the clerk saved it in the app -
reportedAt— when the report was issued
They diverge when a phone's clock is wrong, when a clerk works offline in a basement flat, or when a report is issued three days after the visit. Collapsing them into one field destroys the only evidence you have that the divergence was innocent. I wrote about the EXIF side of this here.
Enumerate the condition vocabulary
Free-text condition is the second biggest source of unmatched items. An adjudicator discounts "good" and "fair" because they are not comparable between two authors. A closed vocabulary forces the clerk to describe instead:
type Observation = {
itemId: string;
cleanliness: 'professional' | 'domestic' | 'below-domestic';
condition: 'new' | 'good' | 'serviceable' | 'worn' | 'damaged';
note: string; // required when condition is 'worn' or 'damaged'
mediaIds: string[]; // required when condition is 'damaged'
};
Making note and mediaIds conditionally required is a two-line validator that removes most of the disputes we see. A damage claim with no photo attached should not be submittable.
Render the diff, do not make the reader compute it
Once the ids are stable, the check-out document can render as a change set rather than a second inventory:
Kitchen
[unchanged] Flooring
[changed] Work surface good -> damaged 2 photos
[missing] Bin, pedal, chrome
missing is its own state and should never be folded into damaged. They are different claims with different evidence requirements.
Why the modelling matters commercially
This is not an abstract data-modelling exercise. In the UK, a disputed tenancy deposit goes to the scheme's adjudicator, the process is documentary only, and the starting position is that the money belongs to the tenant. Every deduction has to be proven individually. A report that cannot be diffed is a report that cannot prove anything about when damage appeared.
If you want the non-technical version of the same argument, we wrote it up as what a landlord inventory report must contain, and there is a free browser tool that walks through the evidence the way an adjudicator does: the Deposit Evidence Checklist.
On the business side
I run Capital Complete Solutions, an AIIC-accredited property inventory firm in Birmingham. We produce inventory reports, check-in and check-out inspections across the West Midlands, which is where this data model came from — several hundred reports and a running count of which ones survived a dispute.
If you are building in this space and want to argue about the schema, the comments are open.
Top comments (0)