[RAGE 001] Durable memory_remember + memory_get vertical slice #1
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
nsaspy/symbolic-memory#1
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Human gate
All research documents 001–012 are approved for implementation by the human operator. The durable gate is
research/IMPLEMENTATION-APPROVAL-2026-08-31.org.This is the only implementation slice to pick up right now. Do not widen into recall/search/forget/rule evolution yet.
Goal
Build the first executable end-to-end symbolic-memory path:
Prolog owns memory semantics, scope, authority decisions, IDs/domain records, and storage abstraction. Any MCP/transport layer is a thin adapter.
Required research inputs
At minimum consume these approved docs:
research/SYMBOLIC-MEMORY-RESEARCH-001-tiered-symbolic-memory.orgresearch/SYMBOLIC-MEMORY-RESEARCH-005-mcp-contract-and-authority.orgresearch/SYMBOLIC-MEMORY-RESEARCH-006-persistence-and-concurrency.orgresearch/SYMBOLIC-MEMORY-RESEARCH-009-memory-poisoning-and-trust-boundaries.orgresearch/SYMBOLIC-MEMORY-RESEARCH-010-project-identity-and-namespace-model.orgresearch/SYMBOLIC-MEMORY-RESEARCH-012-explicit-remember-durability.orgUse the remaining approved research as invariant/background context where relevant.
Implementation requirements
1. Library-first SWI-Prolog core
Create a small, testable Prolog library before transport glue. Keep modules narrow; suggested responsibilities are domain/model, namespace resolution, authority policy, storage adapter, bootstrap persistent backend, audit, and public API.
Do not expose arbitrary
assertz/1,retract/1,consult/1, shell, filesystem, or network execution as model tools.2.
memory_rememberMinimal model-facing input:
Host-bound context must carry principal/capabilities and project/session hints outside the natural-language memory text.
Default semantics:
Do not require symbolic extraction or an LLM for this slice. A memory with zero projections is valid.
3.
memory_getImplement ID-based retrieval sufficient to prove the write contract. It must return at least:
memory_getmust enforce read authority; knowing an ID is not authorization.4. Namespace identity
Implement the minimum correct namespace model, not path-as-identity.
Required:
It is okay to defer shared namespaces and sophisticated remote normalization as long as the interface does not preclude them.
5. Authority + trust
Make both explicit from v1.
At minimum support capabilities equivalent to:
Tests must prove a principal with project-write authority cannot write global memory.
Trust/provenance is data carried by the record and policy; it is not inferred from the memory text.
6. Storage adapter
Define the backend-neutral storage boundary now. The bootstrap backend may use SWI
library(persistency)as approved research recommends.The public/domain API must not depend on persistency-specific predicates.
Document the bootstrap as single-process if needed. Compound mutations must be serialized/atomic at the domain boundary.
A successful remember transaction must make the following visible together or not at all:
Do not claim database-grade multi-process guarantees from
library(persistency).7. Audit
Every write records an append-only event including at least:
8. MCP/native-tool smoke path
Expose
memory_rememberandmemory_getthrough the project's intended native MCP surface using a thin adapter over the Prolog API.Do not put semantics in the transport layer. If dependency/library selection for MCP needs a tiny research spike, keep it bounded to this issue and record the choice in the PR; do not restart the whole research program.
9. Nix/dev ergonomics
Add a Nix flake/dev shell so a fresh checkout can run the implementation and tests with SWI-Prolog available reproducibly.
Do not add GitHub Actions as part of this slice.
Required tests
Use PlUnit for domain invariants. Add integration/smoke coverage for the external tool surface.
Must cover at least:
memory_geta known ID;Out of scope
Do not implement in this slice:
memory_search;memory_recall;Leave extension points, not half-built features.
Definition of done
rage/branch and submitted as a PR;nix flake check(or the repo's equivalent flake test gate) passes locally;Auto-RAGE execution rule
Implement → run tests → inspect failures → repair → rerun until green. Keep the scope fixed. If a design ambiguity is not required for this vertical slice, defer it instead of widening the issue.
Implementation is now on draft PR #2 from
rage/001-remember-get.The remember/get vertical slice, namespace/authority/trust boundaries, single-process durable storage adapter, audit path, modern + legacy MCP adapter, Nix flake, and regression tests are implemented.
Not closing this issue yet. The current ChatGPT execution environment does not provide
swiplornix, so the authored suite has not been executed here. PR #2 stays draft untilnix flake check(or at minimumnix develop --command swipl -q -s test/run_tests.pl) is actually green.Reconciled into library-first core graph
This remains Slice 01 / the first executable vertical under parent #11 and foundation epic #12.
Do not widen #1 to implement the later world-model program. The immediate continuation after #1 is:
#1's source durability invariant remains foundational: exact source success is independent of semantic projection success.