pub fn remember<F: Fs>(
db: &mut GraphDb<F>,
input: &RememberInput<'_>,
) -> Result<RememberReport>Expand description
Write input as a Note, describing whatever it names along the way.
Validated before anything is written: text must be
[MIN_TEXT_CHARS]..=[MAX_TEXT_CHARS] characters after trimming, and
kind must be one of NOTE_KINDS. Unlike the code-graph remember
0.7 deleted, an unknown about key is never an error — see the module
docs. A key that is empty or only whitespace is one: in about, as an
entities[].key or as a fact’s subject or object it refuses the
whole call, naming the argument and its position, and nothing is written.
So is an entities[].label or a fact’s predicate with nothing in it.
The note’s key is "note:" followed by 16 hex characters of a stable
64-bit hash of ts and text (see [note_key]), so remembering the
same text at the same ts again returns the same key without writing a
second node.
Also ensures full-text search is enabled on Note.text, so a store whose
very first write is a remember call can still be recalled from.