al-buddy-memory

v0.12.0
io.github.flytomoon/al-buddy-memory Checked 1 hour ago Published 1 month ago

Governed local memory for AI agents: facts are retired, not overwritten, and every call is audited.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

remember

Store a fact with its provenance. Returns the fact with validFrom, provenance and confidence, plus mayConflictWith: current facts this one may be correcting — read them and invalidate any that stopped being true.

ParameterTypeDescription
text *string
confidencenumber
provenancestring

recall

Find facts. Every result says who asserted it, since when it has been true, whether it is still current, what superseded it, and which assistant wrote or retired it. The first call of a session, and the first after they change, also returns the user's pinned rules — treat those as standing rules for the conversation.

ParameterTypeDescription
query *string
includeSupersededboolean
limitinteger

history

Show the recorded changes to one fact, including each change time and the full mutable state before and after it.

ParameterTypeDescription
id *string

explain

Why a fact is believed: who asserted it, when it was true and what ended or replaced it, and for a conclusion the exact words it rests on, each checked against its source now.

ParameterTypeDescription
id *string

mental_model

Read a standing question's pre-written answer (no model call): the answer, whether it is fresh or stale and why, and the exact words it rests on. Omit id to list every mental model.

ParameterTypeDescription
idstring

define_mental_model

Define a standing question to keep answered (e.g. "What does the user care about when choosing tools?"), optionally limited to facts carrying some tags. The host's scheduled refresh writes the answer.

ParameterTypeDescription
question *string
tagsarray

invalidate

A fact stopped being true: close its validity (never delete), optionally naming what replaced it.

ParameterTypeDescription
id *string
reasonstring
replacedBystring

pin

Pin a fact into the always-in-prompt tier. Only rules that belong in every conversation; it is a small, budgeted tier.

ParameterTypeDescription
text *string
labelstring

unpin

Unpin a fact (its validity closes; it is kept).

ParameterTypeDescription
id *string

pinned

The pinned tier, as a list and as the rendered prompt block.

export

Export the user's memory in the portable format, with provenance and validity. Only when the user asks for an export or backup. Without a path it is returned inline if under 50000 bytes; otherwise give an absolute path ending in .json that does not exist yet (never overwrites).

ParameterTypeDescription
pathstring