1.0 KiB
1.0 KiB
Validation rules
Reject an import atomically if any error rule fails:
- Exact documented headers; UTF-8; unique, non-empty stable keys.
- Unique normalised names; trimmed display values; controlled enum/boolean values.
- Every relationship endpoint and every usage foreign key resolves.
- No self-relationships or duplicate
(from, to, type)relationships. - All numeric weights are finite and in
[0,1]. - Male and female weights total 1 within
0.0002. - Every name/locale has exactly five ordered, contiguous, non-overlapping bands covering 1900–2026.
- No ownership columns or project-specific aliases enter the reference package.
- Package version and import outcome are recorded transactionally.
Behavioural invariants:
- Unknown name → no dictionary evidence, never “not a person”.
- Relationship → candidate/explanation/warning, never automatic identity merge.
- Gender prior → ranking hint, always subordinate to manuscript evidence.
- Used-name status → computed from project/book/series character data at query time.