memory_pin
Pin or unpin a memory capsule to exempt it from decay and consolidation archiving. Every action is witnessed and audited with a required reason.
Instructions
Pin (or unpin) ONE capsule so decay never erodes it and the consolidation planner never archives it (S1). Pass id (cap-), pinned (true to pin, false to unpin), and a non-empty reason — pin is a WITNESSED, audited act. A pinned capsule ranks by its FULL confidence on every memory_retrieve and memory_bootstrap surface: decay is exempted at the ranking call site and the stored confidence is NEVER mutated; the archive arm of memory_consolidate skips it. Pin is NEVER eligibility — the recall fences (quarantine / falsified / archived / superseded / currency) run UNCHANGED, so a pinned+superseded (or quarantined or falsified) capsule stays EXCLUDED from recall: pin protects a live grounding capsule, it never resurrects a fenced one. Taint dominates pin: a pinned capsule that is instruction-tainted AND externally-imported still QUARANTINES under memory_consolidate (a pin can never launder taint). Unpin (pinned:false) resumes decay from valid_from. APPEND-ONLY: each call appends a pin/unpin event and state is the latest event; there is no separate delete. Audited (hash-chained journal). An unknown id answers resource-not-found (-32002, data {kind,id}); a tombstoned id, or an empty reason, is a teaching -32602. The pin surfaces as a pinned flag on memory_get / memory_list / memory_digest rows and as memory_digest's pinned section — there is NO new memory_bootstrap pack section. Every response is ADVISORY_NOT_AUTHORITY DATA.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | The capsule to pin or unpin (`cap-<n>`, an exact store handle). | |
| pinned | Yes | `true` pins (decay-exempt + archive-vetoed), `false` unpins (decay resumes from `valid_from`). Pin is NEVER eligibility — a pinned+ superseded/quarantined/falsified capsule stays recall-excluded. | |
| reason | Yes | Why — a non-empty, audited justification (pin is a witnessed act). |