Skip to content

feat(people): add typed temporal relationships - #592

Open
salmonumbrella wants to merge 1 commit into
kenn-io:mainfrom
salmonumbrella:typed-person-relationships-v0193-publication
Open

feat(people): add typed temporal relationships#592
salmonumbrella wants to merge 1 commit into
kenn-io:mainfrom
salmonumbrella:typed-person-relationships-v0193-publication

Conversation

@salmonumbrella

Copy link
Copy Markdown
Contributor

What changed

  • Add seeded and user-defined relationship types with forward and reverse labels, symmetric-type support, presentation metadata, and optional vCard RELATED mappings.
  • Store one canonical, temporal edge per person relationship with partial start and end dates, history, notes, provenance, confidence, optimistic concurrency, and active-duplicate protection.
  • Render the correct label from either person's view without mirrored rows, and keep ended relationships available as history.
  • Resolve imported RELATED values only by exact person UID; unresolved values enter a review queue instead of creating people automatically.
  • Expose the model through equivalent SQLite and PostgreSQL stores, the daemon HTTP/OpenAPI clients, and new relationship CLI commands. A graph UI remains out of scope.

Why

Msgvault can preserve rich person profiles, but it cannot yet represent how two people are connected or how that connection changes over time. Copying labels onto profiles loses direction, history, and source evidence, while guessing from imported names or contact values risks linking the wrong people.

Usage

msgvault relationship-type list
msgvault person relationship add 12 partner 34 --from 2024-03
msgvault person relationship list 12
msgvault person relationship end 57 2026-08-09
msgvault person relationship reviews --status pending

Refs #534

@roborev-ci

roborev-ci Bot commented Aug 9, 2026

Copy link
Copy Markdown

roborev: Combined Review (332e3e4)

Code review found one medium-severity consistency issue; no high or critical findings.

Medium

  • Seeded vCard mappings can cause startup failures after mutationinternal/store/relationship_types.go:374

    Seeded relationship types allow vcard_related_type to be cleared or reassigned, but startup reconciliation restores the original mapping. For example, clearing friend and assigning it to a custom type can cause reseeding to violate the unique constraint, preventing archive initialization after restart.

    Fix: Make seeded types’ vCard mappings immutable, or stop reconciling this field so successful updates persist consistently.


Reviewers: 2 done | Synthesis: codex, 8s | Total: 12m47s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant