save

open suspend override fun save(fact: Fact, subject: MemorySubject, scope: MemoryScope)(source)

Persists a fact in the agent's memory system. This operation ensures:

  • Atomic storage of the fact

  • Proper scoping and subject categorization

  • Consistent storage format

Parameters

fact

Knowledge unit to store (can be SingleFact or MultipleFacts)

subject

Context category (e.g., MACHINE, PROJECT)

scope

Visibility boundary (e.g., Agent, Feature)

Throws

IOException

if storage operation fails