Expand description
pnm memory … (and any CLI that adopts it) — CRUD over the VTA’s
per-context agent memory (spec/vta/memory/{put,list,delete}/0.1).
A per-context key/value store the hosted agent reads before it answers:
plant upserts an entry, recall lists (optionally one key), forget
deletes one, and wipe clears the whole context. Each maps onto one of
the SDK memory methods.
Two server-side gates gate every operation, and both matter to what an operator sees here:
- Capability —
MemoryReadforlist,MemoryWriteforputanddelete(vta-service/src/trust_tasks/memory.rs).wipetherefore needs both: it lists before it deletes. Areaderholds onlyMemoryRead, soplant/forget/wipeare refused for that role. - Context access — the isolation boundary. A caller can only touch memory in a context it is permitted to act in, so a context-A agent never reaches context-B memory.
The context is never defaulted at this layer. A super-admin’s access check passes for any context id and the memory tasks do not require the context to exist, so a guessed or mistyped id would read and write a context that is not there — silently, and looking exactly like an empty one. The caller names the context or there is no call.
Functions§
- cmd_
memory_ forget forget→memory_deletefor one key.- cmd_
memory_ plant plant→memory_put. Upsertsvalueunder(context, key); re-planting the same key overwrites the stored value.- cmd_
memory_ recall recall→memory_list, optionally filtered to a single key.- cmd_
memory_ wipe wipe→ list, thenmemory_deleteevery key. There is no bulk-delete Trust Task, so this is N round-trips and not atomic. Needs both memory capabilities —MemoryReadfor the list,MemoryWritefor the deletes.