Documentation
¶
Overview ¶
Package memory implements RiskKernel's git-native memory layer: a user-owned directory of markdown/YAML/text files the agent reads. The files are yours — version them in git, edit them in your editor; RiskKernel only reads them.
Retrieval is deterministic: list, read, and keyword search. There is NO embedding index / vector DB in v0.1 (CLAUDE.md §9) — semantic search is a future opt-in. Reads are path-traversal-safe: a request can never escape the root.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrNotFound = errors.New("memory: not found")
ErrNotFound is returned when a memory entry does not exist.
var ErrUnsafePath = errors.New("memory: unsafe path")
ErrUnsafePath is returned when a name would escape the memory root.
Functions ¶
This section is empty.
Types ¶
type Entry ¶
type Entry struct {
Namespace string `json:"namespace"`
Name string `json:"name"` // path relative to the namespace
Title string `json:"title"`
Description string `json:"description,omitempty"`
Format string `json:"format"` // markdown | yaml | text
Size int64 `json:"size"`
ModTime time.Time `json:"modTime"`
}
Entry is a memory file's metadata.
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
Reader reads a configured memory root directory.
func (*Reader) List ¶
List returns the memory entries under namespace (recursively). A missing directory yields an empty list, not an error.