Article chapter 04 of 08
Relationships that help with real tasks
From Long-term AI memory: records, relationships and retrieval
Relationships are what make memory useful when the query doesn't repeat the source's wording. A task about a deployment might need the service, the repository, the environment, the owner, the last decision and the operating procedure, all connected to each other.
I'd start with a small vocabulary of relationships, chosen from the questions you actually expect to answer. Something like:
- a person
ownsa service - a decision
applies_toa project - a task
depends_onanother task - a document
supportsa decision - a record
supersedesanother record - an event
changedan entity - a preference
has_scopea project or communication channel
Pin down the direction and meaning of each one. Left vague, owns could mean operational responsibility, commercial ownership or who wrote the record. If those differences change what gets retrieved or who's allowed to see it, split them into separate relationships.
Relationships need their own provenance and validity as well. Who owns a service can change without either the person or the service changing. A relationship record should point at the source that set it up, carry effective dates and be able to be superseded like any other record.
Two things being mentioned together is a weak hint, and I wouldn't turn every shared mention into a graph edge. To become a durable relationship it should need a typed statement or a rule that someone can review.
Entity resolution happens on the write path. Two people can have the same name, and one project's shorthand can overlap with another's. Use stable identifiers from trusted systems where you can. When you can't tell who or what a mention refers to, keep it as an unresolved mention linked to its source instead of attaching it to whichever entity matches most closely.
Keep documents and semantic search running alongside the graph. Relationships are good for bounded traversal and current-state questions. Document retrieval covers explanations, detailed procedures and anything that hasn't been turned into structured records yet.