CONTEXT.md gets the monitor glossary (Known Vehicle, Alert, Recurring Unknown; Gate and Whitelist removed). CLAUDE.md records the fork decisions, the UniFi webhook contract, inherited gotchas and the agreed MVP roadmap.
2.2 KiB
Gate Watch
Street plate monitor: LPR cameras watch the street in front of the owner's house/company, the system records every plate that passes and notifies about the ones that matter. It observes — it never drives a gate.
Language
Plate:
A validated Brazilian license plate in its canonical form: uppercase, no
separators, 7 characters in the old (AAA9999) or Mercosul (AAA9A99) layout.
"Valid" and "normalized" are the same act — a Plate cannot exist un-normalized.
Avoid: license, placa (raw), plate string.
Passage: A single sighting of a Plate by a Camera at a moment in time, with the captured image. Direction (in/out) is optional metadata — the UniFi source never provides it, so a Passage is meaningful without it. The historical record of who passed. Avoid: event, detection record, sighting (as a distinct type), passagem.
Known Vehicle (pt-BR: veículo conhecido):
A Vehicle whose Owner is identified. Being Known is identification, not
permission — nothing is allowed or denied on a public street. The legacy flag
name is_whitelisted still carries this meaning in code and DB.
Avoid: authorized, whitelisted (in new writing).
Owner: The party a Vehicle belongs to: a Driver or a Company, never both. Having an Owner is what makes a Vehicle Known. Avoid: holder, proprietário (as a distinct type).
Driver: A person who owns vehicles (pt-BR: motorista). Avoid: user, motorista as a separate concept.
Company: An organization that owns vehicles (pt-BR: empresa), an alternative Owner to a Driver. Avoid: empresa, org, business.
Alert (pt-BR: placa marcada): A per-user subscription that fires a notification when a watched Plate, Driver, or Company appears in a Passage. Avoid: notification (the notification is the effect; the Alert is the subscription), watchlist entry.
Recurring Unknown (pt-BR: desconhecida recorrente): A Plate with no Owner seen repeatedly within a window (default: 3+ Passages in 7 days). Triggers one notification, then stays silent for a cool-down (default 7 days) or until the Vehicle becomes Known. The defaults are starting points, not measurements. Avoid: suspicious vehicle (the system reports recurrence, not intent).